Commit Graph

284 Commits

Author SHA1 Message Date
Oliver Drotbohm
a74c4e582d GH-199 - Release version 1.0.0-M1. 2023-06-23 12:55:09 +02:00
Oliver Drotbohm
b525d925ef GH-219 - Upgrade to Spring Boot 3.1.1. 2023-06-23 12:53:47 +02:00
Oliver Drotbohm
676ee3f0e9 GH-217 - Fix Framework snapshot versions for compatibility tests.
Temporarily run Boot 3.2 snapshot compatibility tests with Framework 6.1 snapshots explicitly.
2023-06-23 12:49:06 +02:00
Oliver Drotbohm
a915f76422 GH-217 - Upgrade CI integration builds after recent releases. 2023-06-23 12:49:06 +02:00
Yossi Spektor
85ce443ce5 GH-213 - Specify proper transactional propagation type in docs.
The default propagation type of @Transactional is Propagation.REQUIRED. That, however would reuse the already running committed transaction which is not the correct behavior.

Related ticket: #80.
2023-06-23 12:49:06 +02:00
Oliver Drotbohm
5dfffa2244 GH-216 - Forward an ApplicationContext's ExecutorService to Scenario instances by default.
We now register a default customizer on the Scenario instances created to pick up an ExecutorService defined in the ApplicationContext so that customizations made to that are considered in the test execution.
2023-06-23 12:49:06 +02:00
Oliver Drotbohm
fb8f12fd98 GH-209 - Polishing.
A few more comments. Test dependency instead of the core one to include the subsequently shown API.
2023-06-23 12:49:06 +02:00
Tom Hombergs
85655c2acd GH-209 - Update the README with a complete pom.xml snippet to get started. 2023-06-23 12:49:06 +02:00
Oliver Drotbohm
e51262d462 GH-211 - Rename actuator to application-modules. 2023-06-23 12:49:06 +02:00
Oliver Drotbohm
516c48dc07 GH-208 - Switch to CopyOnWriteArrayList for DefaultPublishedEvents. 2023-06-23 12:49:06 +02:00
Oliver Drotbohm
4cdf14d241 GH-198 - Upgrade to Spring Boot 3.1. 2023-06-23 12:49:06 +02:00
Oliver Drotbohm
0dd2200302 GH-195 - Unnest test cases to make sure we run the right profiles.
Remove the nesting of the test classes as they will be executed without profiles activated.
2023-06-23 12:49:06 +02:00
Oliver Drotbohm
068916aa54 GH-195 - Remove support for legacy spring.modulith.jdbc-… namespace in JDBC-based event support. 2023-06-23 12:49:06 +02:00
Oliver Drotbohm
3d186062f1 GH-200 - Group starters under single build module. 2023-06-23 12:49:06 +02:00
Oliver Drotbohm
f0fb242b5b GH-189 - Better artifact names for example projects. 2023-06-23 12:49:06 +02:00
Oliver Drotbohm
d7ef7c9dea GH-198 - Upgrade to Spring Boot 3.1 snapshots.
Switch verification of mock beans as Mockito 5.3.0 uses a different MockMaker by default that doesn't add the explicit interface we have previously checked for.

Remove obsolete init- and destroy method declarations from service bean definitions in examples.
2023-05-02 14:32:41 +02:00
Oliver Drotbohm
596e8828a2 GH-197 - Promote project out of experimental status.
Set version number to 1.0.0-SNAPSHOT. New group id is org.springframework.modulith. Also adapt links to new project home.
2023-05-02 14:32:32 +02:00
Oliver Drotbohm
60ce7da56e GH-189 - Prepare next development iteration. 2023-05-02 12:28:30 +02:00
Oliver Drotbohm
9d1180017e GH-189 - Release version 0.6.0. 2023-05-02 12:28:29 +02:00
Oliver Drotbohm
594c22a4c8 GH-181 - Create dedicated submodule for examples.
Move already existing example underneath that. Added examples for JDBC- and MongoDB-based event publication registry setups.
2023-05-01 22:44:54 +02:00
Oliver Drotbohm
94093a3081 GH-175 - More defensive auto-configuration of MongoDB transactions.
We now opt out of defining bean definitions for MongoTransactionManager and TransactionTemplate if user defined. We also make sure to run before the EnableTransactionManagementConfiguration to make sure that will see our auto-configured MongoTransactionManager.
2023-05-01 22:30:29 +02:00
Oliver Drotbohm
c46b9b958d GH-196 - Upgrade to Hibernate 6.2.2 for JPA event publication registry tests. 2023-05-01 21:56:54 +02:00
Oliver Drotbohm
f0c38e1085 GH-194 - Fix combined condition to enable JDBC database initialization. 2023-05-01 21:56:54 +02:00
Oliver Drotbohm
0fbd776239 GH-194 - Switch to spring.modulith.events.jdbc.… namspace for data initialization properties.
The legacy ones are still supported but the data initialization properties have been moved to a new spring.modulith.events.jdbc.… namespace.
2023-05-01 21:33:49 +02:00
Oliver Drotbohm
646722beaf GH-175 - Auto-configure transactions for MongoDB by default.
As the Event Publication registry only works in transactional environments, we should enable them for MongoDB by default. This will require a replica setup for the MongoDB instance the application interacts with.
2023-05-01 21:28:08 +02:00
Oliver Drotbohm
6dabfb425b GH-191 - Prevent premature access of ApplicationContext from ParameterResolver implementations.
We now avoid accessing the ApplicationContext from a BeforeAllCallback as this might cause the context initialization before other extensions had time to kick in.
2023-04-30 22:35:14 +02:00
Oliver Drotbohm
c111e41f2b GH-189 - Upgrade build plugins to latest versions. 2023-04-30 22:35:14 +02:00
Oliver Drotbohm
4656f82089 GH-187 - Do not include non-exposed Spring beans that implement interfaces in Application Module Canvas by default.
We now properly check whether one of a Spring bean's implemented interfaces is exposed by the module before including it in the default rendering of the Application Module Canvas.
2023-04-30 22:35:14 +02:00
Oliver Drotbohm
0b6dccf334 GH-190 - Introduce @EnableScenarios.
The dedicated annotation allows using Scenario as test parameter in @SpringBootTest-based integration tests, too.

ScenarioParameterResolver now throws a better error message if a TransactionTemplate bean is missing from the ApplicationContext.
2023-04-30 22:35:14 +02:00
Oliver Drotbohm
c9729bded0 GH-186 - Workaround for invalid application listener matching in AbstractApplicationEventMulticaster.
AbstractApplicationEventMulticaster.supportsEvent(…) currently doesn't properly match unresolved, generic ApplicationEvents (see [0]). We now work around this problem by additionally matching the raw event types in a custom override of supportsEvent(…).

[0] https://github.com/spring-projects/spring-framework/issues/30399
2023-04-30 22:35:14 +02:00
Oliver Drotbohm
b3b06614f9 GH-180 - Update to Spring Framework 6.0.8 for Javadoc references. 2023-04-30 22:35:14 +02:00
Oliver Drotbohm
70ed1678c2 GH-188 - Upgrade to jMolecules BOM 2022.3.0. 2023-04-30 22:35:14 +02:00
Oliver Drotbohm
16bc4b3a60 GH-192 - Add default component groupings for jMolecules architecture abstractions.
We now register default groupings for the architectural abstractions [0] in case they are available on the classpath but still fall back to the standard Spring Framework ones if not. In other words, if you e.g. use the jmolecules-hexagonal-architecture ones, types and packages annotated with @Port will cause the affected types to appear under a "Ports" section in the "Spring components" row in the Application Module Canvas.

[0] https://github.com/xmolecules/jmolecules#available-libraries-1
2023-04-30 22:35:14 +02:00
Oliver Drotbohm
3c52dbd0b3 GH-188 - Upgrade to jMolecules 2022.3.0 snapshots. 2023-04-28 20:23:40 +02:00
Oliver Drotbohm
394e87337b GH-187 - Unit tests for Spring Data repository detection.
Both imperative and reactive flavours.
2023-04-28 20:22:27 +02:00
Oliver Drotbohm
bb800ba046 GH-185 - Additional simplification of delayed event verification on Scenarios. 2023-04-25 14:34:23 +02:00
Oliver Drotbohm
3a923519f2 GH-185 - Allow verification of events after method invocation stimulus. 2023-04-24 17:31:21 +02:00
Oliver Drotbohm
b834c255ec GH-184 - Enable asynchronous support when using event publication registry.
Unless manually configured we now configure @EnableAsync by default in the event publication registry module.
2023-04-24 14:43:37 +02:00
Oliver Drotbohm
29a5148dcb GH-181 - Delay lookup of EventPublicationRegistry as much as possible.
We now avoid to initialize the EventPublicationRegistry in the ApplicationEventMulticaster unless there is a transactional event listener interested in the event to be published. This should help us avoid premature initialization of the registry for application events published early in the application context bootstrap phase.
2023-04-23 23:56:23 +02:00
Oliver Drotbohm
fbd2c2e66f GH-182 - Use dedicated SliceAssignment to verify modularity.
The previous modularity verification arrangement assumed the default module detection strategy to be used. To properly support alternative implementations during the verification we now use a dedicated SliceAssignment implementation that assigns types to slices identified by the module they are located in.
2023-04-23 23:24:02 +02:00
Oliver Drotbohm
d9f298c96a GH-183 - Improvements in named interface declarations.
Type based named interfaces on types declared in a module's API package still caused the type to be included in the unnamed interface. This is now fixed by explicitly removing named interface types from the unnamed interface.

We now also detect API package types assigned to a named interface without an explicit name as the package name defaulting doesn't work in this case.

Furthermore, named interfaces are now sorted alphabetically to make the unnamed one always appear first.
2023-04-23 23:21:00 +02:00
Oliver Drotbohm
0e6c41b57c GH-180 - Upgrade to Spring Boot 3.0.6. 2023-04-20 16:31:06 +02:00
Oliver Drotbohm
cd76c96250 GH-165 - Introduce ScenarioCustomizer extension.
We now provide a ScenarioCustomizer that can be used to prepare Scenario instances for test methods with a common customizer. This avoids the need to call ….customize(…) for all Scenarios declared in a test class with the same logic.
2023-04-20 14:15:10 +02:00
Oliver Drotbohm
daee88a227 GH-177 - Javadoc polishing. 2023-03-31 13:44:06 +02:00
Oliver Drotbohm
2454ecbc4b GH-177 - Named interfaces names now default to the local package name.
Both package- and type-level declarations now use the local package name as the named interface's name. This allows to, at the same time, easily declared named interfaces based on packages but also a nice decoupling of the interface definition and the package layout as individual types can be assigned to such interfaces no matter where they are actually declared.
2023-03-31 13:34:21 +02:00
Oliver Drotbohm
6d2fdd6fdc GH-173 - Polishing.
@ApplicationModuleTest is now explicitly declared to only be usable on types, documented and inherited.
2023-03-27 17:56:12 +02:00
Oliver Drotbohm
822febd00e GH-173 - Support for @ApplicationModuleTest in JUnit 5 nested test classes.
We now use Spring Test Context's TestContextAnnotationUtils to lookup the @ApplicationModuleTest annotation to eventually bootstrap an ApplicationModules instance. That ensures that we find the annotation on JUnit 5's @Nested classes.
2023-03-27 17:56:04 +02:00
Oliver Drotbohm
281da55eac GH-172 - Prepare next development iteration. 2023-03-24 10:24:47 +01:00
Oliver Drotbohm
d5bdff3f77 GH-172 - Release version 0.5.1. 2023-03-24 10:24:47 +01:00
Oliver Drotbohm
995d10591b GH-169 - More defensive bean definition declaration for the ApplicationStartedEvent listener.
Altered the bean definition to rather only refer to a ListableBeanFactory and only lookup the ApplicationModulesRuntime and ApplicationModuleListeners when the ApplicationStartedEvent is handled.
2023-03-23 22:55:25 +01:00