IBM Support

Sun JDK "endorsed" library files errors: 'toUpperCase' is not a valid object reference OR java.lang.NoClassDefFoundError: com/yantra/interop/japi/YIFCustomApi

Troubleshooting


Problem

Sun JDK "endorsed" library files errors: 'toUpperCase' is not a valid object reference OR java.lang.NoClassDefFoundError: com/yantra/interop/japi/YIFCustomApi

Symptom

We have observed at least two scenarios wherein although the setting and error is different, the resolution is the same. These can occur with Sterling Supply Chain Applications (SCA) / Multi-Channel Fulfillment (MCF) version 7x/8x products.

1. When installing Hot Fixes, errors may be thrown during the XSD generation task of the installation.

2. When starting Agent Servers, errors may be thrown indicating a class definition failure.

These errors are often a side-effect of using a Sun JDK (versions 5x/6x). The Sun JDK has its own version of several XML parsing library files that tend to override the corresponding JAR files provided by Sterling.

Error Message

1. Hot Fix installation / XSD generation errors can appear as (example):

[java] Parsing upgrade file....
[java] ERROR: 'The first argument to the non-static Java function 'toUpperCase' is not a valid object reference.'
[java] FATAL ERROR: 'Could not compile stylesheet'
[java] ErrorCode="javax.xml.transform.TransformerConfigurationException"

2. Agent Server initialization / Class definition errors can appear as (example):

Exception in thread "XXX" java.lang.NoClassDefFoundError: com/yantra/interop/japi/YIFCustomApi
at java.lang.ClassLoader.findBootstrapClass(Native Method)
at java.lang.ClassLoader.findBootstrapClass0(ClassLoader.java:891)
at java.lang.ClassLoader.loadClass(ClassLoader.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:299)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:268)
at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:164)
at com.yantra.interop.services.flowcomponents.ApiFlowComponent.resolveClassName(Api FlowComponent.java:267)

Resolving The Problem

Solution

1. For Hot Fix installation / XSD generation errors, delete any existing Hot Fix installation folders (from previous runs).

2. Create a new folder called "endorsed", as follows:

a. For SCA 7x, under <JAVA_HOME>/jre/lib folder.

b. For MCF 8x (formerly SCA), under <INSTALL_DIR>/jdk/jre/lib folder.

3. Copy to the "endorsed" folder, the following files:

a. For SCA 7x,

<YFS_HOME>/lib/serializer.jar
<YFS_HOME>/lib/xalan.jar
<YFS_HOME>/lib/xercesImpl.jar
<YFS_HOME>/lib/xml-apis.jar

b. For MCF 8x (formerly SCA),

<INSTALL_DIR>/installed_data/platform_afc/files/repository/eardata/platform/w ar/yfscommon/serializer.jar
<INSTALL_DIR>/installed_data/platform_afc/files/repository/eardata/platform/war/ yfscommon/xalan.jar
<INSTALL_DIR>/installed_data/platform_afc/files/repository/eardata/platform/war/ yfscommon/xercesImpl.jar
<INSTALL_DIR>/installed_data/platform_afc/files/repository/eardata/platform/war/ yfscommon/xml-apis.jar
and, if necessary,
<INSTALL_DIR>/installed_data/platform_afc/files/repository/eardata/platform/war/ yfscommon/xmlParserAPIs.jar

4a. For Hot Fix installation / XSD generation errors, re-run the Hot Fix process again following the normal instructions.

4b. For Agent Server initialization / Class definition errors, restart the Agent Server.

[{"Product":{"code":"SS6PEW","label":"IBM Sterling Order Management"},"Business Unit":{"code":"BU048","label":"IBM Software"},"Component":"Not Applicable","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"All","Edition":"","Line of Business":{"code":"LOB59","label":"Sustainability Software"}}]

Historical Number

TRB2883

Document Information

Modified date:
16 June 2018

UID

swg21560601