Skip to content

Commit

Permalink
Merge pull request #1334 from bugsnag/integration/aws-lambda
Browse files Browse the repository at this point in the history
[ROAD-756] AWS Lambda support
  • Loading branch information
bengourley authored Mar 16, 2021
2 parents f42ea9e + 4347759 commit 2d2f358
Show file tree
Hide file tree
Showing 175 changed files with 3,567 additions and 232 deletions.
12 changes: 12 additions & 0 deletions .buildkite/pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,18 @@ steps:
message: '${BUILDKITE_MESSAGE}'
async: true

- label: ':aws-lambda: AWS Lambda tests'
timeout_in_minutes: 35
agents:
queue: 'opensource-mac-aws-sam'
commands:
# force the NPM registry as the default on CI is artifactory, which can't
# currently install from our lockfile
- npm ci --registry https://registry.npmjs.org
- cd test/aws-lambda
- bundle install
- bundle exec maze-runner

#
# Core tests and checks
#
Expand Down
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

## TBD

### Added

- (plugin-aws-lambda): Add support for Node.js on AWS Lambda. See the [docs](https://docs.bugsnag.com/platforms/javascript/aws-lambda/) for usage. [#1334](https://github.com/bugsnag/bugsnag-js/pull/1334)

### Changed

- (plugin-koa): Ensure `ctx.request.body` is present on the event's request property by collecting it at the last possible moment [#1292](https://github.com/bugsnag/bugsnag-js/pull/1292)
Expand Down
2 changes: 2 additions & 0 deletions jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,8 @@ module.exports = {
]),
project('node plugins', [
'delivery-node',
'in-flight',
'plugin-aws-lambda',
'plugin-express',
'plugin-koa',
'plugin-restify',
Expand Down
2 changes: 1 addition & 1 deletion lerna.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@
"packages": [
"packages/*"
],
"version": "7.8.2"
"version": "7.9.0-alpha.0"
}
2 changes: 1 addition & 1 deletion packages/browser/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

38 changes: 19 additions & 19 deletions packages/browser/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@bugsnag/browser",
"version": "7.7.0",
"version": "7.9.0-alpha.0",
"main": "dist/bugsnag.js",
"types": "types/bugsnag.d.ts",
"description": "Bugsnag error reporter for browser JavaScript",
Expand Down Expand Up @@ -32,29 +32,29 @@
"license": "MIT",
"devDependencies": {
"@bugsnag/core": "^7.0.1",
"@bugsnag/delivery-x-domain-request": "^7.7.0",
"@bugsnag/delivery-xml-http-request": "^7.7.0",
"@bugsnag/plugin-app-duration": "^7.7.0",
"@bugsnag/plugin-browser-context": "^7.7.0",
"@bugsnag/plugin-browser-device": "^7.7.0",
"@bugsnag/plugin-browser-request": "^7.7.0",
"@bugsnag/plugin-browser-session": "^7.7.0",
"@bugsnag/plugin-client-ip": "^7.7.0",
"@bugsnag/plugin-console-breadcrumbs": "^7.7.0",
"@bugsnag/plugin-inline-script-content": "^7.7.0",
"@bugsnag/plugin-interaction-breadcrumbs": "^7.7.0",
"@bugsnag/plugin-navigation-breadcrumbs": "^7.7.0",
"@bugsnag/plugin-network-breadcrumbs": "^7.7.0",
"@bugsnag/plugin-simple-throttle": "^7.7.0",
"@bugsnag/plugin-strip-query-string": "^7.7.0",
"@bugsnag/plugin-window-onerror": "^7.7.0",
"@bugsnag/plugin-window-unhandled-rejection": "^7.7.0",
"@bugsnag/delivery-x-domain-request": "^7.9.0-alpha.0",
"@bugsnag/delivery-xml-http-request": "^7.9.0-alpha.0",
"@bugsnag/plugin-app-duration": "^7.9.0-alpha.0",
"@bugsnag/plugin-browser-context": "^7.9.0-alpha.0",
"@bugsnag/plugin-browser-device": "^7.9.0-alpha.0",
"@bugsnag/plugin-browser-request": "^7.9.0-alpha.0",
"@bugsnag/plugin-browser-session": "^7.9.0-alpha.0",
"@bugsnag/plugin-client-ip": "^7.9.0-alpha.0",
"@bugsnag/plugin-console-breadcrumbs": "^7.9.0-alpha.0",
"@bugsnag/plugin-inline-script-content": "^7.9.0-alpha.0",
"@bugsnag/plugin-interaction-breadcrumbs": "^7.9.0-alpha.0",
"@bugsnag/plugin-navigation-breadcrumbs": "^7.9.0-alpha.0",
"@bugsnag/plugin-network-breadcrumbs": "^7.9.0-alpha.0",
"@bugsnag/plugin-simple-throttle": "^7.9.0-alpha.0",
"@bugsnag/plugin-strip-query-string": "^7.9.0-alpha.0",
"@bugsnag/plugin-window-onerror": "^7.9.0-alpha.0",
"@bugsnag/plugin-window-unhandled-rejection": "^7.9.0-alpha.0",
"cloudfront": "^0.4.1",
"knox": "^0.9.2",
"mime": "1.4.1",
"semver": "^5.5.1"
},
"dependencies": {
"@bugsnag/core": "^7.7.0"
"@bugsnag/core": "^7.9.0-alpha.0"
}
}
1 change: 1 addition & 0 deletions packages/core/client.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ interface Delivery {
export default class ClientWithInternals<T extends Config = Config> extends Client {
public constructor(opts: T, schema?: {[key: string]: any}, internalPlugins?: Plugin[], notifier?: Notifier)
_config: T
_depth: number
_logger: LoggerConfig
_breadcrumbs: Breadcrumb[];
_delivery: Delivery
Expand Down
2 changes: 1 addition & 1 deletion packages/core/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion packages/core/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@bugsnag/core",
"main": "index.js",
"version": "7.7.0",
"version": "7.9.0-alpha.0",
"types": "types/index.d.ts",
"description": "Core classes and utilities for Bugsnag notifiers",
"homepage": "https://www.bugsnag.com/",
Expand Down
2 changes: 1 addition & 1 deletion packages/delivery-expo/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions packages/delivery-expo/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@bugsnag/delivery-expo",
"version": "7.7.0",
"version": "7.9.0-alpha.0",
"main": "delivery.js",
"description": "@bugsnag/js delivery mechanism to send events and sessions from Expo, using the FileSystem API to cache and retry sending failed payloads",
"homepage": "https://www.bugsnag.com/",
Expand All @@ -22,7 +22,7 @@
"expo-file-system": "~9.3.0"
},
"devDependencies": {
"@bugsnag/core": "^7.7.0"
"@bugsnag/core": "^7.9.0-alpha.0"
},
"peerDependencies": {
"@bugsnag/core": "^7.0.0"
Expand Down
2 changes: 1 addition & 1 deletion packages/delivery-node/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions packages/delivery-node/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@bugsnag/delivery-node",
"version": "7.7.0",
"version": "7.9.0-alpha.0",
"main": "delivery.js",
"description": "@bugsnag/node delivery mechanism",
"homepage": "https://www.bugsnag.com/",
Expand All @@ -17,7 +17,7 @@
"author": "Bugsnag",
"license": "MIT",
"devDependencies": {
"@bugsnag/core": "^7.7.0"
"@bugsnag/core": "^7.9.0-alpha.0"
},
"peerDependencies": {
"@bugsnag/core": "^7.0.0"
Expand Down
2 changes: 1 addition & 1 deletion packages/delivery-react-native/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions packages/delivery-react-native/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@bugsnag/delivery-react-native",
"version": "7.8.0",
"version": "7.9.0-alpha.0",
"main": "delivery.js",
"description": "@bugsnag/js delivery mechanism for React Native",
"homepage": "https://www.bugsnag.com/",
Expand All @@ -17,7 +17,7 @@
"author": "Bugsnag",
"license": "MIT",
"devDependencies": {
"@bugsnag/core": "^7.7.0"
"@bugsnag/core": "^7.9.0-alpha.0"
},
"peerDependencies": {
"@bugsnag/core": "^7.0.0"
Expand Down
2 changes: 1 addition & 1 deletion packages/delivery-x-domain-request/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions packages/delivery-x-domain-request/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@bugsnag/delivery-x-domain-request",
"version": "7.7.0",
"version": "7.9.0-alpha.0",
"main": "delivery.js",
"description": "@bugsnag/js delivery mechanism for IE 8, 9 and 10",
"homepage": "https://www.bugsnag.com/",
Expand All @@ -17,7 +17,7 @@
"author": "Bugsnag",
"license": "MIT",
"devDependencies": {
"@bugsnag/core": "^7.7.0"
"@bugsnag/core": "^7.9.0-alpha.0"
},
"peerDependencies": {
"@bugsnag/core": "^7.0.0"
Expand Down
2 changes: 1 addition & 1 deletion packages/delivery-xml-http-request/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions packages/delivery-xml-http-request/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@bugsnag/delivery-xml-http-request",
"version": "7.7.0",
"version": "7.9.0-alpha.0",
"main": "delivery.js",
"description": "@bugsnag/js delivery mechanism for most browsers",
"homepage": "https://www.bugsnag.com/",
Expand All @@ -17,7 +17,7 @@
"author": "Bugsnag",
"license": "MIT",
"devDependencies": {
"@bugsnag/core": "^7.7.0"
"@bugsnag/core": "^7.9.0-alpha.0"
},
"peerDependencies": {
"@bugsnag/core": "^7.0.0"
Expand Down
2 changes: 1 addition & 1 deletion packages/expo/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

28 changes: 14 additions & 14 deletions packages/expo/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@bugsnag/expo",
"version": "7.8.2",
"version": "7.9.0-alpha.0",
"main": "src/notifier.js",
"types": "types/bugsnag.d.ts",
"description": "Bugsnag error reporter for Expo applications",
Expand Down Expand Up @@ -32,19 +32,19 @@
"author": "Bugsnag",
"license": "MIT",
"dependencies": {
"@bugsnag/core": "^7.7.0",
"@bugsnag/delivery-expo": "^7.7.0",
"@bugsnag/plugin-browser-session": "^7.7.0",
"@bugsnag/plugin-console-breadcrumbs": "^7.7.0",
"@bugsnag/plugin-expo-app": "^7.7.0",
"@bugsnag/plugin-expo-device": "^7.7.0",
"@bugsnag/plugin-network-breadcrumbs": "^7.7.0",
"@bugsnag/plugin-react": "^7.7.0",
"@bugsnag/plugin-react-native-app-state-breadcrumbs": "^7.7.0",
"@bugsnag/plugin-react-native-connectivity-breadcrumbs": "^7.8.2",
"@bugsnag/plugin-react-native-global-error-handler": "^7.7.0",
"@bugsnag/plugin-react-native-orientation-breadcrumbs": "^7.7.0",
"@bugsnag/plugin-react-native-unhandled-rejection": "^7.7.0",
"@bugsnag/core": "^7.9.0-alpha.0",
"@bugsnag/delivery-expo": "^7.9.0-alpha.0",
"@bugsnag/plugin-browser-session": "^7.9.0-alpha.0",
"@bugsnag/plugin-console-breadcrumbs": "^7.9.0-alpha.0",
"@bugsnag/plugin-expo-app": "^7.9.0-alpha.0",
"@bugsnag/plugin-expo-device": "^7.9.0-alpha.0",
"@bugsnag/plugin-network-breadcrumbs": "^7.9.0-alpha.0",
"@bugsnag/plugin-react": "^7.9.0-alpha.0",
"@bugsnag/plugin-react-native-app-state-breadcrumbs": "^7.9.0-alpha.0",
"@bugsnag/plugin-react-native-connectivity-breadcrumbs": "^7.9.0-alpha.0",
"@bugsnag/plugin-react-native-global-error-handler": "^7.9.0-alpha.0",
"@bugsnag/plugin-react-native-orientation-breadcrumbs": "^7.9.0-alpha.0",
"@bugsnag/plugin-react-native-unhandled-rejection": "^7.9.0-alpha.0",
"@bugsnag/source-maps": "^1.0.1",
"bugsnag-build-reporter": "^1.0.1",
"expo-constants": "~9.3.3"
Expand Down
19 changes: 19 additions & 0 deletions packages/in-flight/LICENSE.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
Copyright (c) Bugsnag, https://www.bugsnag.com/

Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the Software
is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
7 changes: 7 additions & 0 deletions packages/in-flight/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# @bugsnag/in-flight

Internal [@bugsnag/js](https://github.com/bugsnag/bugsnag-js) package to keep track of in-flight requests

## License

This package is free software released under the MIT License. See [LICENSE.txt](./LICENSE.txt) for details.
13 changes: 13 additions & 0 deletions packages/in-flight/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

30 changes: 30 additions & 0 deletions packages/in-flight/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
{
"name": "@bugsnag/in-flight",
"version": "7.9.0-alpha.0",
"main": "src/in-flight.js",
"types": "types/bugsnag-in-flight.d.ts",
"description": "Internal package to keep track of in-flight requests to Bugsnag",
"homepage": "https://www.bugsnag.com/",
"repository": {
"type": "git",
"url": "[email protected]:bugsnag/bugsnag-js.git"
},
"publishConfig": {
"access": "public"
},
"files": [
"src",
"types"
],
"author": "Bugsnag",
"license": "MIT",
"dependencies": {
"@bugsnag/cuid": "^3.0.0"
},
"devDependencies": {
"@bugsnag/core": "^7.9.0-alpha.0"
},
"peerDependencies": {
"@bugsnag/core": "^7.0.0"
}
}
Loading

0 comments on commit 2d2f358

Please sign in to comment.