I'm using SBT 0.13.2-M3 for Lift 2.6-M2 development. I'm also using sbt-escalante 0.2.0 which allows me to start a different application server than Jetty. Now I tried to integrate JRebel 5.2.2 to avoid application restarts. When I run escalante-run I get a lot of JRebel exceptions and the JBoss application server starts but there's no class reloading.
There are so many exceptions that I just list two of them and hope someone has a clue how to fix it.
JRebel: Class 'org.jboss.as.server.deployment.reflect.DeploymentReflectionIndex' could not be processed by org.zeroturnaround.javarebel.jboss7.cbp.DeploymentReflectionIndexCBP#sbt.PluginManagement$PluginClassLoader#411f8c70
2014-03-27 23:02:40 JRebel: ERROR org.zeroturnaround.bundled.javassist.NotFoundException: org.zeroturnaround.javarebel.jboss7.JrDeploymentReflectionIndex
at org.zeroturnaround.bundled.javassist.ClassPool.get(JRebel:450)
at org.zeroturnaround.javarebel.jboss7.cbp.DeploymentReflectionIndexCBP.process(DeploymentReflectionIndexCBP.java:22)
at org.zeroturnaround.javarebel.integration.support.JavassistClassBytecodeProcessor.process(JRebel:70)
at com.zeroturnaround.javarebel.xB.a(JRebel:257)
at com.zeroturnaround.javarebel.xB.a(JRebel:246)
at com.zeroturnaround.javarebel.xB.a(JRebel:224)
at com.zeroturnaround.javarebel.SDKIntegrationImpl.runBytecodeProcessors(JRebel:128)
at com.zeroturnaround.javarebel.xl.transform(JRebel:45)
at java.lang.ClassLoader.defineClass(ClassLoader.java)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at org.jboss.modules.ModuleClassLoader.doDefineOrLoadClass(ModuleClassLoader.java:327)
JRebel: Class 'org.jboss.as.web.deployment.component.WebComponentInstantiator$1' could not be processed by org.zeroturnaround.javarebel.jboss7.as.cbp.web.WebComponentInstantiator$1CBP#sbt.PluginManagement$PluginClassLoader#411f8c70
2014-03-27 23:02:48 JRebel: ERROR org.zeroturnaround.bundled.javassist.NotFoundException: org.zeroturnaround.javarebel.jboss7.as.contracts.JrServletReinjector
at org.zeroturnaround.bundled.javassist.ClassPool.get(JRebel:450)
at org.zeroturnaround.javarebel.jboss7.as.cbp.web.WebComponentInstantiator$1CBP.process(WebComponentInstantiator$1CBP.java:31)
at org.zeroturnaround.javarebel.integration.support.JavassistClassBytecodeProcessor.process(JRebel:70)
at com.zeroturnaround.javarebel.xB.a(JRebel:257)
at com.zeroturnaround.javarebel.xB.a(JRebel:246)
at com.zeroturnaround.javarebel.xB.a(JRebel:224)
at com.zeroturnaround.javarebel.SDKIntegrationImpl.runBytecodeProcessors(JRebel:128)
at com.zeroturnaround.javarebel.xl.transform(JRebel:45)
Related
Okay so I am using Windows 10, I am having issues starting up intelliJ IDEA as every time I run it, it throws the following error and crashes,
Internal error. Please refer to
https://jb.gg/ide/critical-startup-errors
com.intellij.ide.plugins.StartupAbortedException: Cannot start app
at com.intellij.idea.StartupUtil.lambda$start$15(StartupUtil.java:265)
at java.base/java.util.concurrent.CompletableFuture.uniExceptionally(CompletableFuture.java:990)
at java.base/java.util.concurrent.CompletableFuture$UniExceptionally.tryFire(CompletableFuture.java:974)
at java.base/java.util.concurrent.CompletableFuture.postComplete(CompletableFuture.java:510)
at java.base/java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1773)
at java.base/java.util.concurrent.CompletableFuture$AsyncSupply.exec(CompletableFuture.java:1760)
at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:373)
at java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1182)
at java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1655)
at java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1622)
at java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:165)
Caused by: java.lang.NoClassDefFoundError: Could not initialize class
com.sun.jna.Native
at com.sun.jna.platform.win32.WinReg$HKEYByReference.(WinReg.java:52)
at com.sun.jna.platform.win32.WinReg$HKEYByReference.(WinReg.java:48)
at com.sun.jna.platform.win32.Advapi32Util.registryGetStringValue(Advapi32Util.java:736)
at com.sun.jna.platform.win32.Advapi32Util.registryGetStringValue(Advapi32Util.java:717)
at com.intellij.openapi.util.WinBuildVersionKt.getWinBuildNumberInternal(WinBuildVersion.kt:14)
at com.intellij.openapi.util.WinBuildVersionKt.access$getWinBuildNumberInternal(WinBuildVersion.kt:1)
at com.intellij.openapi.util.WinBuildVersionKt$getWinBuildNumber$1.invoke(WinBuildVersion.kt:33)
at com.intellij.openapi.util.WinBuildVersionKt$getWinBuildNumber$1.invoke(WinBuildVersion.kt)
at kotlin.SynchronizedLazyImpl.getValue(LazyJVM.kt:74)
at com.intellij.openapi.util.WinBuildVersionKt.getWinBuildNumber(WinBuildVersion.kt:33)
at com.intellij.openapi.util.SystemInfo.getWinBuildNumber(SystemInfo.java:123)
at com.intellij.openapi.wm.impl.customFrameDecorations.header.CustomHeader$CustomFrameTopBorder.calculateAffectsBorders(CustomHeader.kt:276)
at com.intellij.openapi.wm.impl.customFrameDecorations.header.CustomHeader$CustomFrameTopBorder.addNotify(CustomHeader.kt:346)
at com.intellij.openapi.wm.impl.customFrameDecorations.header.CustomHeader.addNotify(CustomHeader.kt:158)
at com.intellij.openapi.wm.impl.customFrameDecorations.header.DialogHeader.addNotify(DialogHeader.kt:59)
at java.desktop/java.awt.Container.addNotify(Container.java:2804)
at java.desktop/javax.swing.JComponent.addNotify(JComponent.java:4847)
at java.desktop/java.awt.Container.addNotify(Container.java:2804)
at java.desktop/javax.swing.JComponent.addNotify(JComponent.java:4847)
at java.desktop/java.awt.Container.addNotify(Container.java:2804)
at java.desktop/javax.swing.JComponent.addNotify(JComponent.java:4847)
at java.desktop/javax.swing.JRootPane.addNotify(JRootPane.java:729)
at java.desktop/java.awt.Container.addNotify(Container.java:2804)
at java.desktop/java.awt.Window.addNotify(Window.java:797)
at java.desktop/java.awt.Dialog.addNotify(Dialog.java:770)
at com.intellij.openapi.ui.impl.DialogWrapperPeerImpl$MyDialog.addNotify(DialogWrapperPeerImpl.java:641)
at java.desktop/java.awt.Window.pack(Window.java:835)
at com.intellij.openapi.ui.impl.DialogWrapperPeerImpl.pack(DialogWrapperPeerImpl.java:311)
at com.intellij.openapi.ui.DialogWrapper.pack(DialogWrapper.java:1432)
at com.intellij.ide.gdpr.AgreementUi.pack(AgreementUi.kt:254)
at com.intellij.ide.gdpr.Agreements.showEndUserAndDataSharingAgreements(Agreements.kt:19)
at com.intellij.idea.StartupUtil.lambda$showEuaIfNeeded$25(StartupUtil.java:607)
at java.base/java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1768)
at java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:318)
at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:779)
at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:730)
at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:724)
at java.base/java.security.AccessController.doPrivileged(AccessController.java:399)
at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:86)
at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:749)
at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:393)
at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:207)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:128)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:117)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:113)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:105)
at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:92)
----- Your JRE: 17.0.3+7-b469.32 amd64 (JetBrains s.r.o.) C:\Program Files\Jetbrains\IntelliJ IDEA\jbr
Has anyone encountered something like this? I've never seen this issue before so completely clueless, any help would be greatly appreciated.
Thanks a lot
When running the IntelliJ IDEA, a dll
C:\Users<user_name>\AppData\Local\JetBrains\IntelliJIdea2022.2\tmp\jnaxxxx.dll is extracted in IDEA's temp dir and executed.
In Windows, some security tools can restrict the folders where binaries (e.g. dll, ...) can be executed.
If you have security tools installed, ensure that all IDE, project, and IDE installation directories are added to the exclusions list.
We have taken over several Java 6 webservices using Tomcat 6, in production at a customer site, which we’re attempting to upgrade to Java 11 and Tomcat 10
This software currently includes a custom XxxxxxWebActionServlet class, which extends from an old version of org.apache.struts.action.ActionServlet – this old version of struts ActionServlet currently used in production, and our current production XxxxxxWebActionServlet, both import javax.servlet.* classes
For Java 11 we have upgraded our XxxxxxWebActionServlet to import jakarta.servlet.* classes
Our upgrade results in the run-time ClassCastException shown below (from Tomcat 10’s localhost.yyyy-mm-dd.log)
Our guess is that this ClassCastException occurs because our upgraded XxxxxxWebActionServlet, which now imports jakarta.servlet., continues to extend the same older version of struts ActionServlet which imports javax.servlet. classes
After much web searching, we can’t seem to find a version of org.apache.struts.action.ActionServlet which imports jakarta.servlet.*
The last version of org.apache.struts.action.ActionServlet that we can find (in https://archive.apache.org/dist/struts/1.3.10) imports javax.servlet.* - ActionFormValidationInterceptor.java in struts-2.3.20.1 imports (but does not seem to use) org.apache.struts.action.ActionServlet, but ActionServlet.java itself does not seem to be present within struts-2.3.20.1/src
#1) Would a version of org.apache.struts.action.ActionServlet which imports jakarta.servlet.* exist somewhere else ?
#2) If not, we’d be very appreciative of any suggestions for how to circumvent this ClassCastException
Thanks very much in advance
22-Jun-2022 11:29:26.084 INFO [main]
org.apache.catalina.core.ApplicationContext.log Marking servlet
[action] as unavailable 22-Jun-2022 11:29:26.084 SEVERE [main]
org.apache.catalina.core.StandardContext.loadOnStartup Servlet
[action] in web application [/xxware] threw load() exception
java.lang.ClassCastException: class
com.xxxxxx.ui.web.jspframework.XxxxxxWebActionServlet cannot be cast
to class jakarta.servlet.Servlet
(com.xxxxxx.ui.web.jspframework.XxxxxxWebActionServlet is in unnamed
module of loader org.apache.catalina.loader.ParallelWebappClassLoader
#3ce3b176; jakarta.servlet.Servlet is in unnamed module of loader
java.net.URLClassLoader #6ddf90b0) at
org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1071)
at
org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:1011)
at
org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:4906)
at
org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5213)
at
org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:726)
at
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:698)
at
org.apache.catalina.core.StandardHost.addChild(StandardHost.java:747)
at
org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:1027)
at
org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:2001)
at
java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
at
java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at
org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecutorService.java:75)
at
java.base/java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:118)
at
org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:828)
at
org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:478)
at
org.apache.catalina.startup.HostConfig.start(HostConfig.java:1708)
at
org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:320)
at
org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:123)
at
org.apache.catalina.util.LifecycleBase.setStateInternal(LifecycleBase.java:423)
at
org.apache.catalina.util.LifecycleBase.setState(LifecycleBase.java:366)
at
org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:946)
at
org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:886)
at
org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
at
org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1396)
at
org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1386)
at
java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at
org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecutorService.java:75)
at
java.base/java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:140)
at
org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:919)
at
org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:263)
at
org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
at
org.apache.catalina.core.StandardService.startInternal(StandardService.java:432)
at
org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
at
org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:927)
at
org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
at org.apache.catalina.startup.Catalina.start(Catalina.java:795)
at
java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native
Method) at
java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at
java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566) at
org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:345) at
org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:476)
If you're still on struts 1.x, split your upgrade into multiple steps:
Upgrade to a currently supported version of Tomcat
Upgrade your Struts code to a currently supported version (or framework)
There's no need to go to Tomcat 10 and the jakarta.servlet-world. Simply upgrade to Tomcat 9. Struts 1.x is from a time that jakarta.servlet was unheard of. So you won't find them together.
When you get your current code running on Tomcat 9, examine Struts' applicability and supported versions - consider upgrading (or consider picking a different framework). You can go live with your updated version long before that (e.g. just when everything works on Tomcat 9)
I'm currently working to upgrade struts1 (currently JakartaEE 8) and I think I'll reach JakartaEE 9-compatility next week (till 25. Nov. 2022).
In meantime take a look at my struts1-github-project to follow the progress: Weblegacy/Struts1
Greetings
Stefan
As of today, when I try to run some of my programs in IntelliJ today, this message was shown:
Executing pre-compile tasks...
Loading Ant configuration...
Running Ant tasks...
Running 'before' tasks
Checking sources
Finished, saving caches…
Module 'Listen' production: java.lang.NoClassDefFoundError: com/intellij/DynamicBundle
Executing post-compile tasks...
Loading Ant configuration...
Running Ant tasks...
Synchronizing output directories...
13.04.22, 14:54 - Build completed with 1 error and 0 warnings in 4 sec, 39 ms
This line is printed in red: Module 'Listen' production: java.lang.NoClassDefFoundError: com/intellij/DynamicBundle
I don't really have too much of an idea where I should look for the problem.
It seems to not have anything to do with the project itself. I already created a new Project and created a Hello World-program, which resulted in the same error.
Remarkably, yesterday my IntelliJ IDEA version was updated to version 2022.1.
Runtime version: 11.0.14.1+1-b2043.25 amd64
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o.
I have no idea either whether it has anything to do with the new version either.
I maintain another Project, which uses Scala language. That one is messed up even more:
Cannot process toolwindow sbt
java.lang.AbstractMethodError: Missing implementation of resolved method 'abstract com.intellij.openapi.externalSystem.settings.AbstractExternalSystemSettings getSettings(com.intellij.openapi.project.Project)' of abstract class com.intellij.openapi.externalSystem.service.task.ui.AbstractExternalSystemToolWindowFactory.
at com.intellij.openapi.externalSystem.service.task.ui.AbstractExternalSystemToolWindowFactory.shouldBeAvailable(AbstractExternalSystemToolWindowFactory.java:35)
at com.intellij.toolWindow.ToolWindowSetInitializerKt.beanToTask(ToolWindowSetInitializer.kt:262)
at com.intellij.toolWindow.ToolWindowSetInitializerKt.beanToTask(ToolWindowSetInitializer.kt:248)
at com.intellij.toolWindow.ToolWindowSetInitializerKt.access$beanToTask(ToolWindowSetInitializer.kt:1)
at com.intellij.toolWindow.ToolWindowSetInitializerKt$computeToolWindowBeans$1.accept(ToolWindowSetInitializer.kt:278)
at com.intellij.toolWindow.ToolWindowSetInitializerKt$computeToolWindowBeans$1.accept(ToolWindowSetInitializer.kt)
at com.intellij.openapi.extensions.impl.ExtensionPointImpl.processWithPluginDescriptor(ExtensionPointImpl.java:301)
at com.intellij.toolWindow.ToolWindowSetInitializerKt.computeToolWindowBeans(ToolWindowSetInitializer.kt:274)
at com.intellij.toolWindow.ToolWindowSetInitializer$1.get(ToolWindowSetInitializer.kt:101)
at com.intellij.toolWindow.ToolWindowSetInitializer$1.get(ToolWindowSetInitializer.kt:83)
at java.base/java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1700)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:668)
at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:665)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1.run(Executors.java:665)
at java.base/java.lang.Thread.run(Thread.java:829)
Any advice?
Best
Stapelüberläufer
I had the same problem after upgrading to Intellij 2022.1
For me, the fix came from Gen's answer. I also had an old Scala plugin, and just removed it as I'm not using it anymore.
If you are looking to upgrade it, go to File -> Settings -> Plugins. From there just hit Upgrade for the plugins you want. After that restart the IDE.
I found that Scala plugin was not updated and updating it to at least version 2022.1.13 fixed it for me.
I upgraded to Intellij 2022.1 and encountered this issue when trying to sync the old gradles projects that used to work for me :
Caused by: java.lang.NoClassDefFoundError: org/gradle/internal/impldep/com/google/common/collect/Lists
Cleaning the caches folder's content (Gradle_HOME/caches) resolved this issue for me
Make sure to also check that the SDK is correctly configured for your project (Java 17 by default) and the Gradle home is well specified in the Settings>Gradle section.
For info, I'm using Java 8 and Gradle 5.5.1 (yes I know :))
Just upgrade the Scala Plugin and its done!
visiting
scala plugin's page
and install it from there worked for me on ultimate version 2022.2.3
I have used seedstack dependecies for Hibernate and JPA to create DAO services that performs crud operations on Database.
I am trying to Launch this Seedstack application module through Java application Launcher in eclipse, by SeedMain class.
In pom.xml - dependecy for undertow is given.
<dependency>
<groupId>org.seedstack.seed</groupId>
<artifactId>seed-web-undertow</artifactId>
</dependency>
When executing the SeedMain class, I am getting the below error snakeyaml error:-
Exception in thread "main" java.lang.NoSuchMethodError: org.yaml.snakeyaml.DumperOptions.setSplitLines(Z)V
at com.fasterxml.jackson.dataformat.yaml.YAMLGenerator.buildDumperOptions(YAMLGenerator.java:259)
at com.fasterxml.jackson.dataformat.yaml.YAMLGenerator.<init>(YAMLGenerator.java:232)
at com.fasterxml.jackson.dataformat.yaml.YAMLFactory._createGenerator(YAMLFactory.java:447)
at com.fasterxml.jackson.dataformat.yaml.YAMLFactory.createGenerator(YAMLFactory.java:397)
at org.seedstack.seed.core.internal.diagnostic.DefaultDiagnosticReporter.writeDiagnosticReport(DefaultDiagnosticReporter.java:75)
at org.seedstack.seed.core.internal.diagnostic.DefaultDiagnosticReporter.writeDiagnosticReport(DefaultDiagnosticReporter.java:67)
at org.seedstack.seed.core.internal.diagnostic.DiagnosticManagerImpl.dumpDiagnosticReport(DiagnosticManagerImpl.java:70)
at org.seedstack.seed.core.SeedMain.handleException(SeedMain.java:68)
at org.seedstack.seed.core.SeedMain.main(SeedMain.java:61)
As per my understanding the Error is due to some version inconsistency for snakeyaml, But for Seedstack as the versions for dependecies are resolved by seedstack-bom dependecy, so where exactly should I do the changes to resolve the error.
Thanks in Advance!
From reading the stacktrace, it seems that you have some error on startup which is handled by the handleException() method. This method then tries to write a YAML diagnostic report but ultimately fails due to the snakeyaml version issue you mentioned.
You should do two things:
Fix the snakeyaml dependency issue by looking into the dependency tree. This kind of problem is often caused by some library that makes Maven choose an older version. SeedStack needs at least jackson-dataformat-yaml version 2.9.4 which in turn needs at least snakeyaml 1.18.
Fix the other error by looking at the full stacktrace. When a diagnostic report cannot be written, the original exception is still printed on the console (on stderr).
We are trying to make a webservice call using CXF framework involving CXF - ws security and the application being deployed in weblogic 10.3 , but receiving the below exception and seems like the weblogic specific jars are picked up , though the xercesimpl jar is present in the application in /WEB-INF/lib .
Options tried , but did not help:
Setting the weblogic container descriptor with
web-inf preferences
true .
Setting the JVM arguments or system property as -
-Djavax.xml.soap.MessageFactory=com.sun.xml.internal.messaging.saaj.soap.ver1_1.SOAPMessageFactory1_1Impl
-Djavax.xml.soap.SOAPFactory=com.sun.xml.internal.messaging.saaj.soap.ver1_1.SOAPFactory1_1Impl
-Djavax.xml.soap.SOAPConnectionFactory=weblogic.wsee.saaj.SOAPConnectionFactoryImpl
Adding xercesimpl jar to maven pom.
Exception
]] Root cause of ServletException.
java.lang.AssertionError: UNIMPLEMENTED
at weblogic.xml.domimpl.NodeImpl.setTextContent(NodeImpl.java:216)
at org.apache.jcp.xml.dsig.internal.dom.XmlWriterToTree.writeAttribute(XmlWriterToTree.java:137)
at org.apache.jcp.xml.dsig.internal.dom.XmlWriterToTree.writeNamespace(XmlWriterToTree.java:114)
at org.apache.jcp.xml.dsig.internal.dom.DOMXMLSignature.marshal(DOMXMLSignature.java:211)
at org.apache.jcp.xml.dsig.internal.dom.DOMXMLSignature.sign(DOMXMLSignature.java:329)
at org.apache.wss4j.dom.message.WSSecSignature.computeSignature(WSSecSignature.java:578)
at org.apache.wss4j.dom.action.SignatureAction.execute(SignatureAction.java:151)
at org.apache.wss4j.dom.handler.WSHandler.doSenderAction(WSHandler.java:226)
at org.apache.cxf.ws.security.wss4j.WSS4JOutInterceptor.access$100(WSS4JOutInterceptor.java:54)
at org.apache.cxf.ws.security.wss4j.WSS4JOutInterceptor$WSS4JOutInterceptorInternal.handleMessageInternal(WSS4JOutInterceptor.java:282)
at org.apache.cxf.ws.security.wss4j.WSS4JOutInterceptor$WSS4JOutInterceptorInternal.handleMessage(WSS4JOutInterceptor.java:154)
at org.apache.cxf.ws.security.wss4j.WSS4JOutInterceptor$WSS4JOutInterceptorInternal.handleMessage(WSS4JOutInterceptor.java:141)
at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:307)enter code here
at org.apache.cxf.endpoint.ClientImpl.doInvoke(ClientImpl.java:514)
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:423)
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:326)
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:279)
at org.apache.cxf.frontend.ClientProxy.invokeSync(ClientProxy.java:98)
at org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:138)
Thanks,
Soumya
I finally found the answer without modifying any weblogic startup script (tested on CXF 2.7.0 and weblogic 10.3.6
The reason for this issue is that CXF is not compatible with weblogic implementation of SAAJ. http://cxf.apache.org/docs/application-server-specific-configuration-guide.html
1.
Q: I have this error: javax.xml.ws.WebServiceException: Cannot create SAAJ factory instance.
A: Please make sure you have the saaj-impl-1.3.jar in the classpath and make sure your app picks up this one instead of weblogic one.
The same issue is also causing the UNIMPLEMENTED error in the question
So my solution is
1) put saaj-impl in classpath. If you are using maven, put the dependency on pom.xml
2) in weblogic.xml (in your resources folder) put
<wls:container-descriptor>
<wls:prefer-application-packages>
<wls:package-name>com.sun.xml.messaging.saaj.*</wls:package-name>
</wls:prefer-application-packages>
</wls:container-descriptor>
3) Restart your server through Node Manager and by right the CXF WS-Security should be working
Hope it helps!