Class ApplicationModuleDetectionStrategyLookup

java.lang.Object
org.springframework.modulith.core.ApplicationModuleDetectionStrategyLookup

class ApplicationModuleDetectionStrategyLookup extends Object
A factory for the ApplicationModuleDetectionStrategy to be used when scanning code for ApplicationModules.
Author:
Oliver Drotbohm
  • Constructor Details

    • ApplicationModuleDetectionStrategyLookup

      ApplicationModuleDetectionStrategyLookup()
  • Method Details

    • getStrategy

      static ApplicationModuleDetectionStrategy getStrategy()
      Returns the ApplicationModuleDetectionStrategy to be used to detect ApplicationModules. Will use the following algorithm:
      1. Use the prepared strategies if either direct-sub-packages or explicitly-annotated is configured for the spring.modulith.detection-strategy configuration property.
      2. Interpret the configured value as class if it doesn't match the predefined values just described.
      3. Use the ApplicationModuleDetectionStrategy declared in META-INF/spring.properties (deprecated)
      4. A final fallback on the direct-sub-packages.
      Returns:
      will never be null.