Class ProfilingGroup

java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.Resource
software.amazon.awscdk.services.codeguruprofiler.ProfilingGroup
All Implemented Interfaces:
IResource, IProfilingGroup, software.amazon.jsii.JsiiSerializable, software.constructs.IConstruct, software.constructs.IDependable

@Generated(value="jsii-pacmak/1.98.0 (build 00b106d)", date="2024-05-08T21:35:04.380Z") @Stability(Stable) public class ProfilingGroup extends Resource implements IProfilingGroup
A new Profiling Group.

Example:

 // The execution role of your application that publishes to the ProfilingGroup via CodeGuru Profiler Profiling Agent. (the following is merely an example)
 Role publishAppRole = Role.Builder.create(this, "PublishAppRole")
         .assumedBy(new AccountRootPrincipal())
         .build();
 ProfilingGroup profilingGroup = new ProfilingGroup(this, "MyProfilingGroup");
 profilingGroup.grantPublish(publishAppRole);
 
  • Constructor Details

    • ProfilingGroup

      protected ProfilingGroup(software.amazon.jsii.JsiiObjectRef objRef)
    • ProfilingGroup

      protected ProfilingGroup(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
    • ProfilingGroup

      @Stability(Stable) public ProfilingGroup(@NotNull software.constructs.Construct scope, @NotNull String id, @Nullable ProfilingGroupProps props)
      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
      props -
    • ProfilingGroup

      @Stability(Stable) public ProfilingGroup(@NotNull software.constructs.Construct scope, @NotNull String id)
      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
  • Method Details

    • fromProfilingGroupArn

      @Stability(Stable) @NotNull public static IProfilingGroup fromProfilingGroupArn(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull String profilingGroupArn)
      Import an existing Profiling Group provided an ARN.

      Parameters:
      scope - The parent creating construct. This parameter is required.
      id - The construct's name. This parameter is required.
      profilingGroupArn - Profiling Group ARN. This parameter is required.
    • fromProfilingGroupName

      @Stability(Stable) @NotNull public static IProfilingGroup fromProfilingGroupName(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull String profilingGroupName)
      Import an existing Profiling Group provided a Profiling Group Name.

      Parameters:
      scope - The parent creating construct. This parameter is required.
      id - The construct's name. This parameter is required.
      profilingGroupName - Profiling Group Name. This parameter is required.
    • grantPublish

      @Stability(Stable) @NotNull public Grant grantPublish(@NotNull IGrantable grantee)
      Grant access to publish profiling information to the Profiling Group to the given identity.

      This will grant the following permissions:

      • codeguru-profiler:ConfigureAgent
      • codeguru-profiler:PostAgentProfile

      Specified by:
      grantPublish in interface IProfilingGroup
      Parameters:
      grantee - Principal to grant publish rights to. This parameter is required.
    • grantRead

      @Stability(Stable) @NotNull public Grant grantRead(@NotNull IGrantable grantee)
      Grant access to read profiling information from the Profiling Group to the given identity.

      This will grant the following permissions:

      • codeguru-profiler:GetProfile
      • codeguru-profiler:DescribeProfilingGroup

      Specified by:
      grantRead in interface IProfilingGroup
      Parameters:
      grantee - Principal to grant read rights to. This parameter is required.
    • getProfilingGroupArn

      @Stability(Stable) @NotNull public String getProfilingGroupArn()
      The ARN of the Profiling Group.
      Specified by:
      getProfilingGroupArn in interface IProfilingGroup
    • getProfilingGroupName

      @Stability(Stable) @NotNull public String getProfilingGroupName()
      The name of the Profiling Group.
      Specified by:
      getProfilingGroupName in interface IProfilingGroup