camel-xj-kafka-connector sink configuration

When using camel-xj-kafka-connector as sink make sure to use the following Maven dependency to have support for the connector:

<dependency>
  <groupId>org.apache.camel.kafkaconnector</groupId>
  <artifactId>camel-xj-kafka-connector</artifactId>
  <version>x.x.x</version>
  <!-- use the same version as your Camel Kafka connector version -->
</dependency>

To use this Sink connector in Kafka connect you’ll need to set the following connector.class

connector.class=org.apache.camel.kafkaconnector.xj.CamelXjSinkConnector

The camel-xj sink connector supports 30 options, which are listed below.

Name Description Default Priority

camel.sink.path.resourceUri

Path to the template. The following is supported by the default URIResolver. You can prefix with: classpath, file, http, ref, or bean. classpath, file and http loads the resource using these protocols (classpath is default). ref will lookup the resource in the registry. bean will call a method on a bean to be used as the resource. For bean you can specify the method name after dot, eg bean:myBean.myMethod

null

HIGH

camel.sink.endpoint.allowStAX

Whether to allow using StAX as the javax.xml.transform.Source. You can enable this if the XSLT library supports StAX such as the Saxon library (camel-saxon). The Xalan library (default in JVM) does not support StAXSource.

true

MEDIUM

camel.sink.endpoint.contentCache

Cache for the resource content (the stylesheet file) when it is loaded. If set to false Camel will reload the stylesheet file on each message processing. This is good for development. A cached stylesheet can be forced to reload at runtime via JMX using the clearCachedStylesheet operation.

true

MEDIUM

camel.sink.endpoint.deleteOutputFile

If you have output=file then this option dictates whether or not the output file should be deleted when the Exchange is done processing. For example suppose the output file is a temporary file, then it can be a good idea to delete it after use.

false

MEDIUM

camel.sink.endpoint.failOnNullBody

Whether or not to throw an exception if the input body is null.

true

MEDIUM

camel.sink.endpoint.lazyStartProducer

Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the route to fail being started. By deferring this startup to be lazy then the startup failure can be handled during routing messages via Camel’s routing error handlers. Beware that when the first message is processed then creating and starting the producer may take a little time and prolong the total processing time of the processing.

false

MEDIUM

camel.sink.endpoint.output

Option to specify which output type to use. Possible values are: string, bytes, DOM, file. The first three options are all in memory based, where as file is streamed directly to a java.io.File. For file you must specify the filename in the IN header with the key Exchange.XSLT_FILE_NAME which is also CamelXsltFileName. Also any paths leading to the filename must be created beforehand, otherwise an exception is thrown at runtime. One of: [string] [bytes] [DOM] [file]

"string"

MEDIUM

camel.sink.endpoint.transformDirection

Transform direction. Either XML2JSON or JSON2XML One of: [XML2JSON] [JSON2XML]

null

HIGH

camel.sink.endpoint.transformerCacheSize

The number of javax.xml.transform.Transformer object that are cached for reuse to avoid calls to Template.newTransformer().

0

MEDIUM

camel.sink.endpoint.basicPropertyBinding

Whether the endpoint should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities

false

MEDIUM

camel.sink.endpoint.entityResolver

To use a custom org.xml.sax.EntityResolver with javax.xml.transform.sax.SAXSource.

null

MEDIUM

camel.sink.endpoint.errorListener

Allows to configure to use a custom javax.xml.transform.ErrorListener. Beware when doing this then the default error listener which captures any errors or fatal errors and store information on the Exchange as properties is not in use. So only use this option for special use-cases.

null

MEDIUM

camel.sink.endpoint.resultHandlerFactory

Allows you to use a custom org.apache.camel.builder.xml.ResultHandlerFactory which is capable of using custom org.apache.camel.builder.xml.ResultHandler types.

null

MEDIUM

camel.sink.endpoint.saxonConfiguration

To use a custom Saxon configuration

null

MEDIUM

camel.sink.endpoint.saxonExtensionFunctions

Allows you to use a custom net.sf.saxon.lib.ExtensionFunctionDefinition. You would need to add camel-saxon to the classpath. The function is looked up in the registry, where you can comma to separate multiple values to lookup.

null

MEDIUM

camel.sink.endpoint.synchronous

Sets whether synchronous processing should be strictly used, or Camel is allowed to use asynchronous processing (if supported).

false

MEDIUM

camel.sink.endpoint.transformerFactory

To use a custom XSLT transformer factory

null

MEDIUM

camel.sink.endpoint.transformerFactoryClass

To use a custom XSLT transformer factory, specified as a FQN class name

null

MEDIUM

camel.sink.endpoint.transformerFactory ConfigurationStrategy

A configuration strategy to apply on freshly created instances of TransformerFactory.

null

MEDIUM

camel.sink.endpoint.uriResolver

To use a custom javax.xml.transform.URIResolver

null

MEDIUM

camel.component.xj.contentCache

Cache for the resource content (the stylesheet file) when it is loaded. If set to false Camel will reload the stylesheet file on each message processing. This is good for development. A cached stylesheet can be forced to reload at runtime via JMX using the clearCachedStylesheet operation.

true

MEDIUM

camel.component.xj.lazyStartProducer

Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the route to fail being started. By deferring this startup to be lazy then the startup failure can be handled during routing messages via Camel’s routing error handlers. Beware that when the first message is processed then creating and starting the producer may take a little time and prolong the total processing time of the processing.

false

MEDIUM

camel.component.xj.basicPropertyBinding

Whether the component should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities

false

MEDIUM

camel.component.xj.saxonConfiguration

To use a custom Saxon configuration

null

MEDIUM

camel.component.xj.saxonConfigurationProperties

To set custom Saxon configuration properties

null

MEDIUM

camel.component.xj.saxonExtensionFunctions

Allows you to use a custom net.sf.saxon.lib.ExtensionFunctionDefinition. You would need to add camel-saxon to the classpath. The function is looked up in the registry, where you can comma to separate multiple values to lookup.

null

MEDIUM

camel.component.xj.transformerFactoryClass

To use a custom XSLT transformer factory, specified as a FQN class name

null

MEDIUM

camel.component.xj.transformerFactoryConfiguration Strategy

A configuration strategy to apply on freshly created instances of TransformerFactory.

null

MEDIUM

camel.component.xj.uriResolver

To use a custom UriResolver. Should not be used together with the option 'uriResolverFactory'.

null

MEDIUM

camel.component.xj.uriResolverFactory

To use a custom UriResolver which depends on a dynamic endpoint resource URI. Should not be used together with the option 'uriResolver'.

null

MEDIUM

The camel-xj sink connector has no converters out of the box.

The camel-xj sink connector has no transforms out of the box.

The camel-xj sink connector has no aggregation strategies out of the box.