Skip to main content

This content has been archived and is no longer being updated. Links may not function; however, this content may be relevant to outdated versions of the product.

Support Article

ClassNotFoundException when setting up JNDI Server

SA-30986

Summary



User is planning to set up an EJB connection with an external Java application and trying to set up the JNDI rule.

So they are setting up JNDI server in Pega 7.2.1 on WebSphere Liberty profile 16.0.0.3. and typed "com.ibm.websphere.naming.WsnInitialContextFactory" as "Initial context factory".

However, after saving the rule and clicking "Test connectivity", an error popped up.


Error Messages



Configuration Issues
Required classes are not available. Please check the configuration.

Error Details:
java.lang.ClassNotFoundException: com.ibm.websphere.naming.WsnInitialContextFactory


Steps to Reproduce



1. Setup Pega 7.2.1 environment with WebSphere Liberty Profile 16.0.0.3.
2. Create "JNDI Server" rule.
3. Type "com.ibm.websphere.naming.WsnInitialContextFactory" for "Initial context factory".
4. Type valid "Provider URL".
5. Save the JNDI Server rule.
6. Click "Test connectivity" button.


Root Cause


The root cause is in the third-party product WebSphere Liberty profile 16.0.0.3. WsnInitialContextFactory is deprecated in this version.


Resolution



Perform the following local-change:
  1. Copy the jar which contains WsnInitialContextFactory (com.ibm.ws.ejb.thinclient_8.5.0.jar) in the ext folder of web server.
  2. Restart the node.
One can also include the jar in the prconfig file as below:
 
    <env name="classloader/classpath" value="dir/applib/thirdParty.jar" />

Published October 8, 2020

Was this useful?

0% found this useful

Have a question? Get answers now.

Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.

Did you find this content helpful?

We'd prefer it if you saw us at our best.

Pega Community has detected you are using a browser which may prevent you from experiencing the site as intended. To improve your experience, please update your browser.

Close Deprecation Notice