Skip to content

Commit 6bcd1a6

Browse files
committed
ref(aws-serverless)!: Migrate import hook to makeOrchestrionLoader
Switch the `@sentry/aws-serverless/import` loader to the orchestrion-based `makeOrchestrionLoader` and drop the obsolete `./loader` export.
1 parent e9e57d7 commit 6bcd1a6

3 files changed

Lines changed: 3 additions & 8 deletions

File tree

MIGRATION.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -400,6 +400,7 @@ Sentry.init({
400400
- The `generateInstrumentOnce` export was removed (from `@sentry/node` and the framework SDKs that re-exported it). It wrapped OpenTelemetry's `registerInstrumentations` and is no longer needed now that instrumentation is channel-based.
401401
- The `@sentry/node/loader` entry point was removed. Use `node --import @sentry/node/import` instead.
402402
- (Astro) The `@sentry/astro/loader` entry point was removed. Use `node --import @sentry/astro/import` instead.
403+
- (AWS Lambda) The `@sentry/aws-serverless/loader` entry point was removed. Use `node --import @sentry/aws-serverless/import` instead.
403404
- (Fastify) The deprecated `setShouldHandleError` method was removed.
404405
- (AWS Lambda) The deprecated `disableAwsContextPropagation` option was removed. It no longer had any effect.
405406
- (AWS Lambda) The deprecated `startTrace` option was removed. It no longer had any effect; to disable tracing, set `tracesSampleRate` to `0`.

packages/aws-serverless/package.json

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
"files": [
1313
"/build/npm",
1414
"/build/import-hook.mjs",
15-
"/build/loader-hook.mjs",
1615
"/build/lambda-extension"
1716
],
1817
"main": "build/npm/cjs/index.js",
@@ -35,11 +34,6 @@
3534
"default": "./build/import-hook.mjs"
3635
}
3736
},
38-
"./loader": {
39-
"import": {
40-
"default": "./build/loader-hook.mjs"
41-
}
42-
},
4337
"./awslambda-auto": {
4438
"require": {
4539
"default": "./build/npm/cjs/awslambda-auto.js"

packages/aws-serverless/rollup.npm.config.mjs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { makeBaseNPMConfig, makeNPMConfigVariants, makeOtelLoaders } from '@sentry-internal/rollup-utils';
1+
import { makeBaseNPMConfig, makeNPMConfigVariants, makeOrchestrionLoader } from '@sentry-internal/rollup-utils';
22

33
// The handler shim (loaded by the AWS Lambda runtime via the redirected `_HANDLER`) is
44
// built as a standalone, ESM-only bundle: it uses top-level await to load the user's
@@ -41,5 +41,5 @@ export default [
4141
},
4242
}),
4343
),
44-
...makeOtelLoaders('./build', 'sentry-node'),
44+
...makeOrchestrionLoader('./build'),
4545
];

0 commit comments

Comments
 (0)