Open bneigher opened 1 year ago
I'm looking for similar behavior as @nestjs/mongoose:
@nestjs/mongoose
import { Injectable, Logger } from '@nestjs/common'; import { InjectConnection } from '@nestjs/mongoose'; @Injectable() export class MyService { private readonly logger = new Logger(MyService.name); // eslint-disable-next-line no-useless-constructor constructor( @InjectConnection() private dbConnection: Connection, ) {} async test() { const transaction = await this.dbConnection.startSession(); await transaction.withTransaction(async () => { ... /* my transactions */ ... }) transaction.endSession(); return } }
Is this something that we can add to the lib?
I'm looking for similar behavior as
@nestjs/mongoose
:Is this something that we can add to the lib?