@mwcp/kmore
Version:
midway component for knex, supports declarative transaction and OpenTelemetry
17 lines • 1.13 kB
TypeScript
import { IMidwayContainer } from '@midwayjs/core';
import { Application, Context, DecoratorExecutorParamBase, DecoratorHandlerBase } from '@mwcp/share';
import { TrxStatusService } from '../lib/trx-status.service.js';
import { KmorePropagationConfig } from '../lib/types.js';
import { DecoratorExecutorOptions } from './transactional.types.js';
export declare class DecoratorHandlerTransactional extends DecoratorHandlerBase {
protected readonly applicationContext: IMidwayContainer;
protected readonly trxStatusSvc: TrxStatusService;
protected readonly propagationConfig: KmorePropagationConfig;
getWebContext(): Context | undefined;
getWebContextThenApp(): Context | Application;
genExecutorParam(options: DecoratorExecutorParamBase): Promise<DecoratorExecutorOptions> | DecoratorExecutorParamBase<object>;
before(options: DecoratorExecutorOptions): Promise<void> | undefined;
afterReturn(options: DecoratorExecutorOptions): Promise<void> | undefined;
afterThrow(options: DecoratorExecutorOptions, errorExt?: unknown): never | Promise<never>;
}
//# sourceMappingURL=transactional.handler.d.ts.map