diff --git a/pom.xml b/pom.xml index 31de9d9e..c75d60dc 100644 --- a/pom.xml +++ b/pom.xml @@ -42,6 +42,7 @@ 2022.2.2 UTF-8 UTF-8 + 6.0.4 0.0.4 3.0.1 @@ -132,11 +133,6 @@ limitations under the License. - - none - true - package - @@ -225,7 +221,6 @@ limitations under the License. ${project.build.directory}/generated-docs - true true true true @@ -240,6 +235,22 @@ limitations under the License. artifactory-maven-plugin + + org.apache.maven.plugins + maven-javadoc-plugin + 3.4.1 + false + + + aggregate-javadocs + + aggregate-no-fork + + package + + + + @@ -423,6 +434,26 @@ limitations under the License. verify + + + + org.apache.maven.plugins + maven-javadoc-plugin + 3.4.1 + + accessibility,html,reference,syntax + package + true + + https://docs.spring.io/spring-boot/docs/${spring-boot.version}/api/ + https://docs.spring.io/spring/docs/${spring.version}/javadoc-api/ + https://docs.oracle.com/en/java/javase/17/docs/api/ + + + + + + diff --git a/spring-modulith-actuator/src/main/java/org/springframework/modulith/actuator/ApplicationModulesEndpoint.java b/spring-modulith-actuator/src/main/java/org/springframework/modulith/actuator/ApplicationModulesEndpoint.java index b8835285..3db4d856 100644 --- a/spring-modulith-actuator/src/main/java/org/springframework/modulith/actuator/ApplicationModulesEndpoint.java +++ b/spring-modulith-actuator/src/main/java/org/springframework/modulith/actuator/ApplicationModulesEndpoint.java @@ -62,7 +62,7 @@ public class ApplicationModulesEndpoint { private final Supplier runtime; /** - * Creates a new {@link ApplicationModulesEndpoint} for the given {@link ModulesRuntime}. + * Creates a new {@link ApplicationModulesEndpoint} for the given {@link ApplicationModules}. * * @param runtime must not be {@literal null}. */ diff --git a/spring-modulith-actuator/src/main/java/org/springframework/modulith/actuator/autoconfigure/package-info.java b/spring-modulith-actuator/src/main/java/org/springframework/modulith/actuator/autoconfigure/package-info.java new file mode 100644 index 00000000..d81ff6fc --- /dev/null +++ b/spring-modulith-actuator/src/main/java/org/springframework/modulith/actuator/autoconfigure/package-info.java @@ -0,0 +1,5 @@ +/** + * Autoconfiguration for Spring Modulith actuators. + */ +@org.springframework.lang.NonNullApi +package org.springframework.modulith.actuator.autoconfigure; diff --git a/spring-modulith-actuator/src/main/java/org/springframework/modulith/actuator/package-info.java b/spring-modulith-actuator/src/main/java/org/springframework/modulith/actuator/package-info.java new file mode 100644 index 00000000..19489a32 --- /dev/null +++ b/spring-modulith-actuator/src/main/java/org/springframework/modulith/actuator/package-info.java @@ -0,0 +1,5 @@ +/** + * Spring Boot actuator support for Spring Modulith. + */ +@org.springframework.lang.NonNullApi +package org.springframework.modulith.actuator; diff --git a/spring-modulith-api/src/main/java/org/springframework/modulith/package-info.java b/spring-modulith-api/src/main/java/org/springframework/modulith/package-info.java new file mode 100644 index 00000000..b308e837 --- /dev/null +++ b/spring-modulith-api/src/main/java/org/springframework/modulith/package-info.java @@ -0,0 +1,5 @@ +/** + * Core abstractions of Spring Modulith. To be referred to in user applications. + */ +@org.springframework.lang.NonNullApi +package org.springframework.modulith; diff --git a/spring-modulith-core/src/main/java/org/springframework/modulith/model/ApplicationModuleInformation.java b/spring-modulith-core/src/main/java/org/springframework/modulith/model/ApplicationModuleInformation.java index c43675bd..53e93586 100644 --- a/spring-modulith-core/src/main/java/org/springframework/modulith/model/ApplicationModuleInformation.java +++ b/spring-modulith-core/src/main/java/org/springframework/modulith/model/ApplicationModuleInformation.java @@ -22,7 +22,9 @@ import java.util.Optional; import java.util.function.Supplier; import java.util.stream.Stream; +import org.jmolecules.ddd.annotation.Module; import org.springframework.modulith.ApplicationModule; +import org.springframework.util.Assert; import org.springframework.util.ClassUtils; import org.springframework.util.StringUtils; @@ -34,24 +36,46 @@ import org.springframework.util.StringUtils; */ interface ApplicationModuleInformation { + /** + * Creates a new {@link ApplicationModuleInformation} for the given {@link JavaPackage}. + * + * @param javaPackage must not be {@literal null}. + * @return will never be {@literal null}. + */ public static ApplicationModuleInformation of(JavaPackage javaPackage) { if (ClassUtils.isPresent("org.jmolecules.ddd.annotation.Module", ApplicationModuleInformation.class.getClassLoader()) - && MoleculesModule.supports(javaPackage)) { - return new MoleculesModule(javaPackage); + && JMoleculesModule.supports(javaPackage)) { + return new JMoleculesModule(javaPackage); } - return new ModulithsModule(javaPackage); + return new SpringModulithModule(javaPackage); } + /** + * Returns the display name to be used to describe the module. + * + * @return will never be {@literal null}. + */ default Optional getDisplayName() { return Optional.empty(); } + /** + * Returns all allowed dependencies. + * + * @return will never be {@literal null}. + */ List getAllowedDependencies(); - static class MoleculesModule implements ApplicationModuleInformation { + /** + * An {@link ApplicationModuleInformation} for the jMolecules {@link Module} annotation. + * + * @author Oliver Drotbohm + * @see https://jMolecules.org + */ + static class JMoleculesModule implements ApplicationModuleInformation { private final Optional annotation; @@ -59,7 +83,7 @@ interface ApplicationModuleInformation { return javaPackage.getAnnotation(org.jmolecules.ddd.annotation.Module.class).isPresent(); } - public MoleculesModule(JavaPackage javaPackage) { + public JMoleculesModule(JavaPackage javaPackage) { this.annotation = javaPackage.getAnnotation(org.jmolecules.ddd.annotation.Module.class); } @@ -90,15 +114,33 @@ interface ApplicationModuleInformation { } } - static class ModulithsModule implements ApplicationModuleInformation { + /** + * An {@link ApplicationModuleInformation} that inspects the {@link ApplicationModule} annotation. + * + * @author Oliver Drotbohm + */ + static class SpringModulithModule implements ApplicationModuleInformation { private final Optional annotation; + /** + * Whether the given {@link JavaPackage} supports this {@link ApplicationModuleInformation}. + * + * @param javaPackage must not be {@literal null}. + */ public static boolean supports(JavaPackage javaPackage) { + + Assert.notNull(javaPackage, "Java package must not be null!"); + return javaPackage.getAnnotation(ApplicationModule.class).isPresent(); } - public ModulithsModule(JavaPackage javaPackage) { + /** + * Creates a new {@link SpringModulithModule} for the given {@link JavaPackage}. + * + * @param javaPackage must not be {@literal null}. + */ + public SpringModulithModule(JavaPackage javaPackage) { this.annotation = javaPackage.getAnnotation(ApplicationModule.class); } diff --git a/spring-modulith-core/src/main/java/org/springframework/modulith/model/ApplicationModules.java b/spring-modulith-core/src/main/java/org/springframework/modulith/model/ApplicationModules.java index af8b09e7..07d2251b 100644 --- a/spring-modulith-core/src/main/java/org/springframework/modulith/model/ApplicationModules.java +++ b/spring-modulith-core/src/main/java/org/springframework/modulith/model/ApplicationModules.java @@ -154,7 +154,7 @@ public class ApplicationModules implements Iterable { * annotation on the class given for advanced customizations of the module setup. * * @param modulithType must not be {@literal null}. - * @return + * @return will never be {@literal null}. */ public static ApplicationModules of(Class modulithType) { return of(modulithType, alwaysFalse()); @@ -167,9 +167,8 @@ public class ApplicationModules implements Iterable { * of the module setup. * * @param modulithType must not be {@literal null}. - * @param detection must not be {@literal null}. * @param ignored must not be {@literal null}. - * @return + * @return will never be {@literal null}. */ public static ApplicationModules of(Class modulithType, DescribedPredicate ignored) { diff --git a/spring-modulith-core/src/main/java/org/springframework/modulith/model/JavaPackage.java b/spring-modulith-core/src/main/java/org/springframework/modulith/model/JavaPackage.java index 69f5fa75..b8fa4f9f 100644 --- a/spring-modulith-core/src/main/java/org/springframework/modulith/model/JavaPackage.java +++ b/spring-modulith-core/src/main/java/org/springframework/modulith/model/JavaPackage.java @@ -37,6 +37,8 @@ import com.tngtech.archunit.thirdparty.com.google.common.base.Supplier; import com.tngtech.archunit.thirdparty.com.google.common.base.Suppliers; /** + * An abstraction of a Java package. + * * @author Oliver Drotbohm */ public class JavaPackage implements DescribedIterable { diff --git a/spring-modulith-core/src/main/java/org/springframework/modulith/model/ModulithMetadata.java b/spring-modulith-core/src/main/java/org/springframework/modulith/model/ModulithMetadata.java index 6c6a5e05..6b2fdf02 100644 --- a/spring-modulith-core/src/main/java/org/springframework/modulith/model/ModulithMetadata.java +++ b/spring-modulith-core/src/main/java/org/springframework/modulith/model/ModulithMetadata.java @@ -30,8 +30,8 @@ public interface ModulithMetadata { static final String ANNOTATION_MISSING = "Modules can only be retrieved from a root type, but %s is not annotated with either @%s, @%s or @%s!"; /** - * Creates a new {@link ModulithMetadata} for the given annotated type. Expecteds the type either be annotated with - * {@link Modulith}, {@link Modulithic} or {@link SpringBootApplication}. + * Creates a new {@link ModulithMetadata} for the given annotated type. Expects the type either be annotated with + * {@link Modulith}, {@link Modulithic} or {@link org.springframework.boot.autoconfigure.SpringBootApplication}. * * @param annotated must not be {@literal null}. * @return diff --git a/spring-modulith-core/src/main/java/org/springframework/modulith/model/package-info.java b/spring-modulith-core/src/main/java/org/springframework/modulith/model/package-info.java index 318d486f..74187e07 100644 --- a/spring-modulith-core/src/main/java/org/springframework/modulith/model/package-info.java +++ b/spring-modulith-core/src/main/java/org/springframework/modulith/model/package-info.java @@ -1,2 +1,5 @@ +/** + * Core, internal abstractions of Spring Modulith. + */ @org.springframework.lang.NonNullApi package org.springframework.modulith.model; diff --git a/spring-modulith-docs/src/main/java/org/springframework/modulith/docs/Documenter.java b/spring-modulith-docs/src/main/java/org/springframework/modulith/docs/Documenter.java index efc7003b..2066bdf3 100644 --- a/spring-modulith-docs/src/main/java/org/springframework/modulith/docs/Documenter.java +++ b/spring-modulith-docs/src/main/java/org/springframework/modulith/docs/Documenter.java @@ -74,6 +74,7 @@ public class Documenter { private static final Map DEPENDENCY_DESCRIPTIONS = new LinkedHashMap<>(); private static final String INVALID_FILE_NAME_PATTERN = "Configured file name pattern does not include a '%s' placeholder for the module name!"; + private static final String DEFAULT_LOCATION = "spring-modulith-docs"; static { DEPENDENCY_DESCRIPTIONS.put(DependencyType.EVENT_LISTENER, "listens to"); @@ -576,7 +577,7 @@ public class Documenter { * @return will never be {@literal null}. */ private static String getDefaultOutputDirectory() { - return (new File("pom.xml").exists() ? "target" : "build").concat("/spring-modulith-docs"); + return (new File("pom.xml").exists() ? "target" : "build").concat("/").concat(DEFAULT_LOCATION); } private static record Connection(Element source, Element target) { @@ -658,7 +659,7 @@ public class Documenter { /** * A {@link Predicate} to define the which modules to exclude from the diagram to be created. */ - public DiagramOptions withExcusions(Predicate exclusions) { + public DiagramOptions withExclusions(Predicate exclusions) { return new DiagramOptions(dependencyTypes, dependencyDepth, exclusions, componentFilter, targetOnly, targetFileName, colorSelector, defaultDisplayName, style, elementsWithoutRelationships); } @@ -708,7 +709,7 @@ public class Documenter { } /** - * Which style to render the diagram in. Defaults to {@value DiagramStyle#UML}. + * Which style to render the diagram in. Defaults to {@link DiagramStyle#UML}. */ public DiagramOptions withStyle(DiagramStyle style) { return new DiagramOptions(dependencyTypes, dependencyDepth, exclusions, componentFilter, targetOnly, @@ -717,7 +718,7 @@ public class Documenter { /** * Configuration setting to define whether modules that do not have a relationship to any other module shall be - * retained in the diagrams created. The default is {@value ElementsWithoutRelationships#HIDDEN}. See + * retained in the diagrams created. The default is {@link ElementsWithoutRelationships#HIDDEN}. See * {@link DiagramOptions#withExclusions(Predicate)} for a more fine-grained way of defining which modules to exclude * in case you flip this to {@link ElementsWithoutRelationships#VISIBLE}. * @@ -785,14 +786,14 @@ public class Documenter { /** * A C4 model component diagram. * - * @see https://c4model.com/#ComponentDiagram + * @see https://c4model.com/#ComponentDiagram */ C4; } /** * Configuration setting to define whether modules that do not have a relationship to any other module shall be - * retained in the diagrams created. The default is {@value ElementsWithoutRelationships#HIDDEN}. See + * retained in the diagrams created. The default is {@link ElementsWithoutRelationships#HIDDEN}. See * {@link DiagramOptions#withExclusions(Predicate)} for a more fine-grained way of defining which modules to exclude * in case you flip this to {@link ElementsWithoutRelationships#VISIBLE}. * diff --git a/spring-modulith-docs/src/main/java/org/springframework/modulith/docs/package-info.java b/spring-modulith-docs/src/main/java/org/springframework/modulith/docs/package-info.java index 35933587..3e33c847 100644 --- a/spring-modulith-docs/src/main/java/org/springframework/modulith/docs/package-info.java +++ b/spring-modulith-docs/src/main/java/org/springframework/modulith/docs/package-info.java @@ -1,2 +1,5 @@ +/** + * Documentation support for Spring Modulith. + */ @org.springframework.lang.NonNullApi package org.springframework.modulith.docs; diff --git a/spring-modulith-events/spring-modulith-events-core/src/main/java/org/springframework/modulith/events/config/package-info.java b/spring-modulith-events/spring-modulith-events-core/src/main/java/org/springframework/modulith/events/config/package-info.java index 19dc2478..51ee02f8 100644 --- a/spring-modulith-events/spring-modulith-events-core/src/main/java/org/springframework/modulith/events/config/package-info.java +++ b/spring-modulith-events/spring-modulith-events-core/src/main/java/org/springframework/modulith/events/config/package-info.java @@ -1,2 +1,5 @@ +/** + * Spring configuration for the event publication registry. + */ @org.springframework.lang.NonNullApi package org.springframework.modulith.events.config; diff --git a/spring-modulith-events/spring-modulith-events-core/src/main/java/org/springframework/modulith/events/package-info.java b/spring-modulith-events/spring-modulith-events-core/src/main/java/org/springframework/modulith/events/package-info.java index 068392ef..23e944a8 100644 --- a/spring-modulith-events/spring-modulith-events-core/src/main/java/org/springframework/modulith/events/package-info.java +++ b/spring-modulith-events/spring-modulith-events-core/src/main/java/org/springframework/modulith/events/package-info.java @@ -1,2 +1,5 @@ +/** + * The event publication registry abstraction. + */ @org.springframework.lang.NonNullApi package org.springframework.modulith.events; diff --git a/spring-modulith-events/spring-modulith-events-core/src/main/java/org/springframework/modulith/events/support/CompletionRegisteringBeanPostProcessor.java b/spring-modulith-events/spring-modulith-events-core/src/main/java/org/springframework/modulith/events/support/CompletionRegisteringBeanPostProcessor.java index 7aa14f91..06d4acd1 100644 --- a/spring-modulith-events/spring-modulith-events-core/src/main/java/org/springframework/modulith/events/support/CompletionRegisteringBeanPostProcessor.java +++ b/spring-modulith-events/spring-modulith-events-core/src/main/java/org/springframework/modulith/events/support/CompletionRegisteringBeanPostProcessor.java @@ -42,10 +42,9 @@ import org.springframework.util.ReflectionUtils; import org.springframework.util.ReflectionUtils.MethodCallback; /** - * {@link BeanPostProcessor} that will add a - * {@link CompletionRegisteringBeanPostProcessor.ProxyCreatingMethodCallback.CompletionRegisteringMethodInterceptor} to - * the bean in case it carries a {@link TransactionalEventListener} annotation so that the successful invocation of - * those methods mark the event publication to those listeners as completed. + * {@link BeanPostProcessor} that will add a {@link CompletionRegisteringMethodInterceptor} to the bean in case it + * carries a {@link TransactionalEventListener} annotation so that the successful invocation of those methods mark the + * event publication to those listeners as completed. * * @author Oliver Drotbohm */ diff --git a/spring-modulith-events/spring-modulith-events-core/src/main/java/org/springframework/modulith/events/support/PersistentApplicationEventMulticaster.java b/spring-modulith-events/spring-modulith-events-core/src/main/java/org/springframework/modulith/events/support/PersistentApplicationEventMulticaster.java index a5b0a728..1a3dbbdf 100644 --- a/spring-modulith-events/spring-modulith-events-core/src/main/java/org/springframework/modulith/events/support/PersistentApplicationEventMulticaster.java +++ b/spring-modulith-events/spring-modulith-events-core/src/main/java/org/springframework/modulith/events/support/PersistentApplicationEventMulticaster.java @@ -151,11 +151,11 @@ public class PersistentApplicationEventMulticaster extends AbstractApplicationEv /** * First-class collection to work with transactional event listeners, i.e. {@link ApplicationListener} instances that - * implement {@link TransactionalEventListenerMetadata}. + * implement {@link TransactionalApplicationListener}. * * @author Oliver Drotbohm * @see TransactionalEventListener - * @see TransactionalEventListenerMetadata + * @see TransactionalApplicationListener */ static class TransactionalEventListeners { @@ -163,7 +163,7 @@ public class PersistentApplicationEventMulticaster extends AbstractApplicationEv /** * Creates a new {@link TransactionalEventListeners} instance by filtering all elements implementing - * {@link TransactionalEventListenerMetadata}. + * {@link TransactionalApplicationListener}. * * @param listeners must not be {@literal null}. */ diff --git a/spring-modulith-events/spring-modulith-events-core/src/main/java/org/springframework/modulith/events/support/package-info.java b/spring-modulith-events/spring-modulith-events-core/src/main/java/org/springframework/modulith/events/support/package-info.java index c2b6e6c0..d21f792b 100644 --- a/spring-modulith-events/spring-modulith-events-core/src/main/java/org/springframework/modulith/events/support/package-info.java +++ b/spring-modulith-events/spring-modulith-events-core/src/main/java/org/springframework/modulith/events/support/package-info.java @@ -1,2 +1,5 @@ +/** + * Spring Framework extensions to integrate the event publication registry. + */ @org.springframework.lang.NonNullApi package org.springframework.modulith.events.support; diff --git a/spring-modulith-events/spring-modulith-events-jackson/src/main/java/org/springframework/modulith/events/jackson/package-info.java b/spring-modulith-events/spring-modulith-events-jackson/src/main/java/org/springframework/modulith/events/jackson/package-info.java index 577f08f0..b679183f 100644 --- a/spring-modulith-events/spring-modulith-events-jackson/src/main/java/org/springframework/modulith/events/jackson/package-info.java +++ b/spring-modulith-events/spring-modulith-events-jackson/src/main/java/org/springframework/modulith/events/jackson/package-info.java @@ -1,2 +1,5 @@ +/** + * A Jackson based implementation of the {@link org.springframework.modulith.events.EventSerializer}. + */ @org.springframework.lang.NonNullApi package org.springframework.modulith.events.jackson; diff --git a/spring-modulith-events/spring-modulith-events-jdbc/src/main/java/org/springframework/modulith/events/jdbc/package-info.java b/spring-modulith-events/spring-modulith-events-jdbc/src/main/java/org/springframework/modulith/events/jdbc/package-info.java index 148e6b1a..eb7f04a5 100644 --- a/spring-modulith-events/spring-modulith-events-jdbc/src/main/java/org/springframework/modulith/events/jdbc/package-info.java +++ b/spring-modulith-events/spring-modulith-events-jdbc/src/main/java/org/springframework/modulith/events/jdbc/package-info.java @@ -1,2 +1,5 @@ +/** + * JDBC integration for {@link org.springframework.modulith.events.EventPublicationRepository}. + */ @org.springframework.lang.NonNullApi package org.springframework.modulith.events.jdbc; diff --git a/spring-modulith-events/spring-modulith-events-jpa/src/main/java/org/springframework/modulith/events/jpa/package-info.java b/spring-modulith-events/spring-modulith-events-jpa/src/main/java/org/springframework/modulith/events/jpa/package-info.java index 9a6858fd..c09ece90 100644 --- a/spring-modulith-events/spring-modulith-events-jpa/src/main/java/org/springframework/modulith/events/jpa/package-info.java +++ b/spring-modulith-events/spring-modulith-events-jpa/src/main/java/org/springframework/modulith/events/jpa/package-info.java @@ -1,2 +1,5 @@ +/** + * JPA integration for {@link org.springframework.modulith.events.EventPublicationRepository}. + */ @org.springframework.lang.NonNullApi package org.springframework.modulith.events.jpa; diff --git a/spring-modulith-events/spring-modulith-events-mongodb/src/main/java/org/springframework/modulith/events/mongodb/package-info.java b/spring-modulith-events/spring-modulith-events-mongodb/src/main/java/org/springframework/modulith/events/mongodb/package-info.java index 6d371d06..4423ea27 100644 --- a/spring-modulith-events/spring-modulith-events-mongodb/src/main/java/org/springframework/modulith/events/mongodb/package-info.java +++ b/spring-modulith-events/spring-modulith-events-mongodb/src/main/java/org/springframework/modulith/events/mongodb/package-info.java @@ -1,2 +1,5 @@ +/** + * MongoDB integration for {@link org.springframework.modulith.events.EventPublicationRepository}. + */ @org.springframework.lang.NonNullApi package org.springframework.modulith.events.mongodb; diff --git a/spring-modulith-moments/src/main/java/org/springframework/modulith/moments/DayHasPassed.java b/spring-modulith-moments/src/main/java/org/springframework/modulith/moments/DayHasPassed.java index 937a9d65..b7c5d5e5 100644 --- a/spring-modulith-moments/src/main/java/org/springframework/modulith/moments/DayHasPassed.java +++ b/spring-modulith-moments/src/main/java/org/springframework/modulith/moments/DayHasPassed.java @@ -36,7 +36,7 @@ public class DayHasPassed implements DomainEvent { /** * Creates a new {@link DayHasPassed} for the given {@link LocalDate}. * - * @param month must not be {@literal null}. + * @param date must not be {@literal null}. */ private DayHasPassed(LocalDate date) { @@ -48,7 +48,7 @@ public class DayHasPassed implements DomainEvent { /** * Creates a new {@link DayHasPassed} for the given {@link LocalDate}. * - * @param month must not be {@literal null}. + * @param date must not be {@literal null}. */ public static DayHasPassed of(LocalDate date) { return new DayHasPassed(date); diff --git a/spring-modulith-moments/src/main/java/org/springframework/modulith/moments/autoconfigure/package-info.java b/spring-modulith-moments/src/main/java/org/springframework/modulith/moments/autoconfigure/package-info.java new file mode 100644 index 00000000..b9b41da6 --- /dev/null +++ b/spring-modulith-moments/src/main/java/org/springframework/modulith/moments/autoconfigure/package-info.java @@ -0,0 +1,5 @@ +/** + * Autoconfiguration for the {@link org.springframework.modulith.moments.support.Moments} API. + */ +@org.springframework.lang.NonNullApi +package org.springframework.modulith.moments.autoconfigure; diff --git a/spring-modulith-moments/src/main/java/org/springframework/modulith/moments/package-info.java b/spring-modulith-moments/src/main/java/org/springframework/modulith/moments/package-info.java index 500efc9f..9ee45940 100644 --- a/spring-modulith-moments/src/main/java/org/springframework/modulith/moments/package-info.java +++ b/spring-modulith-moments/src/main/java/org/springframework/modulith/moments/package-info.java @@ -1,2 +1,5 @@ +/** + * An Passage-of-Time events implementation. + */ @org.springframework.lang.NonNullApi package org.springframework.modulith.moments; diff --git a/spring-modulith-moments/src/main/java/org/springframework/modulith/moments/support/Moments.java b/spring-modulith-moments/src/main/java/org/springframework/modulith/moments/support/Moments.java index d2cf0a8f..8aab457c 100644 --- a/spring-modulith-moments/src/main/java/org/springframework/modulith/moments/support/Moments.java +++ b/spring-modulith-moments/src/main/java/org/springframework/modulith/moments/support/Moments.java @@ -39,6 +39,8 @@ import org.springframework.scheduling.annotation.Scheduled; import org.springframework.util.Assert; /** + * Core component to publish passage-of-time events. + * * @author Oliver Drotbohm */ public class Moments { diff --git a/spring-modulith-moments/src/main/java/org/springframework/modulith/moments/support/MomentsProperties.java b/spring-modulith-moments/src/main/java/org/springframework/modulith/moments/support/MomentsProperties.java index fb586808..fd325d55 100644 --- a/spring-modulith-moments/src/main/java/org/springframework/modulith/moments/support/MomentsProperties.java +++ b/spring-modulith-moments/src/main/java/org/springframework/modulith/moments/support/MomentsProperties.java @@ -98,7 +98,7 @@ public class MomentsProperties { /** * The {@link ZoneId} to determine times which are attached to the events published. Defaults to - * {@value ZoneOffset#UTC}. + * {@link ZoneOffset#UTC}. * * @return will never be {@literal null}. */ @@ -107,7 +107,7 @@ public class MomentsProperties { } /** - * The {@link Locale} to use when determining week boundaries. Defaults to {@value Locale#getDefault()}. + * The {@link Locale} to use when determining week boundaries. Defaults to {@link Locale#getDefault()}. * * @return will never be {@literal null}. */ @@ -154,8 +154,22 @@ public class MomentsProperties { return new MomentsProperties(granularity, zoneId, locale, enableTimeMachine, quarters); } + /** + * The granularity of events to publish. + * + * @author Oliver Drotbohm + */ static enum Granularity { - HOURS, DAYS; + + /** + * Publish hourly events. Will include daily events. + */ + HOURS, + + /** + * Publish daily events only. + */ + DAYS; } private static class ShiftedQuarters { diff --git a/spring-modulith-moments/src/main/java/org/springframework/modulith/moments/support/package-info.java b/spring-modulith-moments/src/main/java/org/springframework/modulith/moments/support/package-info.java new file mode 100644 index 00000000..31478239 --- /dev/null +++ b/spring-modulith-moments/src/main/java/org/springframework/modulith/moments/support/package-info.java @@ -0,0 +1,6 @@ +/** + * The {@link org.springframework.modulith.moments.support.Moments} abstraction to integrate with Spring Framework's + * scheduling. + */ +@org.springframework.lang.NonNullApi +package org.springframework.modulith.moments.support; diff --git a/spring-modulith-observability/src/main/java/org/springframework/modulith/observability/autoconfigure/package-info.java b/spring-modulith-observability/src/main/java/org/springframework/modulith/observability/autoconfigure/package-info.java new file mode 100644 index 00000000..11a576ba --- /dev/null +++ b/spring-modulith-observability/src/main/java/org/springframework/modulith/observability/autoconfigure/package-info.java @@ -0,0 +1,5 @@ +/** + * Autoconfiguration for the observability integration. + */ +@org.springframework.lang.NonNullApi +package org.springframework.modulith.observability.autoconfigure; diff --git a/spring-modulith-observability/src/main/java/org/springframework/modulith/observability/package-info.java b/spring-modulith-observability/src/main/java/org/springframework/modulith/observability/package-info.java new file mode 100644 index 00000000..83662785 --- /dev/null +++ b/spring-modulith-observability/src/main/java/org/springframework/modulith/observability/package-info.java @@ -0,0 +1,5 @@ +/** + * Support for application module observability. + */ +@org.springframework.lang.NonNullApi +package org.springframework.modulith.observability; diff --git a/spring-modulith-runtime/src/main/java/org/springframework/modulith/runtime/autoconfigure/package-info.java b/spring-modulith-runtime/src/main/java/org/springframework/modulith/runtime/autoconfigure/package-info.java new file mode 100644 index 00000000..a8c83482 --- /dev/null +++ b/spring-modulith-runtime/src/main/java/org/springframework/modulith/runtime/autoconfigure/package-info.java @@ -0,0 +1,5 @@ +/** + * Autoconfiguration the {@link org.springframework.modulith.model.ApplicationModules} runtime support. + */ +@org.springframework.lang.NonNullApi +package org.springframework.modulith.runtime.autoconfigure; diff --git a/spring-modulith-runtime/src/main/java/org/springframework/modulith/runtime/package-info.java b/spring-modulith-runtime/src/main/java/org/springframework/modulith/runtime/package-info.java new file mode 100644 index 00000000..a27f2429 --- /dev/null +++ b/spring-modulith-runtime/src/main/java/org/springframework/modulith/runtime/package-info.java @@ -0,0 +1,5 @@ +/** + * Support to run {@link org.springframework.modulith.model.ApplicationModules} at application runtime. + */ +@org.springframework.lang.NonNullApi +package org.springframework.modulith.runtime; diff --git a/spring-modulith-test/src/main/java/org/springframework/modulith/test/package-info.java b/spring-modulith-test/src/main/java/org/springframework/modulith/test/package-info.java new file mode 100644 index 00000000..1d0fd38f --- /dev/null +++ b/spring-modulith-test/src/main/java/org/springframework/modulith/test/package-info.java @@ -0,0 +1,5 @@ +/** + * Integration test support for Spring Modulith {@link org.springframework.modulith.model.ApplicationModules}. + */ +@org.springframework.lang.NonNullApi +package org.springframework.modulith.test; diff --git a/src/docs/resources/assemblies/docs.xml b/src/docs/resources/assemblies/docs.xml index 63b648e0..5e7f71de 100644 --- a/src/docs/resources/assemblies/docs.xml +++ b/src/docs/resources/assemblies/docs.xml @@ -13,6 +13,16 @@ --> target/generated-docs reference + + **/.asciidoctor/** + + + + + ../target/site/apidocs + api