While Running my apring mvc application I'm having this exception
I think there is issue with my applicationContext.xml file and I'm unable o figure it out.
I've not defined any schema versions in the applicationContext.xml . Is that an issue?
My spring-version -s 5.3.19
Wildlfy version is - 26.1.3
Java version - 17
Also, as of now javax.* package is also being used in my project and I've some issues in secutityConfig and Servlet-config.xml file and all of them are due to the schema location issues as I've not defined any version with .xsd .
Related
I am using
implementation (group: 'com.oracle.oci.sdk', name: 'oci-java-sdk-dataflow', version: '1.12.5') to use create an application in OCI dataflow. But it's not working and getting below error:
"Handler dispatch failed; nested exception is java.lang.NoSuchMethodError: com.oracle.bmc.ClientConfiguration.getRetryConfiguration()Lcom/oracle/bmc/retrier/RetryConfiguration;",
"com.oracle.bmc.ClientConfiguration.getRetryConfiguration()Lcom/oracle/bmc/retrier/RetryConfiguration;",
"[org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:1053), org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:942), org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:1005), org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:908),
I can see 3 jars related to OCI in \WEB-INF\lib path
run mvn dependency:tree -Dverbose and see what version you have
Make sure the versions are all consistent. In this case, I suspect that oci-java-sdk-dataflow is using an older version of oci-java-sdk-common than it expects.
If older version of oci-java-sdk-common is getting added in the class path from a dependent module exclude it to get this issue resolved.
duplicate jar would be my next guess
I try to start the Enterprise Application in WebSphere Application Server version 9.0.0.10 and there is missing class com.ibm.ws.webbeans.services.JCDIWebListener.
Fix pack for version 9.0.0.10 didn't help for this. There still are warning that prevents application starting in SystemLog.log file:
000000a7 annotation W com.ibm.ws.webcontainer.annotation.WASAnnotationHelper collectClasses SRVE8000W: Skipped class that failed to initialize for annotation scanning.
java.lang.ClassNotFoundException: com.ibm.ws.webbeans.services.JCDIWebListener
Where to get that class if latest fix pack won't bring that?
Or is there other libraries where to get that class? I'm running on Java version = 1.8.0_191, Java Runtime Version = 8.0.5.26
I was using primefaces 3.5 in my project and now have updated to 4.0 but its failing to deploy on Glassfish after upgrading and resulting in the following error:
Severe: Critical error during deployment:
com.sun.faces.config.ConfigurationException: java.lang.Exception:
No Function Found on type: org.primefaces.util.ComponentUtils with
signature: java.lang.String resolveWidgetVar(java.lang.String)
I have removed the 3.5 version JAR and placed the new one in the project library, but still failing to deploy with the mentioned error given.
I'm using:
Glassfish: 4.1,
Netbeans 8.0.1
You should clear glassfish cache because old primefaces library which referred in the class path of your app server.
Stop the glassfish server.
Delete the content of the osgi-cache, by removing the felix directory in your domain. This is usually found in glassfish4/glassfish/domains/domain1/osgi-cache
What could be the cause for this error while running my Java EE 6 app from embedded container using Eclipse?
HTTP Status 500 -
type Exception report
message
description: The server encountered an internal error () that prevented it from fulfilling this request.
exception
javax.servlet.ServletException: PWC1391: Servlet.init() for servlet <project>.webservice.ApplicationConfig threw exception
root cause
com.sun.jersey.spi.inject.Errors$ErrorMessagesException
note The full stack traces of the exception and its root causes are available in the GlassFish Server Open Source Edition 3.1.2.2 logs.
Edit: Basically since I ran it successfully, I upgraded eclipse and made some changes in project (refactor/renaming variables) and svn repository setup.
Have you tried the suggestions Google produces when you search for PWC1391? Namely resolving potential version conflicts with the Jersey library (i.e. removing it from project).
Finally figured out that there were some libraries missing...including Glassfish 3.1.2 being the major one from "Web"'s "Java Build Path > Libraries".
I want to not use the built in Websphere 7 jpa plugin, instead use an application WEB-INF/lib/open-jpa 2 and a proprietary persistence provider. I cannot install the OSGI and JPA 2 feature pack for Websphere.
Originally, I was getting a sax parse error simply trying to load the persistence.xml (version="2" not supported). The error was thrown by a class in open-jpa 1.2.3. When I run websphere/appserver/bin/wsjpaversion.bat, the open-jpa 1.2.3 jar is displayed. By default it overrides the open-jpa 2 jar in the app. I created a shared library containing the open-jpa 2 jar with this config option checked: 'Use an isolated class loader for this shared library'. I set my application classloader to load parent last and assigned it the new shared library resource. The 'version 2' error is gone, but there is another problem. When I try to initialize an EntityManager I get an error:
Caused by: javax.persistence.PersistenceException: Failed to load provider from META-INF/services
at javax.persistence.spi.PersistenceProviderResolverHolder$DefaultPersistenceProviderResolver.getPersistenceProviders(PersistenceProviderResolverHolder.java:121)
at javax.persistence.Persistence.createEntityManagerFactory(Persistence.java:91)
at java.lang.J9VMInternals.initializeImpl(Native Method)
at java.lang.J9VMInternals.initialize(J9VMInternals.java:200)
... 2 more
Caused by: java.lang.ClassCastException: com.ibm.websphere.persistence.PersistenceProviderImpl incompatible with javax.persistence.spi.PersistenceProvider
at javax.persistence.spi.PersistenceProviderResolverHolder$DefaultPersistenceProviderResolver.getPersistenceProviders(PersistenceProviderResolverHolder.java:110)
... 11 more
One more detail: inside the persistence.xml, the provider element is set to the proprietary PersistenceProviderImpl not the default Websphere persistence provider. So where is this websphere default coming from and how do I prevent it? (another important note: when I remove persistence.xml completely, I get the same error)
Thank you
Without installing the feature pack, you're fighting a losing battle. While it is possible to plug in your own JPA implementation, it is not possible to do that with JPA API — so WAS 7 ties you to the 1.0 version of JPA (see, for example, here how this is done — no class loader policy juggling will change that, though it seems tempting at first).