Interface CamelContextCustomizer
- All Superinterfaces:
Comparable<CamelContextCustomizer>, Ordered
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
@FunctionalInterface
public interface CamelContextCustomizer
extends Ordered, Comparable<CamelContextCustomizer>
Strategy for applying custom configuration to a
CamelContext after it has been created.
Customizers are discovered from the Registry and invoked during bootstrap, giving a hook to programmatically
tune the context (adding services, configuring options, registering beans) without subclassing. Multiple customizers
run in Ordered order. This is most commonly used by runtimes such as Spring Boot and Quarkus to apply
user-provided configuration. The sibling SPIs ComponentCustomizer, DataFormatCustomizer, and
LanguageCustomizer customize individual components, data formats, and languages.
See CamelContext auto-configuration in
the Camel user manual.- Since:
- 3.6
- See Also:
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptiondefault intcompareTo(CamelContextCustomizer other) voidconfigure(CamelContext camelContext) Configure theCamelContext.default intgetOrder()Gets the order.
-
Method Details
-
configure
Configure theCamelContext.- Parameters:
camelContext- the camel context to configure.
-
getOrder
default int getOrder()Description copied from interface:OrderedGets the order. Use low numbers for higher priority. Normally the sorting will start from 0 and move upwards. So if you want to be last then useInteger.MAX_VALUEor egOrdered.LOWEST. -
compareTo
- Specified by:
compareToin interfaceComparable<CamelContextCustomizer>
-