Class: Aws::CodeGuruProfiler::Client
- Inherits:
-
Seahorse::Client::Base
- Object
- Seahorse::Client::Base
- Aws::CodeGuruProfiler::Client
- Includes:
- Aws::ClientStubs
- Defined in:
- lib/aws-sdk-codeguruprofiler/client.rb
Overview
An API client for CodeGuruProfiler. To construct a client, you need to configure a ‘:region` and `:credentials`.
client = Aws::CodeGuruProfiler::Client.new(
region: region_name,
credentials: credentials,
# ...
)
For details on configuring region and credentials see the [developer guide](/sdk-for-ruby/v3/developer-guide/setup-config.html).
See #initialize for a full list of supported configuration options.
Class Attribute Summary collapse
- .identifier ⇒ Object readonly private
API Operations collapse
-
#add_notification_channels(params = {}) ⇒ Types::AddNotificationChannelsResponse
Add up to 2 anomaly notifications channels for a profiling group.
-
#batch_get_frame_metric_data(params = {}) ⇒ Types::BatchGetFrameMetricDataResponse
Returns the time series of values for a requested list of frame metrics from a time period.
-
#configure_agent(params = {}) ⇒ Types::ConfigureAgentResponse
Used by profiler agents to report their current state and to receive remote configuration updates.
-
#create_profiling_group(params = {}) ⇒ Types::CreateProfilingGroupResponse
Creates a profiling group.
-
#delete_profiling_group(params = {}) ⇒ Struct
Deletes a profiling group.
-
#describe_profiling_group(params = {}) ⇒ Types::DescribeProfilingGroupResponse
Returns a [ ‘ProfilingGroupDescription` ][1] object that contains information about the requested profiling group.
-
#get_findings_report_account_summary(params = {}) ⇒ Types::GetFindingsReportAccountSummaryResponse
Returns a list of [ ‘FindingsReportSummary` ][1] objects that contain analysis results for all profiling groups in your AWS account.
-
#get_notification_configuration(params = {}) ⇒ Types::GetNotificationConfigurationResponse
Get the current configuration for anomaly notifications for a profiling group.
-
#get_policy(params = {}) ⇒ Types::GetPolicyResponse
Returns the JSON-formatted resource-based policy on a profiling group.
-
#get_profile(params = {}) ⇒ Types::GetProfileResponse
Gets the aggregated profile of a profiling group for a specified time range.
-
#get_recommendations(params = {}) ⇒ Types::GetRecommendationsResponse
Returns a list of [ ‘Recommendation` ][1] objects that contain recommendations for a profiling group for a given time period.
-
#list_findings_reports(params = {}) ⇒ Types::ListFindingsReportsResponse
List the available reports for a given profiling group and time range.
-
#list_profile_times(params = {}) ⇒ Types::ListProfileTimesResponse
Lists the start times of the available aggregated profiles of a profiling group for an aggregation period within the specified time range.
-
#list_profiling_groups(params = {}) ⇒ Types::ListProfilingGroupsResponse
Returns a list of profiling groups.
-
#list_tags_for_resource(params = {}) ⇒ Types::ListTagsForResourceResponse
Returns a list of the tags that are assigned to a specified resource.
-
#post_agent_profile(params = {}) ⇒ Struct
Submits profiling data to an aggregated profile of a profiling group.
-
#put_permission(params = {}) ⇒ Types::PutPermissionResponse
Adds permissions to a profiling group’s resource-based policy that are provided using an action group.
-
#remove_notification_channel(params = {}) ⇒ Types::RemoveNotificationChannelResponse
Remove one anomaly notifications channel for a profiling group.
-
#remove_permission(params = {}) ⇒ Types::RemovePermissionResponse
Removes permissions from a profiling group’s resource-based policy that are provided using an action group.
-
#submit_feedback(params = {}) ⇒ Struct
Sends feedback to CodeGuru Profiler about whether the anomaly detected by the analysis is useful or not.
-
#tag_resource(params = {}) ⇒ Struct
Use to assign one or more tags to a resource.
-
#untag_resource(params = {}) ⇒ Struct
Use to remove one or more tags from a resource.
-
#update_profiling_group(params = {}) ⇒ Types::UpdateProfilingGroupResponse
Updates a profiling group.
Class Method Summary collapse
- .errors_module ⇒ Object private
Instance Method Summary collapse
- #build_request(operation_name, params = {}) ⇒ Object private
-
#initialize(options) ⇒ Client
constructor
A new instance of Client.
- #waiter_names ⇒ Object deprecated private Deprecated.
Constructor Details
#initialize(options) ⇒ Client
Returns a new instance of Client.
467 468 469 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 467 def initialize(*args) super end |
Class Attribute Details
.identifier ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
1797 1798 1799 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 1797 def identifier @identifier end |
Class Method Details
.errors_module ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
1800 1801 1802 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 1800 def errors_module Errors end |
Instance Method Details
#add_notification_channels(params = {}) ⇒ Types::AddNotificationChannelsResponse
Add up to 2 anomaly notifications channels for a profiling group.
511 512 513 514 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 511 def add_notification_channels(params = {}, = {}) req = build_request(:add_notification_channels, params) req.send_request() end |
#batch_get_frame_metric_data(params = {}) ⇒ Types::BatchGetFrameMetricDataResponse
Returns the time series of values for a requested list of frame metrics from a time period.
607 608 609 610 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 607 def batch_get_frame_metric_data(params = {}, = {}) req = build_request(:batch_get_frame_metric_data, params) req.send_request() end |
#build_request(operation_name, params = {}) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 1770 def build_request(operation_name, params = {}) handlers = @handlers.for(operation_name) tracer = config.telemetry_provider.tracer_provider.tracer( Aws::Telemetry.module_to_tracer_name('Aws::CodeGuruProfiler') ) context = Seahorse::Client::RequestContext.new( operation_name: operation_name, operation: config.api.operation(operation_name), client: self, params: params, config: config, tracer: tracer ) context[:gem_name] = 'aws-sdk-codeguruprofiler' context[:gem_version] = '1.50.0' Seahorse::Client::Request.new(handlers, context) end |
#configure_agent(params = {}) ⇒ Types::ConfigureAgentResponse
Used by profiler agents to report their current state and to receive remote configuration updates. For example, ‘ConfigureAgent` can be used to tell an agent whether to profile or not and for how long to return profiling data.
682 683 684 685 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 682 def configure_agent(params = {}, = {}) req = build_request(:configure_agent, params) req.send_request() end |
#create_profiling_group(params = {}) ⇒ Types::CreateProfilingGroupResponse
Creates a profiling group.
751 752 753 754 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 751 def create_profiling_group(params = {}, = {}) req = build_request(:create_profiling_group, params) req.send_request() end |
#delete_profiling_group(params = {}) ⇒ Struct
Deletes a profiling group.
773 774 775 776 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 773 def delete_profiling_group(params = {}, = {}) req = build_request(:delete_profiling_group, params) req.send_request() end |
#describe_profiling_group(params = {}) ⇒ Types::DescribeProfilingGroupResponse
Returns a [ ‘ProfilingGroupDescription` ][1] object that contains information about the requested profiling group.
[1]: docs.aws.amazon.com/codeguru/latest/profiler-api/API_ProfilingGroupDescription.html
817 818 819 820 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 817 def describe_profiling_group(params = {}, = {}) req = build_request(:describe_profiling_group, params) req.send_request() end |
#get_findings_report_account_summary(params = {}) ⇒ Types::GetFindingsReportAccountSummaryResponse
Returns a list of [ ‘FindingsReportSummary` ][1] objects that contain analysis results for all profiling groups in your AWS account.
[1]: docs.aws.amazon.com/codeguru/latest/profiler-api/API_FindingsReportSummary.html
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
886 887 888 889 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 886 def get_findings_report_account_summary(params = {}, = {}) req = build_request(:get_findings_report_account_summary, params) req.send_request() end |
#get_notification_configuration(params = {}) ⇒ Types::GetNotificationConfigurationResponse
Get the current configuration for anomaly notifications for a profiling group.
920 921 922 923 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 920 def get_notification_configuration(params = {}, = {}) req = build_request(:get_notification_configuration, params) req.send_request() end |
#get_policy(params = {}) ⇒ Types::GetPolicyResponse
Returns the JSON-formatted resource-based policy on a profiling group.
950 951 952 953 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 950 def get_policy(params = {}, = {}) req = build_request(:get_policy, params) req.send_request() end |
#get_profile(params = {}) ⇒ Types::GetProfileResponse
Gets the aggregated profile of a profiling group for a specified time range. Amazon CodeGuru Profiler collects posted agent profiles for a profiling group into aggregated profiles.
<note> <p> Because aggregated profiles expire over time <code>GetProfile</code> is not idempotent. </p> </note> <p> Specify the time range for the requested aggregated profile using 1 or 2 of the following parameters: <code>startTime</code>, <code>endTime</code>, <code>period</code>. The maximum time range allowed is 7 days. If you specify all 3 parameters, an exception is thrown. If you specify only <code>period</code>, the latest aggregated profile is returned. </p> <p> Aggregated profiles are available with aggregation periods of 5 minutes, 1 hour, and 1 day, aligned to UTC. The aggregation period of an aggregated profile determines how long it is retained. For more information, see <a href="https://docs.aws.amazon.com/codeguru/latest/profiler-api/API_AggregatedProfileTime.html"> <code>AggregatedProfileTime</code> </a>. The aggregated profile's aggregation period determines how long it is retained by CodeGuru Profiler. </p> <ul> <li> <p> If the aggregation period is 5 minutes, the aggregated profile is retained for 15 days. </p> </li> <li> <p> If the aggregation period is 1 hour, the aggregated profile is retained for 60 days. </p> </li> <li> <p> If the aggregation period is 1 day, the aggregated profile is retained for 3 years. </p> </li> </ul> <p>There are two use cases for calling <code>GetProfile</code>.</p> <ol> <li> <p> If you want to return an aggregated profile that already exists, use <a href="https://docs.aws.amazon.com/codeguru/latest/profiler-api/API_ListProfileTimes.html"> <code>ListProfileTimes</code> </a> to view the time ranges of existing aggregated profiles. Use them in a <code>GetProfile</code> request to return a specific, existing aggregated profile. </p> </li> <li> <p> If you want to return an aggregated profile for a time range that doesn't align with an existing aggregated profile, then CodeGuru Profiler makes a best effort to combine existing aggregated profiles from the requested time range and return them as one aggregated profile. </p> <p> If aggregated profiles do not exist for the full time range requested, then aggregated profiles for a smaller time range are returned. For example, if the requested time range is from 00:00 to 00:20, and the existing aggregated profiles are from 00:15 and 00:25, then the aggregated profiles from 00:15 to 00:20 are returned. </p> </li> </ol>
1028 1029 1030 1031 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 1028 def get_profile(params = {}, = {}) req = build_request(:get_profile, params) req.send_request() end |
#get_recommendations(params = {}) ⇒ Types::GetRecommendationsResponse
Returns a list of [ ‘Recommendation` ][1] objects that contain recommendations for a profiling group for a given time period. A list of [ `Anomaly` ][2] objects that contains details about anomalies detected in the profiling group for the same time period is also returned.
[1]: docs.aws.amazon.com/codeguru/latest/profiler-api/API_Recommendation.html [2]: docs.aws.amazon.com/codeguru/latest/profiler-api/API_Anomaly.html
1142 1143 1144 1145 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 1142 def get_recommendations(params = {}, = {}) req = build_request(:get_recommendations, params) req.send_request() end |
#list_findings_reports(params = {}) ⇒ Types::ListFindingsReportsResponse
List the available reports for a given profiling group and time range.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
1224 1225 1226 1227 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 1224 def list_findings_reports(params = {}, = {}) req = build_request(:list_findings_reports, params) req.send_request() end |
#list_profile_times(params = {}) ⇒ Types::ListProfileTimesResponse
Lists the start times of the available aggregated profiles of a profiling group for an aggregation period within the specified time range.
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
1306 1307 1308 1309 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 1306 def list_profile_times(params = {}, = {}) req = build_request(:list_profile_times, params) req.send_request() end |
#list_profiling_groups(params = {}) ⇒ Types::ListProfilingGroupsResponse
Returns a list of profiling groups. The profiling groups are returned as [ ‘ProfilingGroupDescription` ][1] objects.
[1]: docs.aws.amazon.com/codeguru/latest/profiler-api/API_ProfilingGroupDescription.html
The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.
1388 1389 1390 1391 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 1388 def list_profiling_groups(params = {}, = {}) req = build_request(:list_profiling_groups, params) req.send_request() end |
#list_tags_for_resource(params = {}) ⇒ Types::ListTagsForResourceResponse
Returns a list of the tags that are assigned to a specified resource.
1418 1419 1420 1421 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 1418 def (params = {}, = {}) req = build_request(:list_tags_for_resource, params) req.send_request() end |
#post_agent_profile(params = {}) ⇒ Struct
Submits profiling data to an aggregated profile of a profiling group. To get an aggregated profile that is created with this profiling data, use [ ‘GetProfile` ][1].
[1]: docs.aws.amazon.com/codeguru/latest/profiler-api/API_GetProfile.html
1468 1469 1470 1471 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 1468 def post_agent_profile(params = {}, = {}) req = build_request(:post_agent_profile, params) req.send_request() end |
#put_permission(params = {}) ⇒ Types::PutPermissionResponse
Adds permissions to a profiling group’s resource-based policy that are provided using an action group. If a profiling group doesn’t have a resource-based policy, one is created for it using the permissions in the action group and the roles and users in the ‘principals` parameter.
<p> The one supported action group that can be added is <code>agentPermission</code> which grants <code>ConfigureAgent</code> and <code>PostAgent</code> permissions. For more information, see <a href="https://docs.aws.amazon.com/codeguru/latest/profiler-ug/resource-based-policies.html">Resource-based policies in CodeGuru Profiler</a> in the <i>Amazon CodeGuru Profiler User Guide</i>, <a href="https://docs.aws.amazon.com/codeguru/latest/profiler-api/API_ConfigureAgent.html"> <code>ConfigureAgent</code> </a>, and <a href="https://docs.aws.amazon.com/codeguru/latest/profiler-api/API_PostAgentProfile.html"> <code>PostAgentProfile</code> </a>. </p> <p> The first time you call <code>PutPermission</code> on a profiling group, do not specify a <code>revisionId</code> because it doesn't have a resource-based policy. Subsequent calls must provide a <code>revisionId</code> to specify which revision of the resource-based policy to add the permissions to. </p> <p> The response contains the profiling group's JSON-formatted resource policy. </p>
1525 1526 1527 1528 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 1525 def (params = {}, = {}) req = build_request(:put_permission, params) req.send_request() end |
#remove_notification_channel(params = {}) ⇒ Types::RemoveNotificationChannelResponse
Remove one anomaly notifications channel for a profiling group.
1562 1563 1564 1565 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 1562 def remove_notification_channel(params = {}, = {}) req = build_request(:remove_notification_channel, params) req.send_request() end |
#remove_permission(params = {}) ⇒ Types::RemovePermissionResponse
Removes permissions from a profiling group’s resource-based policy that are provided using an action group. The one supported action group that can be removed is ‘agentPermission` which grants `ConfigureAgent` and `PostAgent` permissions. For more information, see [Resource-based policies in CodeGuru Profiler] in the *Amazon CodeGuru Profiler User Guide*, [ `ConfigureAgent` ][2], and [ `PostAgentProfile` ][3].
[1]: docs.aws.amazon.com/codeguru/latest/profiler-ug/resource-based-policies.html [2]: docs.aws.amazon.com/codeguru/latest/profiler-api/API_ConfigureAgent.html [3]: docs.aws.amazon.com/codeguru/latest/profiler-api/API_PostAgentProfile.html
1616 1617 1618 1619 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 1616 def (params = {}, = {}) req = build_request(:remove_permission, params) req.send_request() end |
#submit_feedback(params = {}) ⇒ Struct
Sends feedback to CodeGuru Profiler about whether the anomaly detected by the analysis is useful or not.
1658 1659 1660 1661 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 1658 def submit_feedback(params = {}, = {}) req = build_request(:submit_feedback, params) req.send_request() end |
#tag_resource(params = {}) ⇒ Struct
Use to assign one or more tags to a resource.
1687 1688 1689 1690 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 1687 def tag_resource(params = {}, = {}) req = build_request(:tag_resource, params) req.send_request() end |
#untag_resource(params = {}) ⇒ Struct
Use to remove one or more tags from a resource.
1715 1716 1717 1718 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 1715 def untag_resource(params = {}, = {}) req = build_request(:untag_resource, params) req.send_request() end |
#update_profiling_group(params = {}) ⇒ Types::UpdateProfilingGroupResponse
Updates a profiling group.
1761 1762 1763 1764 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 1761 def update_profiling_group(params = {}, = {}) req = build_request(:update_profiling_group, params) req.send_request() end |
#waiter_names ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
1790 1791 1792 |
# File 'lib/aws-sdk-codeguruprofiler/client.rb', line 1790 def waiter_names [] end |