If you use third-party or custom Java packages in the Java transformation, configure at least one classpath value.
You can set the following classpath values:
JVMClassPath property for the Secure Agent
The Secure Agent uses this classpath when you design and validate the Java transformation, run the mapping from the Mapping Designer, or run the
mapping
task. This classpath applies to all mappings and
mapping
tasks that run on the agent.
Set the JVMClassPath property for the Secure Agent in
Administrator
.
Set this property or set the CLASSPATH environment variable on the Secure Agent machine. You do not need to set both classpath values.
CLASSPATH environment variable
The Secure Agent uses this classpath when you design and validate the Java transformation, run the mapping from the Mapping Designer, or run the
mapping
task. This classpath applies to all mappings and
mapping
tasks that run on the agent.
Set the CLASSPATH environment variable on the Secure Agent machine.
Set the CLASSPATH environment variable or set the JVMClassPath property for the Secure Agent. You do not need to set both classpath values.
Design time classpath
The Secure Agent uses this classpath when you design and validate the Java transformation and when you run the mapping from the Mapping Designer. This classpath is not used when you run the mapping through a
mapping
task.
Set the design-time classpath when you want to test the transformation and neither the JVMClassPath property nor the CLASSPATH environment variable contain the required packages. If you configured the JVMClassPath property or the CLASSPATH environment variable to include the required packages, then you do not need to configure the design time classpath.
You configure the design-time classpath in the Java transformation advanced properties.
Java Classpath session property
The Secure Agent uses this classpath when you run the
mapping
task. This classpath applies only to the
mapping
task in which the property is set.
Set the Java Classpath session property when you want the classpath to apply to one
mapping
task but not others. If you configured the JVMClassPath property or the CLASSPATH environment variable to include the required packages, then you do not need to configure the Java Classpath session property.
Set the Java Classpath session property in the advanced session properties of the
mapping
task.
If you set multiple classpath values, the Secure Agent uses all of the classpaths that apply. For example, you set the JVMClassPath property for the Secure Agent, the CLASSPATH environment variable, and the design time classpath in the Java transformation. When you compile the Java code in the Java transformation or run the mapping through the Mapping Designer, the Secure Agent uses all three classpaths. When you run the mapping through a
mapping
task, the Secure Agent uses the JVMClassPath and the CLASSPATH environment variable only.
If you set multiple classpaths, ensure that they do not create multiple copies of a class or resource which can cause runtime errors.