Class MongoDbTransactionAutoConfiguration
java.lang.Object
org.springframework.modulith.events.mongodb.MongoDbTransactionAutoConfiguration
@AutoConfiguration
@AutoConfigureBefore(org.springframework.boot.autoconfigure.transaction.TransactionAutoConfiguration.class)
@ConditionalOnProperty(name="spring.modulith.events.mongodb.transaction-management.enabled",
havingValue="true",
matchIfMissing=true)
class MongoDbTransactionAutoConfiguration
extends Object
Auto-configuration to enable MongoDB transaction management as that is required for the
EventPublicationRegistry
to work properly.- Author:
- Oliver Drotbohm
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescription(package private) org.springframework.data.mongodb.MongoTransactionManager
transactionManager
(org.springframework.data.mongodb.MongoDatabaseFactory factory) (package private) TransactionTemplate
transactionTemplate
(PlatformTransactionManager txManager)
-
Constructor Details
-
MongoDbTransactionAutoConfiguration
MongoDbTransactionAutoConfiguration()
-
-
Method Details
-
transactionManager
@Bean @ConditionalOnMissingBean org.springframework.data.mongodb.MongoTransactionManager transactionManager(org.springframework.data.mongodb.MongoDatabaseFactory factory) -
transactionTemplate
@Bean @ConditionalOnMissingBean TransactionTemplate transactionTemplate(PlatformTransactionManager txManager)
-