From 0a664c6252b5ce3e1172a6d6f0d0c6394f863ea1 Mon Sep 17 00:00:00 2001 From: Johan Haleby Date: Mon, 9 Sep 2024 15:01:31 +0200 Subject: [PATCH] OccurrentAnnotationBeanPostProcessor is only applied if "occurrent.subscription.enabled" property is missing or is "true" --- changelog.md | 3 +++ .../mongo/blocking/OccurrentMongoAutoConfiguration.java | 1 + 2 files changed, 4 insertions(+) diff --git a/changelog.md b/changelog.md index f8302b2c2..48033cf6e 100644 --- a/changelog.md +++ b/changelog.md @@ -1,3 +1,6 @@ +### Changelog next version +* `OccurrentAnnotationBeanPostProcessor` is only applied if `occurrent.subscription.enabled` property is missing or is `true` + ### 0.19.1 (2024-07-04) * Ignoring NoSuchBeanDefinitionException when getting the springApplicationAdminRegistrar bean when working around https://github.com/spring-projects/spring-framework/issues/32904 diff --git a/framework/spring-boot-starter-mongodb/src/main/java/org/occurrent/springboot/mongo/blocking/OccurrentMongoAutoConfiguration.java b/framework/spring-boot-starter-mongodb/src/main/java/org/occurrent/springboot/mongo/blocking/OccurrentMongoAutoConfiguration.java index d25e68613..77a409f7c 100644 --- a/framework/spring-boot-starter-mongodb/src/main/java/org/occurrent/springboot/mongo/blocking/OccurrentMongoAutoConfiguration.java +++ b/framework/spring-boot-starter-mongodb/src/main/java/org/occurrent/springboot/mongo/blocking/OccurrentMongoAutoConfiguration.java @@ -75,6 +75,7 @@ public class OccurrentMongoAutoConfiguration { @Bean + @ConditionalOnProperty(name = "occurrent.subscription.enabled", havingValue = "true", matchIfMissing = true) static OccurrentAnnotationBeanPostProcessor occurrentAnnotationBeanPostProcessor() { return new OccurrentAnnotationBeanPostProcessor(); }