AWS Tools for Windows PowerShell
Command Reference

AWS services or capabilities described in AWS Documentation may vary by region/location. Click Getting Started with Amazon AWS to see specific differences applicable to the China (Beijing) Region.

Synopsis

Calls the Amazon CloudWatch Application Signals CreateInstrumentationConfiguration API operation.

Syntax

New-CWASInstrumentationConfiguration
-AttributeFilter <Hashtable[]>
-CaptureConfiguration_CodeCapture_CaptureArgument <String[]>
-CaptureConfiguration_CodeCapture_CaptureLocal <String[]>
-CaptureConfiguration_CodeCapture_CaptureReturn <Boolean>
-CaptureConfiguration_CodeCapture_CaptureStackTrace <Boolean>
-Location_CodeLocation_ClassName <String>
-Location_CodeLocation_CodeUnit <String>
-Description <String>
-Environment <String>
-ExpiresAt <DateTime>
-Location_CodeLocation_FilePath <String>
-InstrumentationType <InstrumentationType>
-Location_CodeLocation_Language <ProgrammingLanguage>
-Location_CodeLocation_LineNumber <Int32>
-CaptureConfiguration_CodeCapture_CaptureLimits_MaxCollectionDepth <Int32>
-CaptureConfiguration_CodeCapture_CaptureLimits_MaxCollectionWidth <Int32>
-CaptureConfiguration_CodeCapture_CaptureLimits_MaxFieldsPerObject <Int32>
-CaptureConfiguration_CodeCapture_CaptureLimits_MaxHit <Int32>
-CaptureConfiguration_CodeCapture_CaptureLimits_MaxObjectDepth <Int32>
-CaptureConfiguration_CodeCapture_CaptureLimits_MaxStackFrame <Int32>
-CaptureConfiguration_CodeCapture_CaptureLimits_MaxStackTraceSize <Int32>
-CaptureConfiguration_CodeCapture_CaptureLimits_MaxStringLength <Int32>
-Location_CodeLocation_MethodName <String>
-Service <String>
-SignalType <DynamicInstrumentationSignalType>
-Tag <Tag[]>
-Select <String>
-Force <SwitchParameter>
-ClientConfig <AmazonApplicationSignalsConfig>

Description

Creates a dynamic instrumentation configuration for a specific code or endpoint location within a service and environment. Configurations are immutable after creation. For BREAKPOINT type configurations, they expire after 24 hours unless a shorter expiration is provided. For PROBE type configurations, they persist until explicitly deleted; an expiration cannot be set for PROBE configurations. If a configuration already exists for the same service, environment, signal type, and location, this operation returns a conflict instead of overwriting it. Use attribute filters and capture settings to control where the instrumentation runs and which data is collected.

Parameters

-AttributeFilter <Hashtable[]>
Client-side filters that target specific instances. Each object in the array is AND-matched on its keys, and multiple objects are OR-matched to decide where to apply the instrumentation. Starting with version 4 of the SDK this property will default to null. If no data for this property is returned from the service the property will also be null. This was changed to improve performance and allow the SDK and caller to distinguish between a property not set or a property being empty to clear out a value. To retain the previous SDK behavior set the AWSConfigs.InitializeCollections static property to true.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
AliasesAttributeFilters
-CaptureConfiguration_CodeCapture_CaptureArgument <String[]>
The function arguments to capture. Omit to capture defaults, use an empty list to capture none, use ["*"] to capture all arguments, or specify argument names to capture selectively (up to 10 entries). Starting with version 4 of the SDK this property will default to null. If no data for this property is returned from the service the property will also be null. This was changed to improve performance and allow the SDK and caller to distinguish between a property not set or a property being empty to clear out a value. To retain the previous SDK behavior set the AWSConfigs.InitializeCollections static property to true.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
AliasesCaptureConfiguration_CodeCapture_CaptureArguments
-CaptureConfiguration_CodeCapture_CaptureLimits_MaxCollectionDepth <Int32>
The maximum nesting depth to traverse inside collections. Defaults to 3.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
-CaptureConfiguration_CodeCapture_CaptureLimits_MaxCollectionWidth <Int32>
The maximum number of items to capture from any collection to prevent large payloads. Defaults to 10.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
-CaptureConfiguration_CodeCapture_CaptureLimits_MaxFieldsPerObject <Int32>
The maximum number of fields to capture for any object. Defaults to 10.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
-CaptureConfiguration_CodeCapture_CaptureLimits_MaxHit <Int32>
The maximum number of times the instrumentation point can be hit before it is automatically disabled. Defaults to 100.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
AliasesCaptureConfiguration_CodeCapture_CaptureLimits_MaxHits
-CaptureConfiguration_CodeCapture_CaptureLimits_MaxObjectDepth <Int32>
The maximum depth for nested object traversal when capturing structured data. Defaults to 3.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
-CaptureConfiguration_CodeCapture_CaptureLimits_MaxStackFrame <Int32>
The maximum number of stack frames to capture in stack traces. Defaults to 2.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
AliasesCaptureConfiguration_CodeCapture_CaptureLimits_MaxStackFrames
-CaptureConfiguration_CodeCapture_CaptureLimits_MaxStackTraceSize <Int32>
The maximum total size, in bytes, of a captured stack trace. Defaults to 1000.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
-CaptureConfiguration_CodeCapture_CaptureLimits_MaxStringLength <Int32>
The maximum length of captured string values in characters. Strings longer than this are truncated. Defaults to 128.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
-CaptureConfiguration_CodeCapture_CaptureLocal <String[]>
The local variables to capture by name. Omit or pass an empty list to capture none. You can specify up to 20 names. Starting with version 4 of the SDK this property will default to null. If no data for this property is returned from the service the property will also be null. This was changed to improve performance and allow the SDK and caller to distinguish between a property not set or a property being empty to clear out a value. To retain the previous SDK behavior set the AWSConfigs.InitializeCollections static property to true.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
AliasesCaptureConfiguration_CodeCapture_CaptureLocals
-CaptureConfiguration_CodeCapture_CaptureReturn <Boolean>
Whether to capture the return value. Defaults to false.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
-CaptureConfiguration_CodeCapture_CaptureStackTrace <Boolean>
Whether to capture a stack trace when the instrumentation point is hit. Defaults to true.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
Amazon.PowerShell.Cmdlets.CWAS.AmazonApplicationSignalsClientCmdlet.ClientConfig
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
-Description <String>
An optional short description (up to 50 characters) that explains the purpose of this instrumentation.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
-Environment <String>
The environment that the service is running in, such as eks:cluster-prod/namespace or ec2:production.
Required?True
Position?Named
Accept pipeline input?True (ByPropertyName)
-ExpiresAt <DateTime>
For BREAKPOINT: optional, defaults to 24 hours, must be between 5 min and 24 hours. For PROBE: not supported. PROBE configurations are permanent and persist until explicitly deleted.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
This parameter overrides confirmation prompts to force the cmdlet to continue its operation. This parameter should always be used with caution.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
-InstrumentationType <InstrumentationType>
Type of instrumentation: BREAKPOINT (temporary) or PROBE (permanent)
Required?True
Position?Named
Accept pipeline input?True (ByPropertyName)
-Location_CodeLocation_ClassName <String>
The class or type name that contains the method. This is required for Java and optional for Python module-level functions.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
-Location_CodeLocation_CodeUnit <String>
The package, module, or namespace that contains the target code, for example com.amazon.payment or payment_service.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
-Location_CodeLocation_FilePath <String>
The source file path relative to the project or source root, such as src/payment/PaymentProcessor.java or src/payment/PaymentProcessor.py.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
-Location_CodeLocation_Language <ProgrammingLanguage>
The programming language for this instrumentation point, such as Java, Python, or JavaScript.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
-Location_CodeLocation_LineNumber <Int32>
The line number to instrument. Provide this to disambiguate overloaded methods and to target a specific line when needed.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
-Location_CodeLocation_MethodName <String>
The method or function name to instrument, such as validateCreditCard or __init__.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
-Select <String>
Use the -Select parameter to control the cmdlet output. The default value is '*'. Specifying -Select '*' will result in the cmdlet returning the whole service response (Amazon.ApplicationSignals.Model.CreateInstrumentationConfigurationResponse). Specifying the name of a property of type Amazon.ApplicationSignals.Model.CreateInstrumentationConfigurationResponse will result in that property being returned. Specifying -Select '^ParameterName' will result in the cmdlet returning the selected cmdlet parameter value.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
-Service <String>
The name of the service to instrument. This should match the service.name resource attribute reported by the application.
Required?True
Position?Named
Accept pipeline input?True (ByPropertyName)
The telemetry signal type to emit for this instrumentation. The supported value is SNAPSHOT.
Required?True
Position?Named
Accept pipeline input?True (ByPropertyName)
-Tag <Tag[]>
An optional list of key-value pairs to associate with the instrumentation configuration. Tags can help you organize and categorize your resources. Starting with version 4 of the SDK this property will default to null. If no data for this property is returned from the service the property will also be null. This was changed to improve performance and allow the SDK and caller to distinguish between a property not set or a property being empty to clear out a value. To retain the previous SDK behavior set the AWSConfigs.InitializeCollections static property to true.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
AliasesTags

Common Credential and Region Parameters

-AccessKey <String>
The AWS access key for the user account. This can be a temporary access key if the corresponding session token is supplied to the -SessionToken parameter.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
AliasesAK
-Credential <AWSCredentials>
An AWSCredentials object instance containing access and secret key information, and optionally a token for session-based credentials.
Required?False
Position?Named
Accept pipeline input?True (ByValue, ByPropertyName)
-EndpointUrl <String>
The endpoint to make the call against.Note: This parameter is primarily for internal AWS use and is not required/should not be specified for normal usage. The cmdlets normally determine which endpoint to call based on the region specified to the -Region parameter or set as default in the shell (via Set-DefaultAWSRegion). Only specify this parameter if you must direct the call to a specific custom endpoint.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
-NetworkCredential <PSCredential>
Used with SAML-based authentication when ProfileName references a SAML role profile. Contains the network credentials to be supplied during authentication with the configured identity provider's endpoint. This parameter is not required if the user's default network identity can or should be used during authentication.
Required?False
Position?Named
Accept pipeline input?True (ByValue, ByPropertyName)
-ProfileLocation <String>
Used to specify the name and location of the ini-format credential file (shared with the AWS CLI and other AWS SDKs)If this optional parameter is omitted this cmdlet will search the encrypted credential file used by the AWS SDK for .NET and AWS Toolkit for Visual Studio first. If the profile is not found then the cmdlet will search in the ini-format credential file at the default location: (user's home directory)\.aws\credentials.If this parameter is specified then this cmdlet will only search the ini-format credential file at the location given.As the current folder can vary in a shell or during script execution it is advised that you use specify a fully qualified path instead of a relative path.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
AliasesAWSProfilesLocation, ProfilesLocation
-ProfileName <String>
The user-defined name of an AWS credentials or SAML-based role profile containing credential information. The profile is expected to be found in the secure credential file shared with the AWS SDK for .NET and AWS Toolkit for Visual Studio. You can also specify the name of a profile stored in the .ini-format credential file used with the AWS CLI and other AWS SDKs.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
AliasesStoredCredentials, AWSProfileName
-Region <Object>
The system name of an AWS region or an AWSRegion instance. This governs the endpoint that will be used when calling service operations. Note that the AWS resources referenced in a call are usually region-specific.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
AliasesRegionToCall
-SecretKey <String>
The AWS secret key for the user account. This can be a temporary secret key if the corresponding session token is supplied to the -SessionToken parameter.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
AliasesSK, SecretAccessKey
-SessionToken <String>
The session token if the access and secret keys are temporary session-based credentials.
Required?False
Position?Named
Accept pipeline input?True (ByPropertyName)
AliasesST

Outputs

This cmdlet returns an Amazon.ApplicationSignals.Model.CreateInstrumentationConfigurationResponse object containing multiple properties.

Supported Version

AWS Tools for PowerShell: 2.x.y.z