Skip to main content
Skip to main content

Context

A context used to share resources, such as transaction manager, between the application and the module.

Type parameters

TManagerobjectRequired
__type"MedusaContext"
transactionManagerTManager
An instance of a transaction manager of type TManager, which is a typed parameter passed to the context to specify the type of the transactionManager.
managerTManager
An instance of a manager, typically an entity manager, of type TManager, which is a typed parameter passed to the context to specify the type of the manager.
isolationLevelstring
A string indicating the isolation level of the context. Possible values are READ UNCOMMITTED, READ COMMITTED, REPEATABLE READ, or SERIALIZABLE.
enableNestedTransactionsboolean
A boolean value indicating whether nested transactions are enabled.
eventGroupIdstring
A string indicating the ID of the group to aggregate the events to be emitted at a later point.
transactionIdstring
A string indicating the ID of the current transaction.
messageAggregatorIMessageAggregator
An instance of a message aggregator, which is used to aggregate messages to be emitted at a later point.
requestIdstring
A string indicating the ID of the current request.
Was this section helpful?