@Target(value={TYPE,METHOD})
@Retention(value=RUNTIME)
@Documented
@Profile(value="flamingock-cli")
public @interface FlamingockCliOnly
This is a convenience meta-annotation that wraps @Profile("flamingock-cli").
Use this annotation on components or bean methods that should only be loaded
when the application is executed via the Flamingock CLI.
Example usage:
@Component
@FlamingockCliOnly
public class CliOnlyService {
// This bean will only be loaded when running via Flamingock CLI
}
@Configuration
public class MyConfig {
@Bean
@FlamingockCliOnly
public MyBean cliOnlyBean() {
// This bean will only be loaded when running via Flamingock CLI
return new MyBean();
}
}
FlamingockCliExcluded,
Profile