/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include #include #include namespace Aws { namespace PI { namespace Model { /** */ class AWS_PI_API GetResourceMetricsRequest : public PIRequest { public: GetResourceMetricsRequest(); // Service request name is the Operation name which will send this request out, // each operation should has unique request name, so that we can get operation's name from this request. // Note: this is not true for response, multiple operations may have the same response name, // so we can not get operation's name from response. inline virtual const char* GetServiceRequestName() const override { return "GetResourceMetrics"; } Aws::String SerializePayload() const override; Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override; /** *

The AWS service for which Performance Insights will return metrics. The only * valid value for ServiceType is: RDS

*/ inline const ServiceType& GetServiceType() const{ return m_serviceType; } /** *

The AWS service for which Performance Insights will return metrics. The only * valid value for ServiceType is: RDS

*/ inline bool ServiceTypeHasBeenSet() const { return m_serviceTypeHasBeenSet; } /** *

The AWS service for which Performance Insights will return metrics. The only * valid value for ServiceType is: RDS

*/ inline void SetServiceType(const ServiceType& value) { m_serviceTypeHasBeenSet = true; m_serviceType = value; } /** *

The AWS service for which Performance Insights will return metrics. The only * valid value for ServiceType is: RDS

*/ inline void SetServiceType(ServiceType&& value) { m_serviceTypeHasBeenSet = true; m_serviceType = std::move(value); } /** *

The AWS service for which Performance Insights will return metrics. The only * valid value for ServiceType is: RDS

*/ inline GetResourceMetricsRequest& WithServiceType(const ServiceType& value) { SetServiceType(value); return *this;} /** *

The AWS service for which Performance Insights will return metrics. The only * valid value for ServiceType is: RDS

*/ inline GetResourceMetricsRequest& WithServiceType(ServiceType&& value) { SetServiceType(std::move(value)); return *this;} /** *

An immutable, AWS Region-unique identifier for a data source. Performance * Insights gathers metrics from this data source.

To use an Amazon RDS * instance as a data source, you specify its DbiResourceId value - * for example: db-FAIHNTYBKTGAUSUZQYPDS2GW4A

*/ inline const Aws::String& GetIdentifier() const{ return m_identifier; } /** *

An immutable, AWS Region-unique identifier for a data source. Performance * Insights gathers metrics from this data source.

To use an Amazon RDS * instance as a data source, you specify its DbiResourceId value - * for example: db-FAIHNTYBKTGAUSUZQYPDS2GW4A

*/ inline bool IdentifierHasBeenSet() const { return m_identifierHasBeenSet; } /** *

An immutable, AWS Region-unique identifier for a data source. Performance * Insights gathers metrics from this data source.

To use an Amazon RDS * instance as a data source, you specify its DbiResourceId value - * for example: db-FAIHNTYBKTGAUSUZQYPDS2GW4A

*/ inline void SetIdentifier(const Aws::String& value) { m_identifierHasBeenSet = true; m_identifier = value; } /** *

An immutable, AWS Region-unique identifier for a data source. Performance * Insights gathers metrics from this data source.

To use an Amazon RDS * instance as a data source, you specify its DbiResourceId value - * for example: db-FAIHNTYBKTGAUSUZQYPDS2GW4A

*/ inline void SetIdentifier(Aws::String&& value) { m_identifierHasBeenSet = true; m_identifier = std::move(value); } /** *

An immutable, AWS Region-unique identifier for a data source. Performance * Insights gathers metrics from this data source.

To use an Amazon RDS * instance as a data source, you specify its DbiResourceId value - * for example: db-FAIHNTYBKTGAUSUZQYPDS2GW4A

*/ inline void SetIdentifier(const char* value) { m_identifierHasBeenSet = true; m_identifier.assign(value); } /** *

An immutable, AWS Region-unique identifier for a data source. Performance * Insights gathers metrics from this data source.

To use an Amazon RDS * instance as a data source, you specify its DbiResourceId value - * for example: db-FAIHNTYBKTGAUSUZQYPDS2GW4A

*/ inline GetResourceMetricsRequest& WithIdentifier(const Aws::String& value) { SetIdentifier(value); return *this;} /** *

An immutable, AWS Region-unique identifier for a data source. Performance * Insights gathers metrics from this data source.

To use an Amazon RDS * instance as a data source, you specify its DbiResourceId value - * for example: db-FAIHNTYBKTGAUSUZQYPDS2GW4A

*/ inline GetResourceMetricsRequest& WithIdentifier(Aws::String&& value) { SetIdentifier(std::move(value)); return *this;} /** *

An immutable, AWS Region-unique identifier for a data source. Performance * Insights gathers metrics from this data source.

To use an Amazon RDS * instance as a data source, you specify its DbiResourceId value - * for example: db-FAIHNTYBKTGAUSUZQYPDS2GW4A

*/ inline GetResourceMetricsRequest& WithIdentifier(const char* value) { SetIdentifier(value); return *this;} /** *

An array of one or more queries to perform. Each query must specify a * Performance Insights metric, and can optionally specify aggregation and * filtering criteria.

*/ inline const Aws::Vector& GetMetricQueries() const{ return m_metricQueries; } /** *

An array of one or more queries to perform. Each query must specify a * Performance Insights metric, and can optionally specify aggregation and * filtering criteria.

*/ inline bool MetricQueriesHasBeenSet() const { return m_metricQueriesHasBeenSet; } /** *

An array of one or more queries to perform. Each query must specify a * Performance Insights metric, and can optionally specify aggregation and * filtering criteria.

*/ inline void SetMetricQueries(const Aws::Vector& value) { m_metricQueriesHasBeenSet = true; m_metricQueries = value; } /** *

An array of one or more queries to perform. Each query must specify a * Performance Insights metric, and can optionally specify aggregation and * filtering criteria.

*/ inline void SetMetricQueries(Aws::Vector&& value) { m_metricQueriesHasBeenSet = true; m_metricQueries = std::move(value); } /** *

An array of one or more queries to perform. Each query must specify a * Performance Insights metric, and can optionally specify aggregation and * filtering criteria.

*/ inline GetResourceMetricsRequest& WithMetricQueries(const Aws::Vector& value) { SetMetricQueries(value); return *this;} /** *

An array of one or more queries to perform. Each query must specify a * Performance Insights metric, and can optionally specify aggregation and * filtering criteria.

*/ inline GetResourceMetricsRequest& WithMetricQueries(Aws::Vector&& value) { SetMetricQueries(std::move(value)); return *this;} /** *

An array of one or more queries to perform. Each query must specify a * Performance Insights metric, and can optionally specify aggregation and * filtering criteria.

*/ inline GetResourceMetricsRequest& AddMetricQueries(const MetricQuery& value) { m_metricQueriesHasBeenSet = true; m_metricQueries.push_back(value); return *this; } /** *

An array of one or more queries to perform. Each query must specify a * Performance Insights metric, and can optionally specify aggregation and * filtering criteria.

*/ inline GetResourceMetricsRequest& AddMetricQueries(MetricQuery&& value) { m_metricQueriesHasBeenSet = true; m_metricQueries.push_back(std::move(value)); return *this; } /** *

The date and time specifying the beginning of the requested time series data. * You can't specify a StartTime that's earlier than 7 days ago. The * value specified is inclusive - data points equal to or greater than * StartTime will be returned.

The value for * StartTime must be earlier than the value for * EndTime.

*/ inline const Aws::Utils::DateTime& GetStartTime() const{ return m_startTime; } /** *

The date and time specifying the beginning of the requested time series data. * You can't specify a StartTime that's earlier than 7 days ago. The * value specified is inclusive - data points equal to or greater than * StartTime will be returned.

The value for * StartTime must be earlier than the value for * EndTime.

*/ inline bool StartTimeHasBeenSet() const { return m_startTimeHasBeenSet; } /** *

The date and time specifying the beginning of the requested time series data. * You can't specify a StartTime that's earlier than 7 days ago. The * value specified is inclusive - data points equal to or greater than * StartTime will be returned.

The value for * StartTime must be earlier than the value for * EndTime.

*/ inline void SetStartTime(const Aws::Utils::DateTime& value) { m_startTimeHasBeenSet = true; m_startTime = value; } /** *

The date and time specifying the beginning of the requested time series data. * You can't specify a StartTime that's earlier than 7 days ago. The * value specified is inclusive - data points equal to or greater than * StartTime will be returned.

The value for * StartTime must be earlier than the value for * EndTime.

*/ inline void SetStartTime(Aws::Utils::DateTime&& value) { m_startTimeHasBeenSet = true; m_startTime = std::move(value); } /** *

The date and time specifying the beginning of the requested time series data. * You can't specify a StartTime that's earlier than 7 days ago. The * value specified is inclusive - data points equal to or greater than * StartTime will be returned.

The value for * StartTime must be earlier than the value for * EndTime.

*/ inline GetResourceMetricsRequest& WithStartTime(const Aws::Utils::DateTime& value) { SetStartTime(value); return *this;} /** *

The date and time specifying the beginning of the requested time series data. * You can't specify a StartTime that's earlier than 7 days ago. The * value specified is inclusive - data points equal to or greater than * StartTime will be returned.

The value for * StartTime must be earlier than the value for * EndTime.

*/ inline GetResourceMetricsRequest& WithStartTime(Aws::Utils::DateTime&& value) { SetStartTime(std::move(value)); return *this;} /** *

The date and time specifiying the end of the requested time series data. The * value specified is exclusive - data points less than (but not equal to) * EndTime will be returned.

The value for EndTime * must be later than the value for StartTime.

*/ inline const Aws::Utils::DateTime& GetEndTime() const{ return m_endTime; } /** *

The date and time specifiying the end of the requested time series data. The * value specified is exclusive - data points less than (but not equal to) * EndTime will be returned.

The value for EndTime * must be later than the value for StartTime.

*/ inline bool EndTimeHasBeenSet() const { return m_endTimeHasBeenSet; } /** *

The date and time specifiying the end of the requested time series data. The * value specified is exclusive - data points less than (but not equal to) * EndTime will be returned.

The value for EndTime * must be later than the value for StartTime.

*/ inline void SetEndTime(const Aws::Utils::DateTime& value) { m_endTimeHasBeenSet = true; m_endTime = value; } /** *

The date and time specifiying the end of the requested time series data. The * value specified is exclusive - data points less than (but not equal to) * EndTime will be returned.

The value for EndTime * must be later than the value for StartTime.

*/ inline void SetEndTime(Aws::Utils::DateTime&& value) { m_endTimeHasBeenSet = true; m_endTime = std::move(value); } /** *

The date and time specifiying the end of the requested time series data. The * value specified is exclusive - data points less than (but not equal to) * EndTime will be returned.

The value for EndTime * must be later than the value for StartTime.

*/ inline GetResourceMetricsRequest& WithEndTime(const Aws::Utils::DateTime& value) { SetEndTime(value); return *this;} /** *

The date and time specifiying the end of the requested time series data. The * value specified is exclusive - data points less than (but not equal to) * EndTime will be returned.

The value for EndTime * must be later than the value for StartTime.

*/ inline GetResourceMetricsRequest& WithEndTime(Aws::Utils::DateTime&& value) { SetEndTime(std::move(value)); return *this;} /** *

The granularity, in seconds, of the data points returned from Performance * Insights. A period can be as short as one second, or as long as one day (86400 * seconds). Valid values are:

  • 1 (one second)

    *
  • 60 (one minute)

  • 300 * (five minutes)

  • 3600 (one hour)

  • *

    86400 (twenty-four hours)

If you don't * specify PeriodInSeconds, then Performance Insights will choose a * value for you, with a goal of returning roughly 100-200 data points in the * response.

*/ inline int GetPeriodInSeconds() const{ return m_periodInSeconds; } /** *

The granularity, in seconds, of the data points returned from Performance * Insights. A period can be as short as one second, or as long as one day (86400 * seconds). Valid values are:

  • 1 (one second)

    *
  • 60 (one minute)

  • 300 * (five minutes)

  • 3600 (one hour)

  • *

    86400 (twenty-four hours)

If you don't * specify PeriodInSeconds, then Performance Insights will choose a * value for you, with a goal of returning roughly 100-200 data points in the * response.

*/ inline bool PeriodInSecondsHasBeenSet() const { return m_periodInSecondsHasBeenSet; } /** *

The granularity, in seconds, of the data points returned from Performance * Insights. A period can be as short as one second, or as long as one day (86400 * seconds). Valid values are:

  • 1 (one second)

    *
  • 60 (one minute)

  • 300 * (five minutes)

  • 3600 (one hour)

  • *

    86400 (twenty-four hours)

If you don't * specify PeriodInSeconds, then Performance Insights will choose a * value for you, with a goal of returning roughly 100-200 data points in the * response.

*/ inline void SetPeriodInSeconds(int value) { m_periodInSecondsHasBeenSet = true; m_periodInSeconds = value; } /** *

The granularity, in seconds, of the data points returned from Performance * Insights. A period can be as short as one second, or as long as one day (86400 * seconds). Valid values are:

  • 1 (one second)

    *
  • 60 (one minute)

  • 300 * (five minutes)

  • 3600 (one hour)

  • *

    86400 (twenty-four hours)

If you don't * specify PeriodInSeconds, then Performance Insights will choose a * value for you, with a goal of returning roughly 100-200 data points in the * response.

*/ inline GetResourceMetricsRequest& WithPeriodInSeconds(int value) { SetPeriodInSeconds(value); return *this;} /** *

The maximum number of items to return in the response. If more items exist * than the specified MaxRecords value, a pagination token is included * in the response so that the remaining results can be retrieved.

*/ inline int GetMaxResults() const{ return m_maxResults; } /** *

The maximum number of items to return in the response. If more items exist * than the specified MaxRecords value, a pagination token is included * in the response so that the remaining results can be retrieved.

*/ inline bool MaxResultsHasBeenSet() const { return m_maxResultsHasBeenSet; } /** *

The maximum number of items to return in the response. If more items exist * than the specified MaxRecords value, a pagination token is included * in the response so that the remaining results can be retrieved.

*/ inline void SetMaxResults(int value) { m_maxResultsHasBeenSet = true; m_maxResults = value; } /** *

The maximum number of items to return in the response. If more items exist * than the specified MaxRecords value, a pagination token is included * in the response so that the remaining results can be retrieved.

*/ inline GetResourceMetricsRequest& WithMaxResults(int value) { SetMaxResults(value); return *this;} /** *

An optional pagination token provided by a previous request. If this * parameter is specified, the response includes only records beyond the token, up * to the value specified by MaxRecords.

*/ inline const Aws::String& GetNextToken() const{ return m_nextToken; } /** *

An optional pagination token provided by a previous request. If this * parameter is specified, the response includes only records beyond the token, up * to the value specified by MaxRecords.

*/ inline bool NextTokenHasBeenSet() const { return m_nextTokenHasBeenSet; } /** *

An optional pagination token provided by a previous request. If this * parameter is specified, the response includes only records beyond the token, up * to the value specified by MaxRecords.

*/ inline void SetNextToken(const Aws::String& value) { m_nextTokenHasBeenSet = true; m_nextToken = value; } /** *

An optional pagination token provided by a previous request. If this * parameter is specified, the response includes only records beyond the token, up * to the value specified by MaxRecords.

*/ inline void SetNextToken(Aws::String&& value) { m_nextTokenHasBeenSet = true; m_nextToken = std::move(value); } /** *

An optional pagination token provided by a previous request. If this * parameter is specified, the response includes only records beyond the token, up * to the value specified by MaxRecords.

*/ inline void SetNextToken(const char* value) { m_nextTokenHasBeenSet = true; m_nextToken.assign(value); } /** *

An optional pagination token provided by a previous request. If this * parameter is specified, the response includes only records beyond the token, up * to the value specified by MaxRecords.

*/ inline GetResourceMetricsRequest& WithNextToken(const Aws::String& value) { SetNextToken(value); return *this;} /** *

An optional pagination token provided by a previous request. If this * parameter is specified, the response includes only records beyond the token, up * to the value specified by MaxRecords.

*/ inline GetResourceMetricsRequest& WithNextToken(Aws::String&& value) { SetNextToken(std::move(value)); return *this;} /** *

An optional pagination token provided by a previous request. If this * parameter is specified, the response includes only records beyond the token, up * to the value specified by MaxRecords.

*/ inline GetResourceMetricsRequest& WithNextToken(const char* value) { SetNextToken(value); return *this;} private: ServiceType m_serviceType; bool m_serviceTypeHasBeenSet; Aws::String m_identifier; bool m_identifierHasBeenSet; Aws::Vector m_metricQueries; bool m_metricQueriesHasBeenSet; Aws::Utils::DateTime m_startTime; bool m_startTimeHasBeenSet; Aws::Utils::DateTime m_endTime; bool m_endTimeHasBeenSet; int m_periodInSeconds; bool m_periodInSecondsHasBeenSet; int m_maxResults; bool m_maxResultsHasBeenSet; Aws::String m_nextToken; bool m_nextTokenHasBeenSet; }; } // namespace Model } // namespace PI } // namespace Aws