On migration application from glassfish 3 to glassfish 5 and jdk-6 to jdk-8, I am getting following error on console. What could be the possible reasons for EJB not getting deployed on glassfish server?
Exception while invoking class org.glassfish.ejb.startup.EjbDeployer
load method java.lang.RuntimeException: EJB Container initialization
error at
org.glassfish.ejb.startup.EjbApplication.loadContainers(EjbApplication.java:234)
...
Caused by: java.lang.IllegalAccessException: Class
com.sun.ejb.containers.BaseContainer can not access a member of class
my.package.$Proxy280 with modifiers "public"> at sun.reflect.Reflection.ensureMemberAccess(Reflection.java:102)
Related
I am using spring Webservicetemplate to access soap service. The soap client package has been deployed in websphere. The deployment was successful but its throwing following error during SOAP api invocation.
Caused by: java.lang.LinkageError: loading constraint violation when resolving method "javax/xml/soap/SOAPElement.getElementQName()Ljavax/xml/namespace/QName;" : loader "com/ibm/ws/classloader/CompoundClassLoader#69ddc3da" of class "org/springframework/ws/soap/saaj/SaajSoapElement" and loader "com/ibm/oti/vm/BootstrapClassLoader#6d67c67c" of class "javax/xml/soap/SOAPElement" have different types for the method signature
at org.springframework.ws.soap.saaj.SaajSoapElement.getName(SaajSoapElement.java:51)
at org.springframework.ws.soap.AbstractSoapMessage.getVersion(AbstractSoapMessage.java:89)
at org.springframework.ws.soap.saaj.SaajSoapMessage.setSoapAction(SaajSoapMessage.java:168)
Can anyone please assist ?
I am using Websphere 7 and recently i am getting this error while trying to start the application.
00000018 servlet E com.ibm.ws.webcontainer.servlet.ServletWrapper init SRVE0100E: Uncaught init() exception created by servlet Application Initialization Servlet in application xxx-Portal: java.lang.NullPointerException
at com.xyz.zyx.web.init.ApplicationInitServlet.init(ApplicationInitServlet.java:75)
and the code is :
final Properties props =
init.initialize(url, getServletContext().getRealPath("/WEB-INF/classes"));
Don't know what happened all of a sudden..Something i have to change in the server parameters since I cannot change the code.
The solution was simple:
Go to installed applicaton > class loader and update detection > under WAR Class loader policy, select 'Single Class Loader'
Now the application will start.
Found it after long struggle .
I am trying to deploy Spring web application using Spring Web Services on Websphere 8. Deploy to Tomcat works without any problem but with Websphere I needed to add jaxws-rt (this wasn't needed for Tomcat, but also with it is working) and after that I am still getting on WAS:
CWNEN0044E: A resource reference binding could not be found for the following resource
references [com.sun.xml.ws.transport.tcp.servicechannel.ServiceChannelWSImpl/wsContext,
com.sun.xml.ws.tx.webservice.member.coord.RegistrationRequesterPortTypeImpl/wsContext,
com.sun.xml.ws.tx.webservice.member.coord.RegistrationPortTypeImpl/wsContext,
com.sun.xml.ws.tx.webservice.member.coord.ActivationRequesterPortTypeImpl/wsContext,
com.sun.xml.ws.tx.webservice.member.coord.RegistrationCoordinatorPortTypeImpl/wsContext,
com.sun.xml.ws.mex.server.MEXEndpoint/wsContext,
com.sun.xml.ws.tx.webservice.member.at.CoordinatorPortTypeImpl/wsContext,
com.sun.xml.ws.tx.webservice.member.coord.ActivationCoordinatorPortTypeImpl/wsContext,
com.sun.xml.ws.tx.webservice.member.at.CompletionInitiatorPortTypeImpl/wsContext,
com.sun.xml.ws.tx.webservice.member.at.ParticipantPortTypeImpl/wsContext,
com.sun.xml.ws.tx.webservice.member.at.CompletionCoordinatorPortTypeImpl/wsContext]
How to specify reference bindings?
I also see another error during deployin SystemErr:
Caused by: com.ibm.ws.webcontainer.exception.WebAppNotLoadedException: Failed to load
webapp: Failed to load webapp: javax.servlet.ServletContainerInitializer: Provider
com.sun.xml.ws.transport.http.servlet.WSServletContainerInitializer not a subtype
But I am not sure if this is somehow connected with reference binding problem.
I've deployed Worklight 6 on WebSphere 8.5.5 trying to follow these instructions ( http://pic.dhe.ibm.com/infocenter/wrklight/v6r0m0/index.jsp ) with a derby database and I've encountered the following error when trying to hit my Worklight instance:
Error 500: javax.servlet.ServletException: Worklight Project not initialized
When I check the log, I can see that the worklight server has not been started due to this exception:
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'brokerSessionFactory' defined in URL [jar:file:/C:/IBM/WebSphere/AppServer/lib/worklight-jee-library-6.0.0.jar!/conf/spring-server-core.xml]: Invocation of init method failed; nested exception is java.lang.AbstractMethodError: javax/persistence/spi/PersistenceUnitInfo.getValidationMode()Ljavax/persistence/ValidationMode;
...
Caused by: java.lang.AbstractMethodError: javax/persistence/spi/PersistenceUnitInfo.getValidationMode()Ljavax/persistence/ValidationMode
at org.apache.openjpa.persistence.PersistenceUnitInfoImpl.toOpenJPAProperties(PersistenceUnitInfoImpl.java:499)
at org.apache.openjpa.persistence.PersistenceProductDerivation.load(PersistenceProductDerivation.java:317)
at org.apache.openjpa.persistence.PersistenceProviderImpl.createContainerEntityManagerFactory(PersistenceProviderImpl.java:160)
at org.apache.openjpa.persistence.PersistenceProviderImpl.createContainerEntityManagerFactory(PersistenceProviderImpl.java:62)
I put the worklight jar directly in the WebSphere lib to solve another problem related to an Authentication class not being found if I recall correctly... Perhaps I need more jars in there, or did I solve my previous problem incorrectly? I put the javax.peristence.jar inside websphere as well, but that didn't help.
Are you using Ant scripts for deployment? This happens if you miss some steps while doing the manual application deployment.
I am migrating my application from EJB2.0 to EJB3.0 and at the same migrating server from WAS5.0 to WAS7.0, I did all the changes required to migrate the EJB and has no compile time errors however when I deploy my EAR into the server and hit the application it gives me an error -
NMSV0605W: A javax.naming.Reference object looked up from the context "ejblocal:" with the name "ejb/com/freight/xyz/UserLocalHome" was sent to the JNDI Naming Manager and an exception resulted. Reference data follows:
Reference Factory Class Name: com.ibm.ejs.container.util.EJBLocalInterfaceObjectFactory
Reference Factory Class Location URLs: <null>
Reference Class Name: com.freight.xyz.UserLocalHome
Type: EJBLocalInterfaceInfo
Content: com.ibm.ejs.container.util.EJBLocalInterfaceInfo#5bb95bb9
Exception data follows:
com.ibm.ejs.container.ContainerEJBException: Unable to initialize deferred EJB.; nested exception is: java.lang.NoClassDefFoundError: com.freight.ecw.dto.User
at com.ibm.ws.runtime.component.EJBContainerImpl.initializeDeferredEJB(EJBContainerImpl.java:4938)
Along with this in the logs I can also see-
Exception stack trace: com.ibm.websphere.naming.CannotInstantiateObjectException: Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object.
Does anyone has any idea how to resolve this?