oci_stack_monitoring_metric_extension

This resource provides the Metric Extension resource in Oracle Cloud Infrastructure Stack Monitoring service.

Creates a new metric extension resource for a given compartment

Example Usage

resource "oci_stack_monitoring_metric_extension" "test_metric_extension" {
	#Required
	collection_recurrences = var.metric_extension_collection_recurrences
	compartment_id = var.compartment_id
	display_name = var.metric_extension_display_name
	metric_list {
		#Required
		data_type = var.metric_extension_metric_list_data_type
		name = var.metric_extension_metric_list_name

		#Optional
		compute_expression = var.metric_extension_metric_list_compute_expression
		display_name = var.metric_extension_metric_list_display_name
		is_dimension = var.metric_extension_metric_list_is_dimension
		is_hidden = var.metric_extension_metric_list_is_hidden
		metric_category = var.metric_extension_metric_list_metric_category
		unit = var.metric_extension_metric_list_unit
	}
	name = var.metric_extension_name
	query_properties {
		#Required
		collection_method = var.metric_extension_query_properties_collection_method

		#Optional
		arguments = var.metric_extension_query_properties_arguments
		auto_row_prefix = var.metric_extension_query_properties_auto_row_prefix
		command = var.metric_extension_query_properties_command
		delimiter = var.metric_extension_query_properties_delimiter
		identity_metric = var.metric_extension_query_properties_identity_metric
		in_param_details {

			#Optional
			in_param_position = var.metric_extension_query_properties_in_param_details_in_param_position
			in_param_value = var.metric_extension_query_properties_in_param_details_in_param_value
		}
		is_metric_service_enabled = var.metric_extension_query_properties_is_metric_service_enabled
		jmx_attributes = var.metric_extension_query_properties_jmx_attributes
		managed_bean_query = var.metric_extension_query_properties_managed_bean_query
		out_param_details {

			#Optional
			out_param_position = var.metric_extension_query_properties_out_param_details_out_param_position
			out_param_type = var.metric_extension_query_properties_out_param_details_out_param_type
		}
		script_details {

			#Optional
			content = var.metric_extension_query_properties_script_details_content
			name = var.metric_extension_query_properties_script_details_name
		}
		sql_details {

			#Optional
			content = var.metric_extension_query_properties_sql_details_content
			script_file_name = var.metric_extension_query_properties_sql_details_script_file_name
		}
		sql_type = var.metric_extension_query_properties_sql_type
		starts_with = var.metric_extension_query_properties_starts_with
	}
	resource_type = var.metric_extension_resource_type

	#Optional
	description = var.metric_extension_description
}

Argument Reference

The following arguments are supported:

** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

Attributes Reference

The following attributes are exported:

Timeouts

The timeouts block allows you to specify timeouts for certain operations: * create - (Defaults to 20 minutes), when creating the Metric Extension * update - (Defaults to 20 minutes), when updating the Metric Extension * delete - (Defaults to 20 minutes), when destroying the Metric Extension

Import

MetricExtensions can be imported using the id, e.g.

$ terraform import oci_stack_monitoring_metric_extension.test_metric_extension "id"