Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(cloudtrail): enable CloudTrail Insights on Trail #23099

Merged
merged 8 commits into from
Dec 7, 2022

Conversation

watany-dev
Copy link
Contributor

@watany-dev watany-dev commented Nov 26, 2022

After an issue is submitted, the specification is added and the implementation is such that the InsightType is selected.

fixes #8335


All Submissions:

Adding new Unconventional Dependencies:

  • This PR adds new unconventional dependencies following the process described here

New Features

  • Have you added the new feature to an integration test?
    • Did you use yarn integ to deploy the infrastructure and generate the snapshot (i.e. yarn integ without --dry-run)?

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license

@gitpod-io
Copy link

gitpod-io bot commented Nov 26, 2022

@github-actions github-actions bot added effort/small Small work item – less than a day of effort feature-request A feature should be added or improved. p2 admired-contributor [Pilot] contributed between 13-24 PRs to the CDK labels Nov 26, 2022
@aws-cdk-automation aws-cdk-automation requested a review from a team November 26, 2022 08:40
@Naumel
Copy link
Contributor

Naumel commented Nov 30, 2022

@Mergifyio update

@mergify
Copy link
Contributor

mergify bot commented Nov 30, 2022

update

✅ Branch has been successfully updated

@Naumel
Copy link
Contributor

Naumel commented Nov 30, 2022

I believe the following

aws-cdk-lib: aws-cloudtrail/test/integ.cloudtrail-insight.lit.ts:4:24 - error TS2307: Cannot find module '../../integ-tests' or its corresponding type declarations.
aws-cdk-lib: 4 import * as integ from '../../integ-tests';
aws-cdk-lib:                          ~~~~~~~~~~~~~~~~~~~

is relevant to the changes here.

@watany-dev
Copy link
Contributor Author

Hmmm, this error may not be immediately obvious because the integtest I have modified is not a relative path specification as shown below.
aws-cdk-lib:4 import * as integ from '... /... /integ-tests';

Suspicious part is aws-cdk-lib instead of @aws-cdk-lib?

@mrgrain
Copy link
Contributor

mrgrain commented Nov 30, 2022

Hmmm, this error may not be immediately obvious because the integtest I have modified is not a relative path specification as shown below. aws-cdk-lib:4 import * as integ from '... /... /integ-tests';

Suspicious part is aws-cdk-lib instead of @aws-cdk-lib?

Integration tests with the .lit.ts extensions are an older style that is also used in documentation examples. You'll have to do either one of:

  • Find the examples by searching for the file name (without ending) and replace them with hand-crafted inline examples
  • Remove the .lit from the filename

or

  • Write a completely new integration test without the .lit thingy
  • This one is only an option if it doesn't add unnecessary duplication (e.g. adding a single prop to an existing integ test doesn't justify having it's own test case)

@watany-dev
Copy link
Contributor Author

I am very pleased with your kind response. I will try the former method to resolve this.

@mrgrain mrgrain changed the title feat(cloudtrail): Enable CloudTrail Insights on Trail feat(cloudtrail): enable CloudTrail Insights on Trail Dec 5, 2022
/**
* Util element for InsightSelector
*/
export class InsightType {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[non-blocking] What are the reasons to use a class instead of an enum here?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My apologies. I'm just left with something that was created with expandability in mind during development.

@mergify
Copy link
Contributor

mergify bot commented Dec 7, 2022

Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: AutoBuildv2Project1C6BFA3F-wQm2hXv2jqQv
  • Commit ID: 563899b
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@mergify mergify bot merged commit 8a1460e into aws:main Dec 7, 2022
@mergify
Copy link
Contributor

mergify bot commented Dec 7, 2022

Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

@watany-dev watany-dev deleted the trail-insight branch December 7, 2022 13:19
brennanho pushed a commit to brennanho/aws-cdk that referenced this pull request Dec 9, 2022
After an issue is submitted, the specification is added and the implementation is such that the InsightType is selected.

fixes aws#8335 

----

### All Submissions:

* [x] Have you followed the guidelines in our [Contributing guide?](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md)

### Adding new Unconventional Dependencies:

* [ ] This PR adds new unconventional dependencies following the process described [here](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md/#adding-new-unconventional-dependencies)

### New Features

* [x] Have you added the new feature to an [integration test](https://github.com/aws/aws-cdk/blob/main/INTEGRATION_TESTS.md)?
	* [x] Did you use `yarn integ` to deploy the infrastructure and generate the snapshot (i.e. `yarn integ` without `--dry-run`)?

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
brennanho pushed a commit to brennanho/aws-cdk that referenced this pull request Jan 20, 2023
After an issue is submitted, the specification is added and the implementation is such that the InsightType is selected.

fixes aws#8335 

----

### All Submissions:

* [x] Have you followed the guidelines in our [Contributing guide?](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md)

### Adding new Unconventional Dependencies:

* [ ] This PR adds new unconventional dependencies following the process described [here](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md/#adding-new-unconventional-dependencies)

### New Features

* [x] Have you added the new feature to an [integration test](https://github.com/aws/aws-cdk/blob/main/INTEGRATION_TESTS.md)?
	* [x] Did you use `yarn integ` to deploy the infrastructure and generate the snapshot (i.e. `yarn integ` without `--dry-run`)?

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
brennanho pushed a commit to brennanho/aws-cdk that referenced this pull request Feb 22, 2023
After an issue is submitted, the specification is added and the implementation is such that the InsightType is selected.

fixes aws#8335 

----

### All Submissions:

* [x] Have you followed the guidelines in our [Contributing guide?](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md)

### Adding new Unconventional Dependencies:

* [ ] This PR adds new unconventional dependencies following the process described [here](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md/#adding-new-unconventional-dependencies)

### New Features

* [x] Have you added the new feature to an [integration test](https://github.com/aws/aws-cdk/blob/main/INTEGRATION_TESTS.md)?
	* [x] Did you use `yarn integ` to deploy the infrastructure and generate the snapshot (i.e. `yarn integ` without `--dry-run`)?

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
admired-contributor [Pilot] contributed between 13-24 PRs to the CDK effort/small Small work item – less than a day of effort feature-request A feature should be added or improved. p2
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Enable CloudTrail Insights on Trail
4 participants