Rocky_Mountain_Vending/.pnpm-store/v10/files/3a/c448664ff2e8b032b6add029e9074f0d68897d9ce8711cc02d8e38698c93f9509e4c5e002be418efcaf0e1ae5b483e1c8bb9b054195bf828cd42da6c17bc88
DMleadgen 46d973904b
Initial commit: Rocky Mountain Vending website
Next.js website for Rocky Mountain Vending company featuring:
- Product catalog with Stripe integration
- Service areas and parts pages
- Admin dashboard with Clerk authentication
- SEO optimized pages with JSON-LD structured data

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-12 16:22:15 -07:00

34 lines
1.2 KiB
Text

import { defineIntegration, startSession, getIsolationScope, endSession } from '@sentry/core';
const INTEGRATION_NAME = 'ProcessSession';
/**
* Records a Session for the current process to track release health.
*/
const processSessionIntegration = defineIntegration(() => {
return {
name: INTEGRATION_NAME,
setupOnce() {
startSession();
// Emitted in the case of healthy sessions, error of `mechanism.handled: true` and unhandledrejections because
// The 'beforeExit' event is not emitted for conditions causing explicit termination,
// such as calling process.exit() or uncaught exceptions.
// Ref: https://nodejs.org/api/process.html#process_event_beforeexit
process.on('beforeExit', () => {
const session = getIsolationScope().getSession();
// Only call endSession, if the Session exists on Scope and SessionStatus is not a
// Terminal Status i.e. Exited or Crashed because
// "When a session is moved away from ok it must not be updated anymore."
// Ref: https://develop.sentry.dev/sdk/sessions/
if (session?.status !== 'ok') {
endSession();
}
});
},
};
});
export { processSessionIntegration };
//# sourceMappingURL=processSession.js.map