import * as pulumi from "@pulumi/pulumi"; import * as outputs from "./types/output"; /** * > **Authentication:** Protection policy operations do **not** support API key authentication. Use `username` and `password` in the provider configuration. * * List the protection policies defined on the system. This operation supports filtering, sorting, selection and pagination. * * ## Example Usage * * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as nutanix from "@pierskarsenbarg/nutanix"; * * // with filter * const pps_filter = nutanix.getProtectionPoliciesV2({ * filter: "name eq 'example_protection_policy'", * }); * // with limit * const pp_limit = nutanix.getProtectionPoliciesV2({ * limit: 4, * }); * // with filter and limit * const example = nutanix.getProtectionPoliciesV2({ * filter: "startswith(name, 'C')", * limit: 10, * }); * ``` * * * ## Protection Policies * * The `protectionPolicies` is a list of protection policies. Each protection policy supports the following attributes: * * * `tenantId`: - A globally unique identifier that represents the tenant that owns this entity. The system automatically assigns it, and it and is immutable from an API consumer perspective (some use cases may cause this Id to change - For instance, a use case may require the transfer of ownership of the entity, but these cases are handled automatically on the server). * * `extId`: - A globally unique identifier of an instance that is suitable for external consumption. * * `links`: - A HATEOAS style link for the response. Each link contains a user-friendly name identifying the link and an address for retrieving the particular resource. * * `name`: - Name of the protection policy. * * `description`: - Description of the protection policy. * * `replicationLocations`: - Hypervisor details. * * `replicationConfigurations`: - Cluster reference for an entity. * * `categoryIds`: - Host entity with its attributes. * * `isApprovalPolicyNeeded`: - Disks attached to host. * * `ownerExtId`: - Node degraded status. * * ### Links * The links attribute supports the following: * * * `href`: - The URL at which the entity described by the link can be accessed. * * `rel`: - A name that identifies the relationship of the link to the object that is returned by the URL. The unique value of "self" identifies the URL for the object. * * ### Replication Locations * The replicationLocations attribute supports the following: * * * `label`: - This is a unique user defined label of the replication location. It is used to identify the location in the replication configurations. * * `domainManagerExtId`: - External identifier of the domain manager. * * `replicationSubLocation`: - Specifies the replication sub-locations where recovery points can be created or replicated. * * `isPrimary`: - One of the locations must be specified as the primary location. All the other locations must be connected to the primary location. * * #### Replication Sub Location * The replicationSubLocation attribute supports the following: * > One of `clusterExtIds` : * * `clusterExtIds` : - External identifier of the clusters. * * ##### Cluster Ext Ids * The clusterExtIds attribute supports the following: * * * `clusterExtId`: - List of Prism Element cluster external identifiers whose associated VMs and volume groups are protected. Only the primary location can have multiple clusters configured, while the other locations can specify only one cluster. Clusters must be specified for replication within the same Prism Central and cannot be specified for an MST type location. All clusters are considered if the cluster external identifier list is empty. * * ### Replication Configurations * The replicationConfigurations attribute supports the following: * * * `sourceLocationLabel`: - Label of the source location from the replication locations list, where the entity is running. The location of type MST can not be specified as the replication source. * * `remoteLocationLabel`: - Label of the source location from the replication locations list, where the entity will be replicated. * * `schedule`: - Schedule for protection. The schedule specifies the recovery point objective and the retention policy for the participating locations. * * #### Schedule * The schedule attribute supports the following: * * * `recoveryPointType`: - Type of recovery point. * * `CRASH_CONSISTENT`: Crash-consistent Recovery points capture all the VM and application level details. * * `APP_CONSISTENT`: Application-consistent Recovery points can capture all the data stored in the memory and also the in-progress transaction details. * * `recoveryPointObjectiveTimeSeconds`: - The Recovery point objective of the schedule in seconds and specified in multiple of 60 seconds. Only following RPO values can be provided for rollup retention type: * - Minute(s): 1, 2, 3, 4, 5, 6, 10, 12, 15 * - Hour(s): 1, 2, 3, 4, 6, 8, 12 * - Day(s): 1 * - Week(s): 1, 2 * * `retention`: - Specifies the retention policy for the recovery point schedule. * * `startTime`: - Represents the protection start time for the new entities added to the policy after the policy is created in h:m format. The values must be between 00h:00m and 23h:59m and in UTC timezone. It specifies the time when the first snapshot is taken and replicated for any entity added to the policy. If this is not specified, the snapshot is taken immediately and replicated for any new entity added to the policy. * * `syncReplicationAutoSuspendTimeoutSeconds`: - Auto suspend timeout if there is a connection failure between locations for synchronous replication. If this value is not set, then the policy will not be suspended. * * #### Retention * > One of `linearRetention` or `autoRollupRetention` : * * * `linearRetention`: - Linear retention policy. * * `autoRollupRetention`: - Auto rollup retention policy. * * ##### Linear Retention * The linearRetention attribute supports the following: * * * `local`: - Specifies the number of recovery points to retain on the local location. * * `remote`: - Specifies the number of recovery points to retain on the remote location. * * ##### Auto Rollup Retention * The autoRollupRetention attribute supports the following: * * * `local`: - Specifies the auto rollup retention details. * * `remote`: - Specifies the auto rollup retention details. * * ###### Local, Remote * The local, remote attribute in the autoRollupRetention supports the following: * * * `snapshotIntervalType`: - Snapshot interval period. * * `YEARLY`: Specifies the number of latest yearly recovery points to retain. * * `WEEKLY`: Specifies the number of latest weekly recovery points to retain. * * `DAILY`: Specifies the number of latest daily recovery points to retain. * * `MONTHLY`: Specifies the number of latest monthly recovery points to retain. * * `HOURLY`: Specifies the number of latest hourly recovery points to retain. * * `frequency`: - Multiplier to 'snapshotIntervalType'. For example, if 'snapshotIntervalType' is 'YEARLY' and 'multiple' is 5, then 5 years worth of rollup snapshots will be retained. * * See detailed information in [Nutanix List Protection Policies V4](https://developers.nutanix.com/api-reference?namespace=datapolicies&version=v4.2#tag/ProtectionPolicies/operation/listProtectionPolicies). */ export declare function getProtectionPoliciesV2(args?: GetProtectionPoliciesV2Args, opts?: pulumi.InvokeOptions): Promise; /** * A collection of arguments for invoking getProtectionPoliciesV2. */ export interface GetProtectionPoliciesV2Args { /** * -(Optional) A URL query parameter that allows clients to filter a collection of resources. The expression specified with $filter is evaluated for each resource in the collection, and only items where the expression evaluates to true are included in the response. Expression specified with the $filter must conform to the OData V4.01 URL conventions. For example, filter '$filter=name eq 'karbon-ntnx-1.0' would filter the result on cluster name 'karbon-ntnx1.0', filter '$filter=startswith(name, 'C')' would filter on cluster name starting with 'C'. The filter can be applied to the following fields: * - extId * - name * - ownerExtId * - replicationLocations/domainManagerExtId */ filter?: string; /** * -(Optional) A URL query parameter that specifies the total number of records returned in the result set. Must be a positive integer between 1 and 100. Any number out of this range will lead to a validation error. If the limit is not provided, a default value of 50 records will be returned in the result set. */ limit?: number; /** * -(Optional) A URL query parameter that allows clients to specify the sort criteria for the returned list of objects. Resources can be sorted in ascending order using asc or descending order using desc. If asc or desc are not specified, the resources will be sorted in ascending order by default. For example, '$orderby=templateName desc' would get all templates sorted by templateName in descending order. The orderby can be applied to the following fields: * - name */ orderBy?: string; /** * -(Optional) A URL query parameter that specifies the page number of the result set. It must be a positive integer between 0 and the maximum number of pages that are available for that resource. Any number out of this range might lead to no results. */ page?: number; /** * -(Optional) A URL query parameter that allows clients to request a specific set of properties for each entity or complex type. Expression specified with the $select must conform to the OData V4.01 URL conventions. If a $select expression consists of a single select item that is an asterisk (i.e., *), then all properties on the matching resource will be returned. * - extId * - name */ select?: string; } /** * A collection of values returned by getProtectionPoliciesV2. */ export interface GetProtectionPoliciesV2Result { readonly filter?: string; /** * The provider-assigned unique ID for this managed resource. */ readonly id: string; readonly limit?: number; readonly orderBy?: string; readonly page?: number; /** * - List of protection policies. */ readonly protectionPolicies: outputs.GetProtectionPoliciesV2ProtectionPolicy[]; readonly select?: string; } /** * > **Authentication:** Protection policy operations do **not** support API key authentication. Use `username` and `password` in the provider configuration. * * List the protection policies defined on the system. This operation supports filtering, sorting, selection and pagination. * * ## Example Usage * * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as nutanix from "@pierskarsenbarg/nutanix"; * * // with filter * const pps_filter = nutanix.getProtectionPoliciesV2({ * filter: "name eq 'example_protection_policy'", * }); * // with limit * const pp_limit = nutanix.getProtectionPoliciesV2({ * limit: 4, * }); * // with filter and limit * const example = nutanix.getProtectionPoliciesV2({ * filter: "startswith(name, 'C')", * limit: 10, * }); * ``` * * * ## Protection Policies * * The `protectionPolicies` is a list of protection policies. Each protection policy supports the following attributes: * * * `tenantId`: - A globally unique identifier that represents the tenant that owns this entity. The system automatically assigns it, and it and is immutable from an API consumer perspective (some use cases may cause this Id to change - For instance, a use case may require the transfer of ownership of the entity, but these cases are handled automatically on the server). * * `extId`: - A globally unique identifier of an instance that is suitable for external consumption. * * `links`: - A HATEOAS style link for the response. Each link contains a user-friendly name identifying the link and an address for retrieving the particular resource. * * `name`: - Name of the protection policy. * * `description`: - Description of the protection policy. * * `replicationLocations`: - Hypervisor details. * * `replicationConfigurations`: - Cluster reference for an entity. * * `categoryIds`: - Host entity with its attributes. * * `isApprovalPolicyNeeded`: - Disks attached to host. * * `ownerExtId`: - Node degraded status. * * ### Links * The links attribute supports the following: * * * `href`: - The URL at which the entity described by the link can be accessed. * * `rel`: - A name that identifies the relationship of the link to the object that is returned by the URL. The unique value of "self" identifies the URL for the object. * * ### Replication Locations * The replicationLocations attribute supports the following: * * * `label`: - This is a unique user defined label of the replication location. It is used to identify the location in the replication configurations. * * `domainManagerExtId`: - External identifier of the domain manager. * * `replicationSubLocation`: - Specifies the replication sub-locations where recovery points can be created or replicated. * * `isPrimary`: - One of the locations must be specified as the primary location. All the other locations must be connected to the primary location. * * #### Replication Sub Location * The replicationSubLocation attribute supports the following: * > One of `clusterExtIds` : * * `clusterExtIds` : - External identifier of the clusters. * * ##### Cluster Ext Ids * The clusterExtIds attribute supports the following: * * * `clusterExtId`: - List of Prism Element cluster external identifiers whose associated VMs and volume groups are protected. Only the primary location can have multiple clusters configured, while the other locations can specify only one cluster. Clusters must be specified for replication within the same Prism Central and cannot be specified for an MST type location. All clusters are considered if the cluster external identifier list is empty. * * ### Replication Configurations * The replicationConfigurations attribute supports the following: * * * `sourceLocationLabel`: - Label of the source location from the replication locations list, where the entity is running. The location of type MST can not be specified as the replication source. * * `remoteLocationLabel`: - Label of the source location from the replication locations list, where the entity will be replicated. * * `schedule`: - Schedule for protection. The schedule specifies the recovery point objective and the retention policy for the participating locations. * * #### Schedule * The schedule attribute supports the following: * * * `recoveryPointType`: - Type of recovery point. * * `CRASH_CONSISTENT`: Crash-consistent Recovery points capture all the VM and application level details. * * `APP_CONSISTENT`: Application-consistent Recovery points can capture all the data stored in the memory and also the in-progress transaction details. * * `recoveryPointObjectiveTimeSeconds`: - The Recovery point objective of the schedule in seconds and specified in multiple of 60 seconds. Only following RPO values can be provided for rollup retention type: * - Minute(s): 1, 2, 3, 4, 5, 6, 10, 12, 15 * - Hour(s): 1, 2, 3, 4, 6, 8, 12 * - Day(s): 1 * - Week(s): 1, 2 * * `retention`: - Specifies the retention policy for the recovery point schedule. * * `startTime`: - Represents the protection start time for the new entities added to the policy after the policy is created in h:m format. The values must be between 00h:00m and 23h:59m and in UTC timezone. It specifies the time when the first snapshot is taken and replicated for any entity added to the policy. If this is not specified, the snapshot is taken immediately and replicated for any new entity added to the policy. * * `syncReplicationAutoSuspendTimeoutSeconds`: - Auto suspend timeout if there is a connection failure between locations for synchronous replication. If this value is not set, then the policy will not be suspended. * * #### Retention * > One of `linearRetention` or `autoRollupRetention` : * * * `linearRetention`: - Linear retention policy. * * `autoRollupRetention`: - Auto rollup retention policy. * * ##### Linear Retention * The linearRetention attribute supports the following: * * * `local`: - Specifies the number of recovery points to retain on the local location. * * `remote`: - Specifies the number of recovery points to retain on the remote location. * * ##### Auto Rollup Retention * The autoRollupRetention attribute supports the following: * * * `local`: - Specifies the auto rollup retention details. * * `remote`: - Specifies the auto rollup retention details. * * ###### Local, Remote * The local, remote attribute in the autoRollupRetention supports the following: * * * `snapshotIntervalType`: - Snapshot interval period. * * `YEARLY`: Specifies the number of latest yearly recovery points to retain. * * `WEEKLY`: Specifies the number of latest weekly recovery points to retain. * * `DAILY`: Specifies the number of latest daily recovery points to retain. * * `MONTHLY`: Specifies the number of latest monthly recovery points to retain. * * `HOURLY`: Specifies the number of latest hourly recovery points to retain. * * `frequency`: - Multiplier to 'snapshotIntervalType'. For example, if 'snapshotIntervalType' is 'YEARLY' and 'multiple' is 5, then 5 years worth of rollup snapshots will be retained. * * See detailed information in [Nutanix List Protection Policies V4](https://developers.nutanix.com/api-reference?namespace=datapolicies&version=v4.2#tag/ProtectionPolicies/operation/listProtectionPolicies). */ export declare function getProtectionPoliciesV2Output(args?: GetProtectionPoliciesV2OutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output; /** * A collection of arguments for invoking getProtectionPoliciesV2. */ export interface GetProtectionPoliciesV2OutputArgs { /** * -(Optional) A URL query parameter that allows clients to filter a collection of resources. The expression specified with $filter is evaluated for each resource in the collection, and only items where the expression evaluates to true are included in the response. Expression specified with the $filter must conform to the OData V4.01 URL conventions. For example, filter '$filter=name eq 'karbon-ntnx-1.0' would filter the result on cluster name 'karbon-ntnx1.0', filter '$filter=startswith(name, 'C')' would filter on cluster name starting with 'C'. The filter can be applied to the following fields: * - extId * - name * - ownerExtId * - replicationLocations/domainManagerExtId */ filter?: pulumi.Input; /** * -(Optional) A URL query parameter that specifies the total number of records returned in the result set. Must be a positive integer between 1 and 100. Any number out of this range will lead to a validation error. If the limit is not provided, a default value of 50 records will be returned in the result set. */ limit?: pulumi.Input; /** * -(Optional) A URL query parameter that allows clients to specify the sort criteria for the returned list of objects. Resources can be sorted in ascending order using asc or descending order using desc. If asc or desc are not specified, the resources will be sorted in ascending order by default. For example, '$orderby=templateName desc' would get all templates sorted by templateName in descending order. The orderby can be applied to the following fields: * - name */ orderBy?: pulumi.Input; /** * -(Optional) A URL query parameter that specifies the page number of the result set. It must be a positive integer between 0 and the maximum number of pages that are available for that resource. Any number out of this range might lead to no results. */ page?: pulumi.Input; /** * -(Optional) A URL query parameter that allows clients to request a specific set of properties for each entity or complex type. Expression specified with the $select must conform to the OData V4.01 URL conventions. If a $select expression consists of a single select item that is an asterisk (i.e., *), then all properties on the matching resource will be returned. * - extId * - name */ select?: pulumi.Input; } //# sourceMappingURL=getProtectionPoliciesV2.d.ts.map