cancel
Showing results for 
Search instead for 
Did you mean: 

Jar version mismatch on SAP AS Java server

former_member187977
Participant
0 Kudos
156

Dear all,


I am trying to connect to external payment agency called as Bill

Junction.

The agency has given us below Jar files to use

bcjceprovider

commons-codec-1.3

javax-xml-soap-1.6.0

log4j-1.2.17

saaj-impl-1.3.4

SingleURLJARWithoutLIB_out

I have added these jar files in a external library type of a DC and

deployed its deployable version on the server.

My Java code is written below

  • objTransactionRequestBean.setWebServiceLocator(WEBsERVICE_LOCATOR);    

                        wdComponentAPI.getMessageManager().reportSuccess("4");

                        System.setProperty("proxySet", "true");

                        System.setProperty("https.proxyHost", "171.15.109.173");

                        System.setProperty("https.proxyPort", "8080");

                         System.getProperties().put("https.proxyUser", "tecnet\\cg-mohammad");

                              System.getProperties().put("https.proxyPassword", "Pass@xyz");

                        System.getProperties().put("proxy.authentication.username", "tecnet\\ucssuser");

                        System.getProperties().put("proxy.authentication.password", "Kingdom@xyz");  

           

           

            String url1 = objTransactionRequestBean.getTransactionToken();

           

            wdComponentAPI.getMessageManager().reportSuccess(url1);

java.lang.IllegalArgumentException:

com.sun.xml.internal.messaging.saaj.soap.LocalStrings !=

com.sun.xml.messaging.saaj.soap.LocalStrings

The line of code at which this exception occurs is

String url1 = objTransactionRequestBean.getTransactionToken();

The external agency suggests that there is a older version of saaj-impl

jar file on SAP AS Java server and the code is referring to that one

for execution and hence failing with IllegalArgumentException.


I did a find on the server for saaj-impl and obtained few locations where saaj-impl jar file is located. I replaced it with the jar file saaj-impl-1.3.4.jar given by the payment agency and restarted the server with a hope that the my java code will start referring the new version of saaj-impl jar file. But it did not happen so.

Please suggest steps to resolve this issue.

View Entire Topic
0 Kudos

Hi,

I am facing the same problem for other payment gateway.

How you fix the problem please suggest me.Also what is the path of the saaj-impl in the portal server.

Thanks and Regards,

Amit

vijay_kumar49
Active Contributor
0 Kudos

You have multiple different versioned SAAJ libraries in your webapp's runtime classpath. SAAJ is already bundled with JDK. Probably you have some saaj-*.jar file in your webapp's /WEB-INF/libwhich is conflicting with JDK-bundled SAAJ library. Cleanup it


Refer this Check Here

0 Kudos

Hi Vijay,

Thanks for your reply.I have removed the saaj-impl-1.3.4.jar file from my web app lib folder but it will always throw the 500 internal server error.But when go through the default_trace log file from my web server it will shown the below exceptions :

[EXCEPTION]

java.lang.NoClassDefFoundError: com/sun/xml/messaging/saaj/soap/SAAJMetaFactoryImpl : cannot initialize class because prior initialization attempt failed

          at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)

          at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)

          at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)

          at java.lang.reflect.Constructor.newInstance(Constructor.java:513)

          at java.lang.Class.newInstance0(Class.java:361)

          at java.lang.Class.newInstance(Class.java:314)

          at javax.xml.soap.FactoryFinder.newInstance(FactoryFinder.java:47)

          at javax.xml.soap.FactoryFinder.find(FactoryFinder.java:178)

          at javax.xml.soap.FactoryFinder.find(FactoryFinder.java:98)

          at javax.xml.soap.SAAJMetaFactory.getInstance(SAAJMetaFactory.java:59)

          at javax.xml.soap.MessageFactory.newInstance(MessageFactory.java:132)

          at com.sun.xml.messaging.saaj.client.p2p.HttpSOAPConnection.<init>(HttpSOAPConnection.java:87)

          at com.sun.xml.messaging.saaj.client.p2p.HttpSOAPConnectionFactory.createConnection(HttpSOAPConnectionFactory.java:52)

          at com.tp.pg.util.shopping.SoapWSCall.getToken(SoapWSCall.java:96)

          at com.tp.pg.util.shopping.SoapWSCall.getTransactionToken(SoapWSCall.java:56)

          at com.tp.pg.util.TransactionRequestBean.getTransactionToken(TransactionRequestBean.java:554)

          at in.hpseb.Action.InitiateICICIAction.doPost(InitiateICICIAction.java:79)

          at javax.servlet.http.HttpServlet.service(HttpServlet.java:754)

          at javax.servlet.http.HttpServlet.service(HttpServlet.java:847)

          at com.sap.engine.services.servlets_jsp.server.Invokable.invoke(Invokable.java:152)

          at com.sap.engine.services.servlets_jsp.server.Invokable.invoke(Invokable.java:38)

          at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:466)

          at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:210)

          at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:441)

          at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:430)

          at com.sap.engine.services.servlets_jsp.filters.DSRWebContainerFilter.process(DSRWebContainerFilter.java:38)

          at com.sap.engine.services.httpserver.chain.AbstractChain.process(AbstractChain.java:78)

          at com.sap.engine.services.servlets_jsp.filters.ServletSelector.process(ServletSelector.java:81)

          at com.sap.engine.services.httpserver.chain.AbstractChain.process(AbstractChain.java:78)

          at com.sap.engine.services.servlets_jsp.filters.ApplicationSelector.process(ApplicationSelector.java:278)

          at com.sap.engine.services.httpserver.chain.AbstractChain.process(AbstractChain.java:78)

          at com.sap.engine.services.httpserver.filters.WebContainerInvoker.process(WebContainerInvoker.java:81)

          at com.sap.engine.services.httpserver.chain.HostFilter.process(HostFilter.java:9)

          at com.sap.engine.services.httpserver.chain.AbstractChain.process(AbstractChain.java:78)

          at com.sap.engine.services.httpserver.filters.ResponseLogWriter.process(ResponseLogWriter.java:60)

          at com.sap.engine.services.httpserver.chain.HostFilter.process(HostFilter.java:9)

          at com.sap.engine.services.httpserver.chain.AbstractChain.process(AbstractChain.java:78)

          at com.sap.engine.services.httpserver.filters.DefineHostFilter.process(DefineHostFilter.java:27)

          at com.sap.engine.services.httpserver.chain.ServerFilter.process(ServerFilter.java:12)

          at com.sap.engine.services.httpserver.chain.AbstractChain.process(AbstractChain.java:78)

          at com.sap.engine.services.httpserver.filters.MonitoringFilter.process(MonitoringFilter.java:29)

          at com.sap.engine.services.httpserver.chain.ServerFilter.process(ServerFilter.java:12)

          at com.sap.engine.services.httpserver.chain.AbstractChain.process(AbstractChain.java:78)

          at com.sap.engine.services.httpserver.filters.SessionSizeFilter.process(SessionSizeFilter.java:26)

          at com.sap.engine.services.httpserver.chain.ServerFilter.process(ServerFilter.java:12)

          at com.sap.engine.services.httpserver.chain.AbstractChain.process(AbstractChain.java:78)

          at com.sap.engine.services.httpserver.filters.MemoryStatisticFilter.process(MemoryStatisticFilter.java:57)

          at com.sap.engine.services.httpserver.chain.ServerFilter.process(ServerFilter.java:12)

          at com.sap.engine.services.httpserver.chain.AbstractChain.process(AbstractChain.java:78)

          at com.sap.engine.services.httpserver.filters.DSRHttpFilter.process(DSRHttpFilter.java:43)

          at com.sap.engine.services.httpserver.chain.ServerFilter.process(ServerFilter.java:12)

          at com.sap.engine.services.httpserver.chain.AbstractChain.process(AbstractChain.java:78)

          at com.sap.engine.services.httpserver.server.Processor.chainedRequest(Processor.java:475)

          at com.sap.engine.services.httpserver.server.Processor$FCAProcessorThread.process(Processor.java:269)

          at com.sap.engine.services.httpserver.server.rcm.RequestProcessorThread.run(RequestProcessorThread.java:56)

          at com.sap.engine.core.thread.execution.Executable.run(Executable.java:122)

          at com.sap.engine.core.thread.execution.Executable.run(Executable.java:101)

          at com.sap.engine.core.thread.execution.CentralExecutor$SingleThread.run(CentralExecutor.java:328)

Caused by: java.lang.ExceptionInInitializerError

          ... 58 more

Caused by: java.lang.IllegalArgumentException: com.sun.xml.internal.messaging.saaj.soap.LocalStrings != com.sun.xml.messaging.saaj.soap.LocalStrings

          at java.util.logging.Logger.getLogger(Logger.java:377)

          at com.sun.xml.messaging.saaj.soap.SAAJMetaFactoryImpl.<clinit>(SAAJMetaFactoryImpl.java:52)

Please help me on this,I am unable to understand the what is the issue.

Thanks and Regards,

Amit Basak

vijay_kumar49
Active Contributor