IBM Streams 4.2

Developing Java primitive operators

To create a Java™ primitive operator inside an SPL toolkit, you must provide an operator model. The process is similar to how you provide operator models for C++ primitive operators.

Java primitive operators are defined inside SPL toolkit namespace directories, similar to their C++ counterparts. As a result, Java primitive operators have their own names and namespaces within SPL applications. These names and namespaces are derived from the Java primitive operator's location within the toolkit directory, using the exact same rules that are used for C++ primitive operators. Unlike C++ primitive operators, no code generation templates are associated with Java primitive operators in their toolkit directory.

Any dependencies that the Java primitive operator might have on the Java operator implementation and other Java libraries that are required are specified as part of its Java operator model and do not appear in the SPL invocation of the operator. As a part of the SPL invocation of the operator, you can use the vmArg parameter to specify additional JVM arguments that are required by the specific invocation of the operator. The values that are specified in vmArg are appended to the vmArg values listed in the execution settings of the Java primitive operator. If the appended JVM arguments match the arguments in vmArg, the appended values take precedence over the existing vmArg values that are listed in the execution settings.