OperationsInsightsClient

class oci.opsi.OperationsInsightsClient(config, **kwargs)

Use the Operations Insights API to perform data extraction operations to obtain database resource utilization, performance statistics, and reference information. For more information, see [About Oracle Cloud Infrastructure Operations Insights](https://docs.cloud.oracle.com/en-us/iaas/operations-insights/doc/operations-insights.html).

Methods

__init__(config, **kwargs) Creates a new service client
ingest_sql_bucket(compartment_id, …) The sqlbucket endpoint takes in a JSON payload, persists it in Operations Insights ingest pipeline.
ingest_sql_plan_lines(compartment_id, …) The SqlPlanLines endpoint takes in a JSON payload, persists it in Operation Insights ingest pipeline.
ingest_sql_text(compartment_id, database_id, …) The SqlText endpoint takes in a JSON payload, persists it in Operation Insights ingest pipeline.
list_database_insights(compartment_id, **kwargs) Lists database insight resources
list_sql_plans(compartment_id, database_id, …) Query SQL Warehouse to list the plan xml for a given SQL execution plan.
list_sql_searches(compartment_id, …) Search SQL by SQL Identifier across databases and get the SQL Text and the details of the databases executing the SQL for a given time period.
list_sql_texts(compartment_id, …) Query SQL Warehouse to get the full SQL Text for a SQL.
summarize_database_insight_resource_capacity_trend(…) Returns response with time series data (endTimestamp, capacity, baseCapacity) for the time period specified.
summarize_database_insight_resource_forecast_trend(…) Get Forecast predictions for CPU and Storage resources since a time in the past.
summarize_database_insight_resource_statistics(…) Lists the Resource statistics (usage,capacity, usage change percent, utilization percent, base capacity, isAutoScalingEnabled) for each database filtered by utilization level
summarize_database_insight_resource_usage(…) A cumulative distribution function is used to rank the usage data points per database within the specified time period.
summarize_database_insight_resource_usage_trend(…) Returns response with time series data (endTimestamp, usage, capacity) for the time period specified.
summarize_database_insight_resource_utilization_insight(…) Gets resources with current utilization (high and low) and projected utilization (high and low) for a resource type over specified time period.
summarize_sql_insights(compartment_id, **kwargs) Query SQL Warehouse to get the performance insights for SQLs taking greater than X% database time for a given time period across the given databases or database types.
summarize_sql_plan_insights(compartment_id, …) Query SQL Warehouse to get the performance insights on the execution plans for a given SQL for a given time period.
summarize_sql_response_time_distributions(…) Query SQL Warehouse to summarize the response time distribution of query executions for a given SQL for a given time period.
summarize_sql_statistics(compartment_id, …) Query SQL Warehouse to get the performance statistics for SQLs taking greater than X% database time for a given time period across the given databases or database types.
summarize_sql_statistics_time_series(…) Query SQL Warehouse to get the performance statistics time series for a given SQL across given databases for a given time period.
summarize_sql_statistics_time_series_by_plan(…) Query SQL Warehouse to get the performance statistics time series for a given SQL by execution plans for a given time period.
__init__(config, **kwargs)

Creates a new service client

Parameters:
  • config (dict) – Configuration keys and values as per SDK and Tool Configuration. The from_file() method can be used to load configuration from a file. Alternatively, a dict can be passed. You can validate_config the dict using validate_config()
  • service_endpoint (str) – (optional) The endpoint of the service to call using this client. For example https://iaas.us-ashburn-1.oraclecloud.com. If this keyword argument is not provided then it will be derived using the region in the config parameter. You should only provide this keyword argument if you have an explicit need to specify a service endpoint.
  • timeout (float or tuple(float, float)) – (optional) The connection and read timeouts for the client. The default values are connection timeout 10 seconds and read timeout 60 seconds. This keyword argument can be provided as a single float, in which case the value provided is used for both the read and connection timeouts, or as a tuple of two floats. If a tuple is provided then the first value is used as the connection timeout and the second value as the read timeout.
  • signer (AbstractBaseSigner) –

    (optional) The signer to use when signing requests made by the service client. The default is to use a Signer based on the values provided in the config parameter.

    One use case for this parameter is for Instance Principals authentication by passing an instance of InstancePrincipalsSecurityTokenSigner as the value for this keyword argument

  • retry_strategy (obj) –

    (optional) A retry strategy to apply to all calls made by this service client (i.e. at the client level). There is no retry strategy applied by default. Retry strategies can also be applied at the operation level by passing a retry_strategy keyword argument as part of calling the operation. Any value provided at the operation level will override whatever is specified at the client level.

    This should be one of the strategies available in the retry module. A convenience DEFAULT_RETRY_STRATEGY is also available. The specifics of the default retry strategy are described here.

ingest_sql_bucket(compartment_id, database_id, ingest_sql_bucket_details, **kwargs)

The sqlbucket endpoint takes in a JSON payload, persists it in Operations Insights ingest pipeline.

Parameters:
  • compartment_id (str) –

    (required) The OCID of the compartment.

  • database_id (str) –

    (required) Required OCID of the database.

  • ingest_sql_bucket_details (oci.opsi.models.IngestSqlBucketDetails) – (required) Collection of SQL bucket objects for a particular database.
  • opc_request_id (str) – (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
  • if_match (str) – (optional) Used for optimistic concurrency control. In the update or delete call for a resource, set the if-match parameter to the value of the etag from a previous get, create, or update response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource’s current etag value.
  • opc_retry_token (str) –

    (optional) A token that uniquely identifies a request that can be retried in case of a timeout or server error without risk of executing the same action again. Retry tokens expire after 24 hours.

    Note: Retry tokens can be invalidated before the 24 hour time limit due to conflicting operations, such as a resource being deleted or purged from the system.

  • retry_strategy (obj) –

    (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.

    This should be one of the strategies available in the retry module. A convenience DEFAULT_RETRY_STRATEGY is also available. The specifics of the default retry strategy are described here.

    To have this operation explicitly not perform any retries, pass an instance of NoneRetryStrategy.

Returns:

A Response object with data of type IngestSqlBucketResponseDetails

Return type:

Response

Example:

Click here to see an example of how to use ingest_sql_bucket API.

ingest_sql_plan_lines(compartment_id, database_id, ingest_sql_plan_lines_details, **kwargs)

The SqlPlanLines endpoint takes in a JSON payload, persists it in Operation Insights ingest pipeline.

Parameters:
  • compartment_id (str) –

    (required) The OCID of the compartment.

  • database_id (str) –

    (required) Required OCID of the database.

  • ingest_sql_plan_lines_details (oci.opsi.models.IngestSqlPlanLinesDetails) – (required) Collection of SQL plan line objects for a particular database.
  • opc_request_id (str) – (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
  • if_match (str) – (optional) Used for optimistic concurrency control. In the update or delete call for a resource, set the if-match parameter to the value of the etag from a previous get, create, or update response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource’s current etag value.
  • opc_retry_token (str) –

    (optional) A token that uniquely identifies a request that can be retried in case of a timeout or server error without risk of executing the same action again. Retry tokens expire after 24 hours.

    Note: Retry tokens can be invalidated before the 24 hour time limit due to conflicting operations, such as a resource being deleted or purged from the system.

  • retry_strategy (obj) –

    (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.

    This should be one of the strategies available in the retry module. A convenience DEFAULT_RETRY_STRATEGY is also available. The specifics of the default retry strategy are described here.

    To have this operation explicitly not perform any retries, pass an instance of NoneRetryStrategy.

Returns:

A Response object with data of type IngestSqlPlanLinesResponseDetails

Return type:

Response

Example:

Click here to see an example of how to use ingest_sql_plan_lines API.

ingest_sql_text(compartment_id, database_id, ingest_sql_text_details, **kwargs)

The SqlText endpoint takes in a JSON payload, persists it in Operation Insights ingest pipeline. Disclaimer: SQL text being uploaded explicitly via APIs is not masked. Any sensitive literals contained in the sqlFullText column should be masked prior to ingestion.

Parameters:
  • compartment_id (str) –

    (required) The OCID of the compartment.

  • database_id (str) –

    (required) Required OCID of the database.

  • ingest_sql_text_details (oci.opsi.models.IngestSqlTextDetails) – (required) Collection of SQL text objects for a particular database.
  • opc_request_id (str) – (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
  • if_match (str) – (optional) Used for optimistic concurrency control. In the update or delete call for a resource, set the if-match parameter to the value of the etag from a previous get, create, or update response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource’s current etag value.
  • opc_retry_token (str) –

    (optional) A token that uniquely identifies a request that can be retried in case of a timeout or server error without risk of executing the same action again. Retry tokens expire after 24 hours.

    Note: Retry tokens can be invalidated before the 24 hour time limit due to conflicting operations, such as a resource being deleted or purged from the system.

  • retry_strategy (obj) –

    (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.

    This should be one of the strategies available in the retry module. A convenience DEFAULT_RETRY_STRATEGY is also available. The specifics of the default retry strategy are described here.

    To have this operation explicitly not perform any retries, pass an instance of NoneRetryStrategy.

Returns:

A Response object with data of type IngestSqlTextResponseDetails

Return type:

Response

Example:

Click here to see an example of how to use ingest_sql_text API.

list_database_insights(compartment_id, **kwargs)

Lists database insight resources

Parameters:
  • compartment_id (str) –

    (required) The OCID of the compartment.

  • database_type (list[str]) –

    (optional) Filter by one or more database type. Possible values are ADW-S, ATP-S, ADW-D, ATP-D

    Allowed values are: “ADW-S”, “ATP-S”, “ADW-D”, “ATP-D”

  • database_id (list[str]) –

    (optional) Optional list of database OCIDs.

  • fields (list[str]) –

    (optional) Specifies the fields to return in a database summary response. By default all fields are returned if omitted.

    Allowed values are: “compartmentId”, “databaseName”, “databaseDisplayName”, “databaseType”, “databaseVersion”, “databaseHostNames”, “freeformTags”, “definedTags”

  • limit (int) –

    (optional) For list pagination. The maximum number of results per page, or items to return in a paginated “List” call. For important details about how pagination works, see List Pagination. Example: 50

  • page (str) –

    (optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.

  • sort_order (str) –

    (optional) The sort order to use, either ascending (ASC) or descending (DESC).

    Allowed values are: “ASC”, “DESC”

  • sort_by (str) –

    (optional) Database insight list sort options. If fields parameter is selected, the sortBy parameter must be one of the fields specified.

    Allowed values are: “databaseName”, “databaseDisplayName”, “databaseType”

  • opc_request_id (str) – (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
  • retry_strategy (obj) –

    (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.

    This should be one of the strategies available in the retry module. A convenience DEFAULT_RETRY_STRATEGY is also available. The specifics of the default retry strategy are described here.

    To have this operation explicitly not perform any retries, pass an instance of NoneRetryStrategy.

Returns:

A Response object with data of type DatabaseInsightsCollection

Return type:

Response

Example:

Click here to see an example of how to use list_database_insights API.

list_sql_plans(compartment_id, database_id, sql_identifier, plan_hash, **kwargs)

Query SQL Warehouse to list the plan xml for a given SQL execution plan. This returns a SqlPlanCollection object, but is currently limited to a single plan.

Parameters:
  • compartment_id (str) –

    (required) The OCID of the compartment.

  • database_id (str) –

    (required) Required OCID of the database.

  • sql_identifier (str) – (required) Unique SQL_ID for a SQL Statement. Example: 6rgjh9bjmy2s7
  • plan_hash (oci.opsi.models.list[int]) – (required) Unique plan hash for a SQL Plan of a particular SQL Statement. Example: 9820154385
  • page (str) –

    (optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.

  • opc_request_id (str) – (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
  • retry_strategy (obj) –

    (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.

    This should be one of the strategies available in the retry module. A convenience DEFAULT_RETRY_STRATEGY is also available. The specifics of the default retry strategy are described here.

    To have this operation explicitly not perform any retries, pass an instance of NoneRetryStrategy.

Returns:

A Response object with data of type SqlPlanCollection

Return type:

Response

Example:

Click here to see an example of how to use list_sql_plans API.

list_sql_searches(compartment_id, sql_identifier, **kwargs)

Search SQL by SQL Identifier across databases and get the SQL Text and the details of the databases executing the SQL for a given time period.

Parameters:
  • compartment_id (str) –

    (required) The OCID of the compartment.

  • sql_identifier (str) – (required) Unique SQL_ID for a SQL Statement. Example: 6rgjh9bjmy2s7
  • analysis_time_interval (str) – (optional) Specify time period in ISO 8601 format with respect to current time. Default is last 30 days represented by P30D. If timeInterval is specified, then timeIntervalStart and timeIntervalEnd will be ignored. Examples P90D (last 90 days), P4W (last 4 weeks), P2M (last 2 months), P1Y (last 12 months), . Maximum value allowed is 25 months prior to current time (P25M).
  • time_interval_start (datetime) – (optional) Analysis start time in UTC in ISO 8601 format(inclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). The minimum allowed value is 2 years prior to the current day. timeIntervalStart and timeIntervalEnd parameters are used together. If analysisTimeInterval is specified, this parameter is ignored.
  • time_interval_end (datetime) – (optional) Analysis end time in UTC in ISO 8601 format(exclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). timeIntervalStart and timeIntervalEnd are used together. If timeIntervalEnd is not specified, current time is used as timeIntervalEnd.
  • page (str) –

    (optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.

  • opc_request_id (str) – (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
  • retry_strategy (obj) –

    (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.

    This should be one of the strategies available in the retry module. A convenience DEFAULT_RETRY_STRATEGY is also available. The specifics of the default retry strategy are described here.

    To have this operation explicitly not perform any retries, pass an instance of NoneRetryStrategy.

Returns:

A Response object with data of type SqlSearchCollection

Return type:

Response

Example:

Click here to see an example of how to use list_sql_searches API.

list_sql_texts(compartment_id, sql_identifier, **kwargs)

Query SQL Warehouse to get the full SQL Text for a SQL.

Parameters:
  • compartment_id (str) –

    (required) The OCID of the compartment.

  • sql_identifier (oci.opsi.models.list[str]) – (required) One or more unique SQL_IDs for a SQL Statement. Example: 6rgjh9bjmy2s7
  • database_id (list[str]) –

    (optional) Optional list of database OCIDs.

  • page (str) –

    (optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.

  • opc_request_id (str) – (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
  • retry_strategy (obj) –

    (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.

    This should be one of the strategies available in the retry module. A convenience DEFAULT_RETRY_STRATEGY is also available. The specifics of the default retry strategy are described here.

    To have this operation explicitly not perform any retries, pass an instance of NoneRetryStrategy.

Returns:

A Response object with data of type SqlTextCollection

Return type:

Response

Example:

Click here to see an example of how to use list_sql_texts API.

summarize_database_insight_resource_capacity_trend(compartment_id, resource_metric, **kwargs)

Returns response with time series data (endTimestamp, capacity, baseCapacity) for the time period specified. The maximum time range for analysis is 2 years, hence this is intentionally not paginated.

Parameters:
  • compartment_id (str) –

    (required) The OCID of the compartment.

  • resource_metric (str) – (required) Filter by resource metric. Supported values are CPU and STORAGE.
  • analysis_time_interval (str) – (optional) Specify time period in ISO 8601 format with respect to current time. Default is last 30 days represented by P30D. If timeInterval is specified, then timeIntervalStart and timeIntervalEnd will be ignored. Examples P90D (last 90 days), P4W (last 4 weeks), P2M (last 2 months), P1Y (last 12 months), . Maximum value allowed is 25 months prior to current time (P25M).
  • time_interval_start (datetime) – (optional) Analysis start time in UTC in ISO 8601 format(inclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). The minimum allowed value is 2 years prior to the current day. timeIntervalStart and timeIntervalEnd parameters are used together. If analysisTimeInterval is specified, this parameter is ignored.
  • time_interval_end (datetime) – (optional) Analysis end time in UTC in ISO 8601 format(exclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). timeIntervalStart and timeIntervalEnd are used together. If timeIntervalEnd is not specified, current time is used as timeIntervalEnd.
  • database_type (list[str]) –

    (optional) Filter by one or more database type. Possible values are ADW-S, ATP-S, ADW-D, ATP-D

    Allowed values are: “ADW-S”, “ATP-S”, “ADW-D”, “ATP-D”

  • database_id (list[str]) –

    (optional) Optional list of database OCIDs.

  • utilization_level (str) –

    (optional) Filter by utilization level by the following buckets:

    • HIGH_UTILIZATION: DBs with utilization greater or equal than 75.
    • LOW_UTILIZATION: DBs with utilization lower than 25.
    • MEDIUM_HIGH_UTILIZATION: DBs with utilization greater or equal than 50 but lower than 75.
    • MEDIUM_LOW_UTILIZATION: DBs with utilization greater or equal than 25 but lower than 50.

    Allowed values are: “HIGH_UTILIZATION”, “LOW_UTILIZATION”, “MEDIUM_HIGH_UTILIZATION”, “MEDIUM_LOW_UTILIZATION”

  • page (str) –

    (optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.

  • sort_order (str) –

    (optional) The sort order to use, either ascending (ASC) or descending (DESC).

    Allowed values are: “ASC”, “DESC”

  • sort_by (str) –

    (optional) Sorts using end timestamp , capacity or baseCapacity

    Allowed values are: “endTimestamp”, “capacity”, “baseCapacity”

  • opc_request_id (str) – (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
  • retry_strategy (obj) –

    (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.

    This should be one of the strategies available in the retry module. A convenience DEFAULT_RETRY_STRATEGY is also available. The specifics of the default retry strategy are described here.

    To have this operation explicitly not perform any retries, pass an instance of NoneRetryStrategy.

Returns:

A Response object with data of type SummarizeDatabaseInsightResourceCapacityTrendAggregationCollection

Return type:

Response

Example:

Click here to see an example of how to use summarize_database_insight_resource_capacity_trend API.

summarize_database_insight_resource_forecast_trend(compartment_id, resource_metric, **kwargs)

Get Forecast predictions for CPU and Storage resources since a time in the past.

Parameters:
  • compartment_id (str) –

    (required) The OCID of the compartment.

  • resource_metric (str) – (required) Filter by resource metric. Supported values are CPU and STORAGE.
  • analysis_time_interval (str) – (optional) Specify time period in ISO 8601 format with respect to current time. Default is last 30 days represented by P30D. If timeInterval is specified, then timeIntervalStart and timeIntervalEnd will be ignored. Examples P90D (last 90 days), P4W (last 4 weeks), P2M (last 2 months), P1Y (last 12 months), . Maximum value allowed is 25 months prior to current time (P25M).
  • time_interval_start (datetime) – (optional) Analysis start time in UTC in ISO 8601 format(inclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). The minimum allowed value is 2 years prior to the current day. timeIntervalStart and timeIntervalEnd parameters are used together. If analysisTimeInterval is specified, this parameter is ignored.
  • time_interval_end (datetime) – (optional) Analysis end time in UTC in ISO 8601 format(exclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). timeIntervalStart and timeIntervalEnd are used together. If timeIntervalEnd is not specified, current time is used as timeIntervalEnd.
  • database_type (list[str]) –

    (optional) Filter by one or more database type. Possible values are ADW-S, ATP-S, ADW-D, ATP-D

    Allowed values are: “ADW-S”, “ATP-S”, “ADW-D”, “ATP-D”

  • database_id (list[str]) –

    (optional) Optional list of database OCIDs.

  • statistic (str) –

    (optional) Choose the type of statistic metric data to be used for forecasting.

    Allowed values are: “AVG”, “MAX”

  • forecast_days (int) – (optional) Number of days used for utilization forecast analysis.
  • forecast_model (str) –

    (optional) Choose algorithm model for the forecasting. Possible values:

    • LINEAR: Uses linear regression algorithm for forecasting.
    • ML_AUTO: Automatically detects best algorithm to use for forecasting.
    • ML_NO_AUTO: Automatically detects seasonality of the data for forecasting using linear or seasonal algorithm.

    Allowed values are: “LINEAR”, “ML_AUTO”, “ML_NO_AUTO”

  • utilization_level (str) –

    (optional) Filter by utilization level by the following buckets:

    • HIGH_UTILIZATION: DBs with utilization greater or equal than 75.
    • LOW_UTILIZATION: DBs with utilization lower than 25.
    • MEDIUM_HIGH_UTILIZATION: DBs with utilization greater or equal than 50 but lower than 75.
    • MEDIUM_LOW_UTILIZATION: DBs with utilization greater or equal than 25 but lower than 50.

    Allowed values are: “HIGH_UTILIZATION”, “LOW_UTILIZATION”, “MEDIUM_HIGH_UTILIZATION”, “MEDIUM_LOW_UTILIZATION”

  • confidence (int) – (optional) This parameter is used to change data’s confidence level, this data is ingested by the forecast algorithm. Confidence is the probability of an interval to contain the expected population parameter. Manipulation of this value will lead to different results. If not set, default confidence value is 95%.
  • page (str) –

    (optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.

  • opc_request_id (str) – (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
  • retry_strategy (obj) –

    (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.

    This should be one of the strategies available in the retry module. A convenience DEFAULT_RETRY_STRATEGY is also available. The specifics of the default retry strategy are described here.

    To have this operation explicitly not perform any retries, pass an instance of NoneRetryStrategy.

Returns:

A Response object with data of type SummarizeDatabaseInsightResourceForecastTrendAggregation

Return type:

Response

Example:

Click here to see an example of how to use summarize_database_insight_resource_forecast_trend API.

summarize_database_insight_resource_statistics(compartment_id, resource_metric, **kwargs)

Lists the Resource statistics (usage,capacity, usage change percent, utilization percent, base capacity, isAutoScalingEnabled) for each database filtered by utilization level

Parameters:
  • compartment_id (str) –

    (required) The OCID of the compartment.

  • resource_metric (str) – (required) Filter by resource metric. Supported values are CPU and STORAGE.
  • analysis_time_interval (str) – (optional) Specify time period in ISO 8601 format with respect to current time. Default is last 30 days represented by P30D. If timeInterval is specified, then timeIntervalStart and timeIntervalEnd will be ignored. Examples P90D (last 90 days), P4W (last 4 weeks), P2M (last 2 months), P1Y (last 12 months), . Maximum value allowed is 25 months prior to current time (P25M).
  • time_interval_start (datetime) – (optional) Analysis start time in UTC in ISO 8601 format(inclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). The minimum allowed value is 2 years prior to the current day. timeIntervalStart and timeIntervalEnd parameters are used together. If analysisTimeInterval is specified, this parameter is ignored.
  • time_interval_end (datetime) – (optional) Analysis end time in UTC in ISO 8601 format(exclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). timeIntervalStart and timeIntervalEnd are used together. If timeIntervalEnd is not specified, current time is used as timeIntervalEnd.
  • database_type (list[str]) –

    (optional) Filter by one or more database type. Possible values are ADW-S, ATP-S, ADW-D, ATP-D

    Allowed values are: “ADW-S”, “ATP-S”, “ADW-D”, “ATP-D”

  • database_id (list[str]) –

    (optional) Optional list of database OCIDs.

  • percentile (int) – (optional) Percentile values of daily usage to be used for computing the aggregate resource usage.
  • insight_by (str) – (optional) Return data of a specific insight Possible values are High Utilization, Low Utilization, Any ,High Utilization Forecast, Low Utilization Forecast
  • forecast_days (int) – (optional) Number of days used for utilization forecast analysis.
  • limit (int) –

    (optional) For list pagination. The maximum number of results per page, or items to return in a paginated “List” call. For important details about how pagination works, see List Pagination. Example: 50

  • page (str) –

    (optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.

  • sort_order (str) –

    (optional) The sort order to use, either ascending (ASC) or descending (DESC).

    Allowed values are: “ASC”, “DESC”

  • sort_by (str) –

    (optional) The order in which resource statistics records are listed

    Allowed values are: “utilizationPercent”, “usage”, “usageChangePercent”, “databaseName”, “databaseType”

  • opc_request_id (str) – (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
  • retry_strategy (obj) –

    (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.

    This should be one of the strategies available in the retry module. A convenience DEFAULT_RETRY_STRATEGY is also available. The specifics of the default retry strategy are described here.

    To have this operation explicitly not perform any retries, pass an instance of NoneRetryStrategy.

Returns:

A Response object with data of type SummarizeDatabaseInsightResourceStatisticsAggregationCollection

Return type:

Response

Example:

Click here to see an example of how to use summarize_database_insight_resource_statistics API.

summarize_database_insight_resource_usage(compartment_id, resource_metric, **kwargs)

A cumulative distribution function is used to rank the usage data points per database within the specified time period. For each database, the minimum data point with a ranking > the percentile value is included in the summation. Linear regression functions are used to calculate the usage change percentage.

Parameters:
  • compartment_id (str) –

    (required) The OCID of the compartment.

  • resource_metric (str) – (required) Filter by resource metric. Supported values are CPU and STORAGE.
  • analysis_time_interval (str) – (optional) Specify time period in ISO 8601 format with respect to current time. Default is last 30 days represented by P30D. If timeInterval is specified, then timeIntervalStart and timeIntervalEnd will be ignored. Examples P90D (last 90 days), P4W (last 4 weeks), P2M (last 2 months), P1Y (last 12 months), . Maximum value allowed is 25 months prior to current time (P25M).
  • time_interval_start (datetime) – (optional) Analysis start time in UTC in ISO 8601 format(inclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). The minimum allowed value is 2 years prior to the current day. timeIntervalStart and timeIntervalEnd parameters are used together. If analysisTimeInterval is specified, this parameter is ignored.
  • time_interval_end (datetime) – (optional) Analysis end time in UTC in ISO 8601 format(exclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). timeIntervalStart and timeIntervalEnd are used together. If timeIntervalEnd is not specified, current time is used as timeIntervalEnd.
  • database_type (list[str]) –

    (optional) Filter by one or more database type. Possible values are ADW-S, ATP-S, ADW-D, ATP-D

    Allowed values are: “ADW-S”, “ATP-S”, “ADW-D”, “ATP-D”

  • database_id (list[str]) –

    (optional) Optional list of database OCIDs.

  • page (str) –

    (optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.

  • percentile (int) – (optional) Percentile values of daily usage to be used for computing the aggregate resource usage.
  • opc_request_id (str) – (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
  • retry_strategy (obj) –

    (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.

    This should be one of the strategies available in the retry module. A convenience DEFAULT_RETRY_STRATEGY is also available. The specifics of the default retry strategy are described here.

    To have this operation explicitly not perform any retries, pass an instance of NoneRetryStrategy.

Returns:

A Response object with data of type SummarizeDatabaseInsightResourceUsageAggregation

Return type:

Response

Example:

Click here to see an example of how to use summarize_database_insight_resource_usage API.

summarize_database_insight_resource_usage_trend(compartment_id, resource_metric, **kwargs)

Returns response with time series data (endTimestamp, usage, capacity) for the time period specified. The maximum time range for analysis is 2 years, hence this is intentionally not paginated.

Parameters:
  • compartment_id (str) –

    (required) The OCID of the compartment.

  • resource_metric (str) – (required) Filter by resource metric. Supported values are CPU and STORAGE.
  • analysis_time_interval (str) – (optional) Specify time period in ISO 8601 format with respect to current time. Default is last 30 days represented by P30D. If timeInterval is specified, then timeIntervalStart and timeIntervalEnd will be ignored. Examples P90D (last 90 days), P4W (last 4 weeks), P2M (last 2 months), P1Y (last 12 months), . Maximum value allowed is 25 months prior to current time (P25M).
  • time_interval_start (datetime) – (optional) Analysis start time in UTC in ISO 8601 format(inclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). The minimum allowed value is 2 years prior to the current day. timeIntervalStart and timeIntervalEnd parameters are used together. If analysisTimeInterval is specified, this parameter is ignored.
  • time_interval_end (datetime) – (optional) Analysis end time in UTC in ISO 8601 format(exclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). timeIntervalStart and timeIntervalEnd are used together. If timeIntervalEnd is not specified, current time is used as timeIntervalEnd.
  • database_type (list[str]) –

    (optional) Filter by one or more database type. Possible values are ADW-S, ATP-S, ADW-D, ATP-D

    Allowed values are: “ADW-S”, “ATP-S”, “ADW-D”, “ATP-D”

  • database_id (list[str]) –

    (optional) Optional list of database OCIDs.

  • page (str) –

    (optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.

  • sort_order (str) –

    (optional) The sort order to use, either ascending (ASC) or descending (DESC).

    Allowed values are: “ASC”, “DESC”

  • sort_by (str) –

    (optional) Sorts using end timestamp, usage or capacity

    Allowed values are: “endTimestamp”, “usage”, “capacity”

  • opc_request_id (str) – (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
  • retry_strategy (obj) –

    (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.

    This should be one of the strategies available in the retry module. A convenience DEFAULT_RETRY_STRATEGY is also available. The specifics of the default retry strategy are described here.

    To have this operation explicitly not perform any retries, pass an instance of NoneRetryStrategy.

Returns:

A Response object with data of type SummarizeDatabaseInsightResourceUsageTrendAggregationCollection

Return type:

Response

Example:

Click here to see an example of how to use summarize_database_insight_resource_usage_trend API.

summarize_database_insight_resource_utilization_insight(compartment_id, resource_metric, **kwargs)

Gets resources with current utilization (high and low) and projected utilization (high and low) for a resource type over specified time period.

Parameters:
  • compartment_id (str) –

    (required) The OCID of the compartment.

  • resource_metric (str) – (required) Filter by resource metric. Supported values are CPU and STORAGE.
  • analysis_time_interval (str) – (optional) Specify time period in ISO 8601 format with respect to current time. Default is last 30 days represented by P30D. If timeInterval is specified, then timeIntervalStart and timeIntervalEnd will be ignored. Examples P90D (last 90 days), P4W (last 4 weeks), P2M (last 2 months), P1Y (last 12 months), . Maximum value allowed is 25 months prior to current time (P25M).
  • time_interval_start (datetime) – (optional) Analysis start time in UTC in ISO 8601 format(inclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). The minimum allowed value is 2 years prior to the current day. timeIntervalStart and timeIntervalEnd parameters are used together. If analysisTimeInterval is specified, this parameter is ignored.
  • time_interval_end (datetime) – (optional) Analysis end time in UTC in ISO 8601 format(exclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). timeIntervalStart and timeIntervalEnd are used together. If timeIntervalEnd is not specified, current time is used as timeIntervalEnd.
  • database_type (list[str]) –

    (optional) Filter by one or more database type. Possible values are ADW-S, ATP-S, ADW-D, ATP-D

    Allowed values are: “ADW-S”, “ATP-S”, “ADW-D”, “ATP-D”

  • database_id (list[str]) –

    (optional) Optional list of database OCIDs.

  • forecast_days (int) – (optional) Number of days used for utilization forecast analysis.
  • page (str) –

    (optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.

  • opc_request_id (str) – (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
  • retry_strategy (obj) –

    (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.

    This should be one of the strategies available in the retry module. A convenience DEFAULT_RETRY_STRATEGY is also available. The specifics of the default retry strategy are described here.

    To have this operation explicitly not perform any retries, pass an instance of NoneRetryStrategy.

Returns:

A Response object with data of type SummarizeDatabaseInsightResourceUtilizationInsightAggregation

Return type:

Response

Example:

Click here to see an example of how to use summarize_database_insight_resource_utilization_insight API.

summarize_sql_insights(compartment_id, **kwargs)

Query SQL Warehouse to get the performance insights for SQLs taking greater than X% database time for a given time period across the given databases or database types.

Parameters:
  • compartment_id (str) –

    (required) The OCID of the compartment.

  • database_type (list[str]) –

    (optional) Filter by one or more database type. Possible values are ADW-S, ATP-S, ADW-D, ATP-D

    Allowed values are: “ADW-S”, “ATP-S”, “ADW-D”, “ATP-D”

  • database_id (list[str]) –

    (optional) Optional list of database OCIDs.

  • database_time_pct_greater_than (float) – (optional) Filter sqls by percentage of db time.
  • analysis_time_interval (str) – (optional) Specify time period in ISO 8601 format with respect to current time. Default is last 30 days represented by P30D. If timeInterval is specified, then timeIntervalStart and timeIntervalEnd will be ignored. Examples P90D (last 90 days), P4W (last 4 weeks), P2M (last 2 months), P1Y (last 12 months), . Maximum value allowed is 25 months prior to current time (P25M).
  • time_interval_start (datetime) – (optional) Analysis start time in UTC in ISO 8601 format(inclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). The minimum allowed value is 2 years prior to the current day. timeIntervalStart and timeIntervalEnd parameters are used together. If analysisTimeInterval is specified, this parameter is ignored.
  • time_interval_end (datetime) – (optional) Analysis end time in UTC in ISO 8601 format(exclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). timeIntervalStart and timeIntervalEnd are used together. If timeIntervalEnd is not specified, current time is used as timeIntervalEnd.
  • page (str) –

    (optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.

  • opc_request_id (str) – (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
  • retry_strategy (obj) –

    (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.

    This should be one of the strategies available in the retry module. A convenience DEFAULT_RETRY_STRATEGY is also available. The specifics of the default retry strategy are described here.

    To have this operation explicitly not perform any retries, pass an instance of NoneRetryStrategy.

Returns:

A Response object with data of type SqlInsightAggregationCollection

Return type:

Response

Example:

Click here to see an example of how to use summarize_sql_insights API.

summarize_sql_plan_insights(compartment_id, database_id, sql_identifier, **kwargs)

Query SQL Warehouse to get the performance insights on the execution plans for a given SQL for a given time period.

Parameters:
  • compartment_id (str) –

    (required) The OCID of the compartment.

  • database_id (str) –

    (required) Required OCID of the database.

  • sql_identifier (str) – (required) Unique SQL_ID for a SQL Statement. Example: 6rgjh9bjmy2s7
  • analysis_time_interval (str) – (optional) Specify time period in ISO 8601 format with respect to current time. Default is last 30 days represented by P30D. If timeInterval is specified, then timeIntervalStart and timeIntervalEnd will be ignored. Examples P90D (last 90 days), P4W (last 4 weeks), P2M (last 2 months), P1Y (last 12 months), . Maximum value allowed is 25 months prior to current time (P25M).
  • time_interval_start (datetime) – (optional) Analysis start time in UTC in ISO 8601 format(inclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). The minimum allowed value is 2 years prior to the current day. timeIntervalStart and timeIntervalEnd parameters are used together. If analysisTimeInterval is specified, this parameter is ignored.
  • time_interval_end (datetime) – (optional) Analysis end time in UTC in ISO 8601 format(exclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). timeIntervalStart and timeIntervalEnd are used together. If timeIntervalEnd is not specified, current time is used as timeIntervalEnd.
  • page (str) –

    (optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.

  • opc_request_id (str) – (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
  • retry_strategy (obj) –

    (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.

    This should be one of the strategies available in the retry module. A convenience DEFAULT_RETRY_STRATEGY is also available. The specifics of the default retry strategy are described here.

    To have this operation explicitly not perform any retries, pass an instance of NoneRetryStrategy.

Returns:

A Response object with data of type SqlPlanInsightAggregationCollection

Return type:

Response

Example:

Click here to see an example of how to use summarize_sql_plan_insights API.

summarize_sql_response_time_distributions(compartment_id, database_id, sql_identifier, **kwargs)

Query SQL Warehouse to summarize the response time distribution of query executions for a given SQL for a given time period.

Parameters:
  • compartment_id (str) –

    (required) The OCID of the compartment.

  • database_id (str) –

    (required) Required OCID of the database.

  • sql_identifier (str) – (required) Unique SQL_ID for a SQL Statement. Example: 6rgjh9bjmy2s7
  • analysis_time_interval (str) – (optional) Specify time period in ISO 8601 format with respect to current time. Default is last 30 days represented by P30D. If timeInterval is specified, then timeIntervalStart and timeIntervalEnd will be ignored. Examples P90D (last 90 days), P4W (last 4 weeks), P2M (last 2 months), P1Y (last 12 months), . Maximum value allowed is 25 months prior to current time (P25M).
  • time_interval_start (datetime) – (optional) Analysis start time in UTC in ISO 8601 format(inclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). The minimum allowed value is 2 years prior to the current day. timeIntervalStart and timeIntervalEnd parameters are used together. If analysisTimeInterval is specified, this parameter is ignored.
  • time_interval_end (datetime) – (optional) Analysis end time in UTC in ISO 8601 format(exclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). timeIntervalStart and timeIntervalEnd are used together. If timeIntervalEnd is not specified, current time is used as timeIntervalEnd.
  • page (str) –

    (optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.

  • opc_request_id (str) – (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
  • retry_strategy (obj) –

    (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.

    This should be one of the strategies available in the retry module. A convenience DEFAULT_RETRY_STRATEGY is also available. The specifics of the default retry strategy are described here.

    To have this operation explicitly not perform any retries, pass an instance of NoneRetryStrategy.

Returns:

A Response object with data of type SqlResponseTimeDistributionAggregationCollection

Return type:

Response

Example:

Click here to see an example of how to use summarize_sql_response_time_distributions API.

summarize_sql_statistics(compartment_id, **kwargs)

Query SQL Warehouse to get the performance statistics for SQLs taking greater than X% database time for a given time period across the given databases or database types.

Parameters:
  • compartment_id (str) –

    (required) The OCID of the compartment.

  • database_type (list[str]) –

    (optional) Filter by one or more database type. Possible values are ADW-S, ATP-S, ADW-D, ATP-D

    Allowed values are: “ADW-S”, “ATP-S”, “ADW-D”, “ATP-D”

  • database_id (list[str]) –

    (optional) Optional list of database OCIDs.

  • database_time_pct_greater_than (float) – (optional) Filter sqls by percentage of db time.
  • sql_identifier (list[str]) – (optional) One or more unique SQL_IDs for a SQL Statement. Example: 6rgjh9bjmy2s7
  • analysis_time_interval (str) – (optional) Specify time period in ISO 8601 format with respect to current time. Default is last 30 days represented by P30D. If timeInterval is specified, then timeIntervalStart and timeIntervalEnd will be ignored. Examples P90D (last 90 days), P4W (last 4 weeks), P2M (last 2 months), P1Y (last 12 months), . Maximum value allowed is 25 months prior to current time (P25M).
  • time_interval_start (datetime) – (optional) Analysis start time in UTC in ISO 8601 format(inclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). The minimum allowed value is 2 years prior to the current day. timeIntervalStart and timeIntervalEnd parameters are used together. If analysisTimeInterval is specified, this parameter is ignored.
  • time_interval_end (datetime) – (optional) Analysis end time in UTC in ISO 8601 format(exclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). timeIntervalStart and timeIntervalEnd are used together. If timeIntervalEnd is not specified, current time is used as timeIntervalEnd.
  • limit (int) –

    (optional) For list pagination. The maximum number of results per page, or items to return in a paginated “List” call. For important details about how pagination works, see List Pagination. Example: 50

  • page (str) –

    (optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.

  • opc_request_id (str) – (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
  • sort_order (str) –

    (optional) The sort order to use, either ascending (ASC) or descending (DESC).

    Allowed values are: “ASC”, “DESC”

  • sort_by (str) –

    (optional) The field to use when sorting SQL statistics. Example: databaseTimeInSec

    Allowed values are: “databaseTimeInSec”, “executionsPerHour”, “executionsCount”, “cpuTimeInSec”, “ioTimeInSec”, “inefficientWaitTimeInSec”, “responseTimeInSec”, “planCount”, “variability”, “averageActiveSessions”, “databaseTimePct”, “inefficiencyInPct”, “changeInCpuTimeInPct”, “changeInIoTimeInPct”, “changeInInefficientWaitTimeInPct”, “changeInResponseTimeInPct”, “changeInAverageActiveSessionsInPct”, “changeInExecutionsPerHourInPct”, “changeInInefficiencyInPct”

  • category (list[str]) –

    (optional) Filter sqls by one or more performance categories.

    Allowed values are: “DEGRADING”, “VARIANT”, “INEFFICIENT”, “CHANGING_PLANS”, “IMPROVING”, “DEGRADING_VARIANT”, “DEGRADING_INEFFICIENT”, “DEGRADING_CHANGING_PLANS”, “DEGRADING_INCREASING_IO”, “DEGRADING_INCREASING_CPU”, “DEGRADING_INCREASING_INEFFICIENT_WAIT”, “DEGRADING_CHANGING_PLANS_AND_INCREASING_IO”, “DEGRADING_CHANGING_PLANS_AND_INCREASING_CPU”, “DEGRADING_CHANGING_PLANS_AND_INCREASING_INEFFICIENT_WAIT”, “VARIANT_INEFFICIENT”, “VARIANT_CHANGING_PLANS”, “VARIANT_INCREASING_IO”, “VARIANT_INCREASING_CPU”, “VARIANT_INCREASING_INEFFICIENT_WAIT”, “VARIANT_CHANGING_PLANS_AND_INCREASING_IO”, “VARIANT_CHANGING_PLANS_AND_INCREASING_CPU”, “VARIANT_CHANGING_PLANS_AND_INCREASING_INEFFICIENT_WAIT”, “INEFFICIENT_CHANGING_PLANS”, “INEFFICIENT_INCREASING_INEFFICIENT_WAIT”, “INEFFICIENT_CHANGING_PLANS_AND_INCREASING_INEFFICIENT_WAIT”

  • retry_strategy (obj) –

    (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.

    This should be one of the strategies available in the retry module. A convenience DEFAULT_RETRY_STRATEGY is also available. The specifics of the default retry strategy are described here.

    To have this operation explicitly not perform any retries, pass an instance of NoneRetryStrategy.

Returns:

A Response object with data of type SqlStatisticAggregationCollection

Return type:

Response

Example:

Click here to see an example of how to use summarize_sql_statistics API.

summarize_sql_statistics_time_series(compartment_id, sql_identifier, **kwargs)

Query SQL Warehouse to get the performance statistics time series for a given SQL across given databases for a given time period.

Parameters:
  • compartment_id (str) –

    (required) The OCID of the compartment.

  • sql_identifier (str) – (required) Unique SQL_ID for a SQL Statement. Example: 6rgjh9bjmy2s7
  • database_id (list[str]) –

    (optional) Optional list of database OCIDs.

  • analysis_time_interval (str) – (optional) Specify time period in ISO 8601 format with respect to current time. Default is last 30 days represented by P30D. If timeInterval is specified, then timeIntervalStart and timeIntervalEnd will be ignored. Examples P90D (last 90 days), P4W (last 4 weeks), P2M (last 2 months), P1Y (last 12 months), . Maximum value allowed is 25 months prior to current time (P25M).
  • time_interval_start (datetime) – (optional) Analysis start time in UTC in ISO 8601 format(inclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). The minimum allowed value is 2 years prior to the current day. timeIntervalStart and timeIntervalEnd parameters are used together. If analysisTimeInterval is specified, this parameter is ignored.
  • time_interval_end (datetime) – (optional) Analysis end time in UTC in ISO 8601 format(exclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). timeIntervalStart and timeIntervalEnd are used together. If timeIntervalEnd is not specified, current time is used as timeIntervalEnd.
  • page (str) –

    (optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.

  • opc_request_id (str) – (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
  • retry_strategy (obj) –

    (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.

    This should be one of the strategies available in the retry module. A convenience DEFAULT_RETRY_STRATEGY is also available. The specifics of the default retry strategy are described here.

    To have this operation explicitly not perform any retries, pass an instance of NoneRetryStrategy.

Returns:

A Response object with data of type SqlStatisticsTimeSeriesAggregationCollection

Return type:

Response

Example:

Click here to see an example of how to use summarize_sql_statistics_time_series API.

summarize_sql_statistics_time_series_by_plan(compartment_id, database_id, sql_identifier, **kwargs)

Query SQL Warehouse to get the performance statistics time series for a given SQL by execution plans for a given time period.

Parameters:
  • compartment_id (str) –

    (required) The OCID of the compartment.

  • database_id (str) –

    (required) Required OCID of the database.

  • sql_identifier (str) – (required) Unique SQL_ID for a SQL Statement. Example: 6rgjh9bjmy2s7
  • analysis_time_interval (str) – (optional) Specify time period in ISO 8601 format with respect to current time. Default is last 30 days represented by P30D. If timeInterval is specified, then timeIntervalStart and timeIntervalEnd will be ignored. Examples P90D (last 90 days), P4W (last 4 weeks), P2M (last 2 months), P1Y (last 12 months), . Maximum value allowed is 25 months prior to current time (P25M).
  • time_interval_start (datetime) – (optional) Analysis start time in UTC in ISO 8601 format(inclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). The minimum allowed value is 2 years prior to the current day. timeIntervalStart and timeIntervalEnd parameters are used together. If analysisTimeInterval is specified, this parameter is ignored.
  • time_interval_end (datetime) – (optional) Analysis end time in UTC in ISO 8601 format(exclusive). Example 2019-10-30T00:00:00Z (yyyy-MM-ddThh:mm:ssZ). timeIntervalStart and timeIntervalEnd are used together. If timeIntervalEnd is not specified, current time is used as timeIntervalEnd.
  • page (str) –

    (optional) For list pagination. The value of the opc-next-page response header from the previous “List” call. For important details about how pagination works, see List Pagination.

  • opc_request_id (str) – (optional) Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
  • retry_strategy (obj) –

    (optional) A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.

    This should be one of the strategies available in the retry module. A convenience DEFAULT_RETRY_STRATEGY is also available. The specifics of the default retry strategy are described here.

    To have this operation explicitly not perform any retries, pass an instance of NoneRetryStrategy.

Returns:

A Response object with data of type SqlStatisticsTimeSeriesByPlanAggregationCollection

Return type:

Response

Example:

Click here to see an example of how to use summarize_sql_statistics_time_series_by_plan API.