Skip to content
Merged
Changes from all 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
6 changes: 4 additions & 2 deletions apm-lambda-extension/cli/profile.js
Original file line number Diff line number Diff line change
Expand Up @@ -141,11 +141,12 @@ async function runScenario (scenario, config) {
}
)
})
}).catch(function (e) {
}).catch(async function (e) {
console.log('Error creating function')
if (e.statusCode === 409 && e.code === 'ResourceConflictException') {
console.log('Function already exists, deleting. Rerun profiler.')
cleanup(functionName)
await cleanup(functionName)
process.exit(1)
} else {
console.log(e)
}
Expand Down Expand Up @@ -176,6 +177,7 @@ function buildAndDeployArn (config) {

if (arns.indexOf(FLAG_LATEST) === -1) {
resolve()
return
}

// build latest arn, modify config to include it
Expand Down