UNPKG

@eggjs/dal-plugin

Version:
12 lines (11 loc) 578 B
import { type AdviceContext, type IAdvice } from '@eggjs/aop-decorator'; import { type EggProtoImplClass } from '@eggjs/core-decorator'; import { PropagationType } from '@eggjs/tegg-types'; import { MysqlDataSource } from '@eggjs/dal-runtime'; export interface TransactionalParams { propagation: PropagationType; dataSourceGetter: () => MysqlDataSource; } export declare class TransactionalAOP implements IAdvice<EggProtoImplClass, TransactionalParams> { around(ctx: AdviceContext<EggProtoImplClass, TransactionalParams>, next: () => Promise<any>): Promise<void>; }