Skip to content
Open
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
import * as cdk from 'aws-cdk-lib';
import * as integ from '@aws-cdk/integ-tests-alpha';
import * as rum from 'aws-cdk-lib/aws-rum';
import * as s3 from 'aws-cdk-lib/aws-s3';

const app = new cdk.App();

const stack = new cdk.Stack(app, 'RumAppMonitorDeobfuscationIntegrationTestStack');

// Create an S3 bucket for source maps
const sourceMapsBundle = new s3.Bucket(stack, 'SourceMapsBucket', {
removalPolicy: cdk.RemovalPolicy.DESTROY,
autoDeleteObjects: true,
});

// App monitor with JavaScript source maps enabled
const appMonitorWithSourceMaps = new rum.AppMonitor(stack, 'AppMonitorWithSourceMaps', {
appMonitorName: 'integ-test-app-with-source-maps',
domain: 'example.com',
deobfuscationConfiguration: {
javaScriptSourceMaps: {
enabled: true,
s3Uri: `s3://${sourceMapsBundle.bucketName}/source-maps/`,
},
},
});

// App monitor with source maps disabled
const appMonitorWithoutSourceMaps = new rum.AppMonitor(stack, 'AppMonitorWithoutSourceMaps', {
appMonitorName: 'integ-test-app-without-source-maps',
domain: 'example.com',
deobfuscationConfiguration: {
javaScriptSourceMaps: {
enabled: false,
},
},
});

// Outputs for verification
new cdk.CfnOutput(stack, 'AppMonitorWithSourceMapsId', {
value: appMonitorWithSourceMaps.appMonitorId,
});

new cdk.CfnOutput(stack, 'AppMonitorWithoutSourceMapsId', {
value: appMonitorWithoutSourceMaps.appMonitorId,
});

new cdk.CfnOutput(stack, 'SourceMapsBucketName', {
value: sourceMapsBundle.bucketName,
});

new integ.IntegTest(app, 'RumAppMonitorDeobfuscationIntegrationTest', {
testCases: [stack],
});
3 changes: 3 additions & 0 deletions packages/@aws-cdk/aws-rum-alpha/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
const baseConfig = require('@aws-cdk/cdk-build-tools/config/eslintrc');
baseConfig.parserOptions.project = __dirname + '/tsconfig.json';
module.exports = baseConfig;
28 changes: 28 additions & 0 deletions packages/@aws-cdk/aws-rum-alpha/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
*.js
*.js.map
*.d.ts
tsconfig.json
node_modules
*.generated.ts
dist
.jsii

.LAST_BUILD
.nyc_output
coverage
.nycrc
.LAST_PACKAGE
*.snk
nyc.config.js
!.eslintrc.js
!jest.config.js

# Include .jsiirc.json if it exists
!.jsiirc.json

# Include .npmignore if it exists
!.npmignore

# Exclude typescript source for javascript packages
exclude-typescript
junit.xml
109 changes: 109 additions & 0 deletions packages/@aws-cdk/aws-rum-alpha/.npmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,109 @@
# Don't include original .ts files when publishing
*.ts
!*.d.ts

# Include .jsiirc.json if it exists
!.jsiirc.json

# Include .npmignore if it exists
!.npmignore

# Exclude typescript source for javascript packages
exclude-typescript

# The basics
*.orig
.*.swp
.*.swo
*~
*.tmp
*.bak

# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# Runtime data
pids
*.pid
*.seed
*.pid.lock

# Coverage directory used by tools like istanbul
coverage

# nyc test coverage
.nyc_output

# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
.grunt

# Bower dependency directory (https://bower.io/)
bower_components

# node-waf configuration
.lock-wscript

# Compiled binary addons (https://nodejs.org/api/addons.html)
build/Release

# Dependency directories
node_modules/
jspm_packages/

# Typescript v1 declaration files
typings/

# Optional npm cache directory
.npm

# Optional eslint cache
.eslintcache

# Optional REPL history
.node_repl_history

# Output of 'npm pack'
*.tgz

# Yarn Integrity file
.yarn-integrity

# dotenv environment variables file
.env

# parcel-bundler cache (https://parceljs.org/)
.cache
.parcel-cache

# next.js build output
.next

# nuxt.js build output
.nuxt

# vuepress build output
.vuepress/dist

# Serverless directories
.serverless

# CDK Context & Staging files
.cdk.staging/
cdk.out/
**/cdk.out
dist
.LAST_PACKAGE
*.tsbuildinfo
test/
tsconfig.json
!.jsii
.LAST_BUILD
*.snk
junit.xml
!*.js
!*.lit.ts
.eslintrc.js
Loading
Loading