oracle.oci.oci_bds_auto_scale_config_facts – Fetches details about one or multiple BdsAutoScaleConfig resources in Oracle Cloud Infrastructure

Note

This plugin is part of the oracle.oci collection (version 4.14.0).

You might already have this collection installed if you are using the ansible package. It is not included in ansible-core. To check whether it is installed, run ansible-galaxy collection list.

To install it, use: ansible-galaxy collection install oracle.oci.

To use it in a playbook, specify: oracle.oci.oci_bds_auto_scale_config_facts.

New in version 2.9.0: of oracle.oci

Synopsis

  • Fetches details about one or multiple BdsAutoScaleConfig resources in Oracle Cloud Infrastructure

  • Returns information about the autoscaling configurations for a cluster.

  • If auto_scaling_configuration_id is specified, the details of a single BdsAutoScaleConfig will be returned.

Requirements

The below requirements are needed on the host that executes this module.

Parameters

Parameter Choices/Defaults Comments
api_user
string
The OCID of the user, on whose behalf, OCI APIs are invoked. If not set, then the value of the OCI_USER_ID environment variable, if any, is used. This option is required if the user is not specified through a configuration file (See config_file_location). To get the user's OCID, please refer https://docs.us-phoenix-1.oraclecloud.com/Content/API/Concepts/apisigningkey.htm.
api_user_fingerprint
string
Fingerprint for the key pair being used. If not set, then the value of the OCI_USER_FINGERPRINT environment variable, if any, is used. This option is required if the key fingerprint is not specified through a configuration file (See config_file_location). To get the key pair's fingerprint value please refer https://docs.us-phoenix-1.oraclecloud.com/Content/API/Concepts/apisigningkey.htm.
api_user_key_file
string
Full path and filename of the private key (in PEM format). If not set, then the value of the OCI_USER_KEY_FILE variable, if any, is used. This option is required if the private key is not specified through a configuration file (See config_file_location). If the key is encrypted with a pass-phrase, the api_user_key_pass_phrase option must also be provided.
api_user_key_pass_phrase
string
Passphrase used by the key referenced in api_user_key_file, if it is encrypted. If not set, then the value of the OCI_USER_KEY_PASS_PHRASE variable, if any, is used. This option is required if the key passphrase is not specified through a configuration file (See config_file_location).
auth_purpose
string
    Choices:
  • service_principal
The auth purpose which can be used in conjunction with 'auth_type=instance_principal'. The default auth_purpose for instance_principal is None.
auth_type
string
    Choices:
  • api_key ←
  • instance_principal
  • instance_obo_user
  • resource_principal
The type of authentication to use for making API requests. By default auth_type="api_key" based authentication is performed and the API key (see api_user_key_file) in your config file will be used. If this 'auth_type' module option is not specified, the value of the OCI_ANSIBLE_AUTH_TYPE, if any, is used. Use auth_type="instance_principal" to use instance principal based authentication when running ansible playbooks within an OCI compute instance.
auto_scaling_configuration_id
string
Unique Oracle-assigned identifier of the autoscale configuration.
Required to get a specific bds_auto_scale_config.

aliases: id
bds_instance_id
string / required
The OCID of the cluster.
cert_bundle
string
The full path to a CA certificate bundle to be used for SSL verification. This will override the default CA certificate bundle. If not set, then the value of the OCI_ANSIBLE_CERT_BUNDLE variable, if any, is used.
compartment_id
string
The OCID of the compartment.
Required to list multiple bds_auto_scale_configs.
config_file_location
string
Path to configuration file. If not set then the value of the OCI_CONFIG_FILE environment variable, if any, is used. Otherwise, defaults to ~/.oci/config.
config_profile_name
string
The profile to load from the config file referenced by config_file_location. If not set, then the value of the OCI_CONFIG_PROFILE environment variable, if any, is used. Otherwise, defaults to the "DEFAULT" profile in config_file_location.
display_name
string
A filter to return only resources that match the entire display name given.

aliases: name
lifecycle_state
string
    Choices:
  • CREATING
  • ACTIVE
  • INACTIVE
  • UPDATING
  • DELETING
  • DELETED
  • FAILED
The state of the autoscale configuration.
region
string
The Oracle Cloud Infrastructure region to use for all OCI API requests. If not set, then the value of the OCI_REGION variable, if any, is used. This option is required if the region is not specified through a configuration file (See config_file_location). Please refer to https://docs.us-phoenix-1.oraclecloud.com/Content/General/Concepts/regions.htm for more information on OCI regions.
sort_by
string
    Choices:
  • timeCreated
  • displayName
The field to sort by. Only one sort order may be provided. Default order for timeCreated is descending. Default order for displayName is ascending. If no value is specified timeCreated is default.
sort_order
string
    Choices:
  • ASC
  • DESC
The sort order to use, either 'asc' or 'desc'.
tenancy
string
OCID of your tenancy. If not set, then the value of the OCI_TENANCY variable, if any, is used. This option is required if the tenancy OCID is not specified through a configuration file (See config_file_location). To get the tenancy OCID, please refer https://docs.us-phoenix-1.oraclecloud.com/Content/API/Concepts/apisigningkey.htm

Examples

- name: Get a specific bds_auto_scale_config
  oci_bds_auto_scale_config_facts:
    # required
    auto_scaling_configuration_id: "ocid1.autoscalingconfiguration.oc1..xxxxxxEXAMPLExxxxxx"
    bds_instance_id: "ocid1.bdsinstance.oc1..xxxxxxEXAMPLExxxxxx"

- name: List bds_auto_scale_configs
  oci_bds_auto_scale_config_facts:
    # required
    compartment_id: "ocid1.compartment.oc1..xxxxxxEXAMPLExxxxxx"
    bds_instance_id: "ocid1.bdsinstance.oc1..xxxxxxEXAMPLExxxxxx"

    # optional
    sort_by: timeCreated
    sort_order: ASC
    display_name: display_name_example
    lifecycle_state: CREATING

Return Values

Common return values are documented here, the following are the fields unique to this module:

Key Returned Description
bds_auto_scale_configs
complex
on success
List of BdsAutoScaleConfig resources

Sample:
[{'display_name': 'display_name_example', 'id': 'ocid1.resource.oc1..xxxxxxEXAMPLExxxxxx', 'lifecycle_state': 'CREATING', 'node_type': 'node_type_example', 'policy': {'policy_type': 'THRESHOLD_BASED', 'rules': [{'action': 'CHANGE_SHAPE_SCALE_UP', 'metric': {'metric_type': 'CPU_UTILIZATION', 'threshold': {'duration_in_minutes': 56, 'operator': 'GT', 'value': 56}}}]}, 'policy_details': {'action_type': 'VERTICAL_SCALING', 'policy_type': 'METRIC_BASED_VERTICAL_SCALING_POLICY', 'scale_down_config': {'memory_step_size': 56, 'metric': {'metric_type': 'CPU_UTILIZATION', 'threshold': {'duration_in_minutes': 56, 'operator': 'GT', 'value': 56}}, 'min_memory_per_node': 56, 'min_ocpus_per_node': 56, 'ocpu_step_size': 56}, 'scale_in_config': {'metric': {'metric_type': 'CPU_UTILIZATION', 'threshold': {'duration_in_minutes': 56, 'operator': 'GT', 'value': 56}}, 'min_node_count': 56, 'step_size': 56}, 'scale_out_config': {'max_node_count': 56, 'metric': {'metric_type': 'CPU_UTILIZATION', 'threshold': {'duration_in_minutes': 56, 'operator': 'GT', 'value': 56}}, 'step_size': 56}, 'scale_up_config': {'max_memory_per_node': 56, 'max_ocpus_per_node': 56, 'memory_step_size': 56, 'metric': {'metric_type': 'CPU_UTILIZATION', 'threshold': {'duration_in_minutes': 56, 'operator': 'GT', 'value': 56}}, 'ocpu_step_size': 56}, 'schedule_details': [{'schedule_type': 'DAY_BASED', 'time_and_horizontal_scaling_config': [{'target_node_count': 56, 'time_recurrence': 'time_recurrence_example'}], 'time_and_vertical_scaling_config': [{'target_memory_per_node': 56, 'target_ocpus_per_node': 56, 'target_shape': 'target_shape_example', 'time_recurrence': 'time_recurrence_example'}]}], 'timezone': 'timezone_example', 'trigger_type': 'METRIC_BASED'}, 'time_created': '2013-10-20T19:20:30+01:00', 'time_updated': '2013-10-20T19:20:30+01:00'}]
 
display_name
string
on success
A user-friendly name. The name does not have to be unique, and it may be changed. Avoid entering confidential information.

Sample:
display_name_example
 
id
string
on success
The unique identifier for the autoscale configuration.

Sample:
ocid1.resource.oc1..xxxxxxEXAMPLExxxxxx
 
lifecycle_state
string
on success
The state of the autoscale configuration.

Sample:
CREATING
 
node_type
string
on success
A node type that is managed by an autoscale configuration. The only supported types are WORKER and COMPUTE_ONLY_WORKER.

Sample:
node_type_example
 
policy
complex
on success

   
policy_type
string
on success
Types of autoscale policies. Options are SCHEDULE-BASED or THRESHOLD-BASED. (Only THRESHOLD-BASED is supported in this release.)

Sample:
THRESHOLD_BASED
   
rules
complex
on success
The list of rules for autoscaling. If an action has multiple rules, the last rule in the array will be applied.

     
action
string
on success
The valid value are CHANGE_SHAPE_SCALE_UP or CHANGE_SHAPE_SCALE_DOWN.

Sample:
CHANGE_SHAPE_SCALE_UP
     
metric
complex
on success

       
metric_type
string
on success
Allowed value is CPU_UTILIZATION.

Sample:
CPU_UTILIZATION
       
threshold
complex
on success

         
duration_in_minutes
integer
on success
This value is the minimum period of time the metric value exceeds the threshold value before the action is triggered. The value is in minutes.

Sample:
56
         
operator
string
on success
The comparison operator to use. Options are greater than (GT) or less than (LT).

Sample:
GT
         
value
integer
on success
Integer non-negative value. 0 < value < 100

Sample:
56
 
policy_details
complex
on success

   
action_type
string
on success
The type of autoscaling action to take.

Sample:
VERTICAL_SCALING
   
policy_type
string
on success
Type of autoscaling policy.

Sample:
METRIC_BASED_VERTICAL_SCALING_POLICY
   
scale_down_config
complex
on success

     
memory_step_size
integer
on success
For nodes with flexible compute shapes, this value is the size of memory in GBs to remove from each node during a scale-down event. This value is not used for nodes with fixed compute shapes.

Sample:
56
     
metric
complex
on success

       
metric_type
string
on success
Allowed value is CPU_UTILIZATION.

Sample:
CPU_UTILIZATION
       
threshold
complex
on success

         
duration_in_minutes
integer
on success
This value is the minimum period of time the metric value exceeds the threshold value before the action is triggered. The value is in minutes.

Sample:
56
         
operator
string
on success
The comparison operator to use. Options are greater than (GT) or less than (LT).

Sample:
GT
         
value
integer
on success
Integer non-negative value. 0 < value < 100

Sample:
56
     
min_memory_per_node
integer
on success
For nodes with flexible compute shapes, this value is the minimum memory in GBs each node can be scaled-down to. This value is not used for nodes with fixed compute shapes.

Sample:
56
     
min_ocpus_per_node
integer
on success
For nodes with flexible compute shapes, this value is the minimum number of OCPUs each node can be scaled-down to. This value is not used for nodes with fixed compute shapes.

Sample:
56
     
ocpu_step_size
integer
on success
For nodes with flexible compute shapes, this value is the number of OCPUs to remove from each node during a scale-down event. This value is not used for nodes with fixed compute shapes.

Sample:
56
   
scale_in_config
complex
on success

     
metric
complex
on success

       
metric_type
string
on success
Allowed value is CPU_UTILIZATION.

Sample:
CPU_UTILIZATION
       
threshold
complex
on success

         
duration_in_minutes
integer
on success
This value is the minimum period of time the metric value exceeds the threshold value before the action is triggered. The value is in minutes.

Sample:
56
         
operator
string
on success
The comparison operator to use. Options are greater than (GT) or less than (LT).

Sample:
GT
         
value
integer
on success
Integer non-negative value. 0 < value < 100

Sample:
56
     
min_node_count
integer
on success
This value is the minimum number of nodes the cluster can be scaled-in to.

Sample:
56
     
step_size
integer
on success
This value is the number of nodes to remove during a scale-in event.

Sample:
56
   
scale_out_config
complex
on success

     
max_node_count
integer
on success
This value is the maximum number of nodes the cluster can be scaled-out to.

Sample:
56
     
metric
complex
on success

       
metric_type
string
on success
Allowed value is CPU_UTILIZATION.

Sample:
CPU_UTILIZATION
       
threshold
complex
on success

         
duration_in_minutes
integer
on success
This value is the minimum period of time the metric value exceeds the threshold value before the action is triggered. The value is in minutes.

Sample:
56
         
operator
string
on success
The comparison operator to use. Options are greater than (GT) or less than (LT).

Sample:
GT
         
value
integer
on success
Integer non-negative value. 0 < value < 100

Sample:
56
     
step_size
integer
on success
This value is the number of nodes to add during a scale-out event.

Sample:
56
   
scale_up_config
complex
on success

     
max_memory_per_node
integer
on success
For nodes with flexible compute shapes, this value is the maximum memory in GBs each node can be scaled-up to. This value is not used for nodes with fixed compute shapes.

Sample:
56
     
max_ocpus_per_node
integer
on success
For nodes with flexible compute shapes, this value is the maximum number of OCPUs each node can be scaled-up to. This value is not used for nodes with fixed compute shapes.

Sample:
56
     
memory_step_size
integer
on success
For nodes with flexible compute shapes, this value is the size of memory in GBs to add to each node during a scale-up event. This value is not used for nodes with fixed compute shapes.

Sample:
56
     
metric
complex
on success

       
metric_type
string
on success
Allowed value is CPU_UTILIZATION.

Sample:
CPU_UTILIZATION
       
threshold
complex
on success

         
duration_in_minutes
integer
on success
This value is the minimum period of time the metric value exceeds the threshold value before the action is triggered. The value is in minutes.

Sample:
56
         
operator
string
on success
The comparison operator to use. Options are greater than (GT) or less than (LT).

Sample:
GT
         
value
integer
on success
Integer non-negative value. 0 < value < 100

Sample:
56
     
ocpu_step_size
integer
on success
For nodes with flexible compute shapes, this value is the number of OCPUs to add to each node during a scale-up event. This value is not used for nodes with fixed compute shapes.

Sample:
56
   
schedule_details
complex
on success

     
schedule_type
string
on success
The type of schedule.

Sample:
DAY_BASED
     
time_and_horizontal_scaling_config
complex
on success

       
target_node_count
integer
on success
This value is the desired number of nodes in the cluster.

Sample:
56
       
time_recurrence
string
on success
Day/time recurrence (specified following RFC 5545) at which to trigger autoscaling action. Currently only WEEKLY frequency is supported. Days of the week are specified using BYDAY field. Time of the day is specified using BYHOUR and BYMINUTE fields. Other fields are not supported.

Sample:
time_recurrence_example
     
time_and_vertical_scaling_config
complex
on success

       
target_memory_per_node
integer
on success
For nodes with flexible compute shapes, this value is the desired memory in GBs on each node. This value is not used for nodes with fixed compute shapes.

Sample:
56
       
target_ocpus_per_node
integer
on success
For nodes with flexible compute shapes, this value is the desired OCPUs count on each node. This value is not used for nodes with fixed compute shapes.

Sample:
56
       
target_shape
string
on success
For nodes with fixed compute shapes, this value is the desired shape of each node. This value is not used for nodes with flexible compute shapes.

Sample:
target_shape_example
       
time_recurrence
string
on success
Day/time recurrence (specified following RFC 5545) at which to trigger autoscaling action. Currently only WEEKLY frequency is supported. Days of the week are specified using BYDAY field. Time of the day is specified using BYHOUR and BYMINUTE fields. Other fields are not supported.

Sample:
time_recurrence_example
   
timezone
string
on success
The time zone of the execution schedule, in IANA time zone database name format

Sample:
timezone_example
   
trigger_type
string
on success
The type of autoscaling trigger.

Sample:
METRIC_BASED
 
time_created
string
on success
The time the cluster was created, shown as an RFC 3339 formatted datetime string.

Sample:
2013-10-20T19:20:30+01:00
 
time_updated
string
on success
The time the autoscale configuration was updated, shown as an RFC 3339 formatted datetime string.

Sample:
2013-10-20T19:20:30+01:00


Authors

  • Oracle (@oracle)