Knative Trait
The Knative trait automatically discovers addresses of Knative resources and inject them into the running integration.
The full Knative configuration is injected in the CAMEL_KNATIVE_CONFIGURATION in JSON format. The Camel Knative component will then use the full configuration to configure the routes.
The trait is enabled by default when the Knative profile is active.
This trait is available in the following profiles: Knative.
Configuration
Trait properties can be specified when running any integration with the CLI:
$ kamel run --trait knative.[key]=[value] --trait knative.[key2]=[value2] integration.groovy
The following configuration options are available:
Property | Type | Description |
---|---|---|
|
|
Can be used to enable or disable a trait. All traits share this common property. |
|
|
Can be used to inject a Knative complete configuration in JSON format. |
|
|
List of channels used as source of integration routes. Can contain simple channel names or full Camel URIs. |
|
|
List of channels used as destination of integration routes. Can contain simple channel names or full Camel URIs. |
|
|
List of channels used as source of integration routes. |
|
|
List of endpoints used as destination of integration routes. Can contain simple endpoint names or full Camel URIs. |
|
|
List of event types that the integration will be subscribed to. Can contain simple event types or full Camel URIs (to use a specific broker different from "default"). |
|
|
List of event types that the integration will produce. Can contain simple event types or full Camel URIs (to use a specific broker). |
|
|
Enables filtering on events based on the header "ce-knativehistory". Since this header has been removed in newer versions of Knative, filtering is disabled by default. |
|
|
Enables Knative CamelSource pre 0.15 compatibility fixes (will be removed in future versions). |
|
|
Allows binding the integration to a sink via a Knative SinkBinding resource. This can be used when the integration targets a single sink. It’s enabled by default when the integration targets a single sink (except when the integration is owned by a Knative source). |
|
|
Enable automatic discovery of all trait properties. |