Reputation: 191
I have java_home set in linux and in bin/karaf script file one entry is:
JAVA_EXT_DIRS="${JAVA_HOME}/jre/lib/ext:${JAVA_HOME}/lib/ext:${JAVA_HOME}/jre/lib:${KARAF_HOME}/lib/ext"
When my karaf is up and running and a flow is tested below error is throw:
Caused by: java.lang.ClassNotFoundException: javax.xml.transform.TransformerFactoryConfigurationError not found..
But this should be provided by rt.jar and rt.jar is present in "${JAVA_HOME}/jre/lib" hence I added same section in JAVA_EXT_DIRS entry. But same error persists.
I should get java libraries from karaf. Help me understanding the cause.
Upvotes: 0
Views: 750
Reputation: 23948
Your bundle needs to import the package javax.xml.transform
in its Import-Package statement.
In general you need to import all packages that you actually use, with the sole exception of packages beginning with java.
, which includes for example java.lang
, java.util
etc but not javax.*
.
Upvotes: 2