Skip to content

(logs): Query strings may multiple stats commands in a single query #34578

Open
@moltar

Description

@moltar

Describe the bug

Docs: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CWL_QuerySyntax-Stats.html#CWL_QuerySyntax-stats-multi

And the props only support one:

/**
* Uses log field values to calculate aggregate statistics.
*
* @default - no stats in QueryString
*/
readonly stats?: string;

Regression Issue

  • Select this option if this issue appears to be a regression.

Last Known Working CDK Library Version

latest

Expected Behavior

Support 2 stats.

You can use as many as two stats commands in a single query. This enables you to perform an additional aggregation on the output of the first aggregation.

Current Behavior

Supports 1 stats.

Reproduction Steps

Look at the code.

Possible Solution

Add support for 2 stats.

Additional Information/Context

No response

AWS CDK Library version (aws-cdk-lib)

N/A

AWS CDK CLI version

N/A

Node.js Version

N/A

OS

N/A

Language

TypeScript

Language Version

N/A

Other information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    @aws-cdk/aws-logsRelated to Amazon CloudWatch LogsbugThis issue is a bug.p2

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions