Aliheym / typeorm-transactional

A Transactional Method Decorator for TypeORM that uses Async Local Storage or cls-hooked to handle and propagate transactions between different repositories and service methods.
MIT License
201 stars 27 forks source link

initializeTransactionalContext leaks memory during tests #34

Open mlyskawinski opened 1 year ago

mlyskawinski commented 1 year ago

When running empty jest tests (with the --log-heap-usage flag), the memory is stable

image

But when i use the initializeTransactionalContext function, the leaking memory jumps up to ~40MB image

Is there a teardown function that can be used, so that we can avoid that?