Test case:
1.Open valid application url, for example
http://127.0.0.1:8888/rest/hosted/index?gwt.codesvr=127.0.0.1:9997#xxx:yyy
2.Change url to have some UTF-8 encoded characters, for example,
http://127.0.0.1:8888/rest/hosted/index?gwt.codesvr=127.0.0.1:9997#xxx:%u0041
As you see, it contains invalid character %u0041.
After that, GWT is throwing infinite exceptions with stacktrace
com.google.gwt.core.client.JavaScriptException: (URIError) #com.google.gwt.core.client.impl.Impl::apply(Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;)([JavaScript object(10822), JavaScript object(10823), JavaScript object(11420)]): The URI to be decoded is not a valid encoding
at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:249)
at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:136)
at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:576)
at com.google.gwt.dev.shell.ModuleSpace.invokeNativeObject(ModuleSpace.java:284)
at com.google.gwt.dev.shell.JavaScriptHost.invokeNativeObject(JavaScriptHost.java:91)
at com.google.gwt.core.client.impl.Impl.apply(Impl.java)
at com.google.gwt.core.client.impl.Impl.entry0(Impl.java:356)
at sun.reflect.GeneratedMethodAccessor299.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:103)
at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:71)
at com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java:172)
at com.google.gwt.dev.shell.BrowserChannelServer.reactToMessages(BrowserChannelServer.java:293)
at com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java:547)
at com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:364)
at java.lang.Thread.run(Thread.java:662)
Why it throws repeated exceptions and how can I avoid it?
EDIT
Unfortunately I cannot show code since it seems to me that it is GWT's internal stuff. I don't code it, when I change URL in URL bar and press enter, GWT reacts all by itself. It is not feasible option, but it fails penetration tests.
EDIT 2
It appears it happens only in IE 11
GWT version - 2.6.1
Related
I am getting a NullPointerException as shown below.
However, the debugger is not able to bring it up when enabled in this method, the code is getting invoked with reflections. Can you please provide me ideas\techniques to be able to debug this code?
[10/18/16 18:20:47:933 EST] 00000051 DWLExceptionU E java.lang.NullPointerException
at com.dwl.base.notification.NotificationManager$NotificationChannel.notify(NotificationManager.java:662)
at com.dwl.base.notification.NotificationManager$NotificationType.notify(NotificationManager.java:402)
at com.dwl.base.notification.NotificationManager.notify(NotificationManager.java:1454)
at com.dwl.base.notification.bean.impl.NotificationBean.notify(NotificationBean.java:142)
at com.dwl.base.notification.EJSLocalCSLNotification_e2801c59.notify(EJSLocalCSLNotification_e2801c59.java)
at com.dwl.base.notification.EJSProxy$$NotificationLocal.notify(Unknown Source)
at au.com.xxxxx.mdm.notification.NotificationHelper.sendNotification(NotificationHelper.java:75)
at au.com.xxxxxx.mdm.behaviour.SingleCustomerViewId.triggerNotification(SingleCustomerViewId.java:159)
at au.com.xxxxxxx.mdm.behaviour.SingleCustomerViewId.execute(SingleCustomerViewId.java:129)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:88)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:55)
at java.lang.reflect.Method.invoke(Method.java:613)
at com.dwl.base.extensionFramework.JavaExtensionSet.invoke(JavaExtensionSet.java:159)
at com.dwl.base.extensionFramework.ExtensionHandler.executeExtension(ExtensionHandler.java:251)
at com.dwl.base.DWLCommonComponent.handleExtensions(DWLCommonComponent.java:1380)
at com.dwl.base.DWLCommonComponent.postExecute(DWLCommonComponent.java:509)
at com.dwl.tcrm.common.TCRMCommonComponent.postExecute(TCRMCommonComponent.java:263)
at com.dwl.tcrm.coreParty.component.TCRMPersonComponent.addPerson(TCRMPersonComponent.java:1641)
at com.dwl.tcrm.coreParty.component.TCRMPartyComponent.addPerson(TCRMPartyComponent.java:3079)
at com.dwl.tcrm.coreParty.component.TCRMPartyComponent.addPartySimple(TCRMPartyComponent.java:2813)
at com.dwl.tcrm.coreParty.component.TCRMPartyComponent.addParty(TCRMPartyComponent.java:2471)
at com.dwl.tcrm.coreParty.controller.TCRMCorePartyTxnBean.addPerson(TCRMCorePartyTxnBean.java:1764)
at Proxy5aa32899_c04f_46c5_9706_69af241cd3c4.addPerson(Unknown Source)
at Proxy5aa32899_c04f_46c5_9706_69af241cd3c4.addPerson(Unknown Source)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:88)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:55)
at java.lang.reflect.Method.invoke(Method.java:613)
at com.dwl.base.requestHandler.DWLTxnBP.processPersistentObject(DWLTxnBP.java:262)
at com.dwl.base.requestHandler.DWLTxnBP.execute(DWLTxnBP.java:115)
at com.dwl.base.requestHandler.DWLTxnProcessor.processTx(DWLTxnProcessor.java:98)
at com.dwl.unifi.tx.manager.CTxRxFacade.processTxNormal(CTxRxFacade.java:681)
at com.dwl.unifi.tx.manager.CTxRxFacade.processTx(CTxRxFacade.java:544)
at com.dwl.base.requestHandler.DWLRequestHandler.processTransaction(DWLRequestHandler.java:1187)
at com.dwl.base.requestHandler.DWLRequestHandler.processTx(DWLRequestHandler.java:591)
at com.dwl.base.requestHandler.DWLServiceControllerBase.processRequest(DWLServiceControllerBase.java:253)
at com.dwl.base.requestHandler.beans.EJSRemoteCSLDWLServiceController_2c54996d.processRequest(EJSRemoteCSLDWLServiceController_2c54996d.java)
at com.dwl.base.requestHandler.beans._EJSRemoteCSLDWLServiceController_2c54996d_Tie.processRequest(_EJSRemoteCSLDWLServiceController_2c54996d_Tie.java:1)
at com.dwl.base.requestHandler.beans._EJSRemoteCSLDWLServiceController_2c54996d_Tie._invoke(_EJSRemoteCSLDWLServiceController_2c54996d_Tie.java)
at com.ibm.CORBA.iiop.ServerDelegate.dispatchInvokeHandler(ServerDelegate.java:669)
at com.ibm.CORBA.iiop.ServerDelegate.dispatch(ServerDelegate.java:523)
at com.ibm.rmi.iiop.ORB.process(ORB.java:523)
at com.ibm.CORBA.iiop.ORB.process(ORB.java:1575)
at com.ibm.rmi.iiop.Connection.doRequestWork(Connection.java:3039)
at com.ibm.rmi.iiop.Connection.doWork(Connection.java:2922)
at com.ibm.rmi.iiop.WorkUnitImpl.doWork(WorkUnitImpl.java:64)
at com.ibm.ejs.oa.pool.PooledThread.run(ThreadPool.java:118)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1892)
Can you please provide me ideas\techniques to be able to debug this code?
Since you said the method is called from reflection, you can see that in the stacktrace.
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:88)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:55)
at java.lang.reflect.Method.invoke(Method.java:613)
So, keep reading up from that.
I'm guessing you intentionally edited the xxxx values, so these are your libraries that are being dynamically called.
at au.com.xxxxx.mdm.notification.NotificationHelper.sendNotification(NotificationHelper.java:75)
at au.com.xxxxxx.mdm.behaviour.SingleCustomerViewId.triggerNotification(SingleCustomerViewId.java:159)
at au.com.xxxxxxx.mdm.behaviour.SingleCustomerViewId.execute(SingleCustomerViewId.java:129)
Then, the rest of the call stack just goes through some other code library within the same package.
at com.dwl.base.notification.NotificationManager$NotificationChannel.notify(NotificationManager.java:662)
at com.dwl.base.notification.NotificationManager$NotificationType.notify(NotificationManager.java:402)
at com.dwl.base.notification.NotificationManager.notify(NotificationManager.java:1454)
at com.dwl.base.notification.bean.impl.NotificationBean.notify(NotificationBean.java:142)
at com.dwl.base.notification.EJSLocalCSLNotification_e2801c59.notify(EJSLocalCSLNotification_e2801c59.java)
at com.dwl.base.notification.EJSProxy$$NotificationLocal.notify(Unknown Source)
So, the problem definitely starts at NotificationHelper.sendNotification(NotificationHelper.java:75), but it cannot easily be determined the path that the code took in order to reach its eventual destination or what exactly caused the exception without inspecting the source of (NotificationManager.java:662)
Closed. This question needs debugging details. It is not currently accepting answers.
Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question.
Closed 6 years ago.
Improve this question
I am getting this exception in my java program.Can anyone have idea on it?
MarshalException: Failed to communicate due to unread block data
java.rmi.MarshalException: Failed to communicate.
Problem during marshalling/unmarshalling; nested exception is:
java.lang.IllegalStateException: unread block data
com.naresh.product.common.exception.ApplicationException:
java.rmi.MarshalException: Failed to communicate.
Problem during marshalling/unmarshalling; nested exception is:
java.lang.IllegalStateException: unread block data
at com.naresh.product.client.library.util.ServerDelegate.search(Unknown Source)
at com.naresh.product.client.Product.workflow.form4.ProductForm4DashboardView.refreshDashboard(Unknown Source)
at com.naresh.product.client.Product.workflow.form4.ProductForm4DashboardView.access$3(Unknown Source)
at com.naresh.product.client.Product.workflow.form4.ProductForm4DashboardView$7.run(Unknown Source)
at org.eclipse.jface.operation.ModalContext.runInCurrentThread(ModalContext.java:464)
at org.eclipse.jface.operation.ModalContext.run(ModalContext.java:372)
at org.eclipse.jface.dialogs.ProgressMonitorDialog.run(ProgressMonitorDialog.java:507)
at com.naresh.product.client.Product.workflow.form4.ProductForm4DashboardView.refreshDashboard(Unknown Source)
at com.naresh.product.client.Product.workflow.form4.ProductForm4DashboardView$5.widgetSelected(Unknown Source)
at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:234)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1053)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:4066)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3657)
at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2640)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2604)
at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2438)
at org.eclipse.ui.internal.Workbench$7.run(Workbench.java:671)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:664)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
at com.naresh.product.client.app.Application.start(Unknown Source)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:369)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:620)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:575)
at org.eclipse.equinox.launcher.Main.run(Main.java:1408)
Caused by: java.rmi.MarshalException: Failed to communicate. Problem during marshalling/unmarshalling; nested exception is:
java.lang.IllegalStateException: unread block data
at org.jboss.remoting.transport.socket.SocketClientInvoker.handleException(SocketClientInvoker.java:122)
at org.jboss.remoting.transport.socket.MicroSocketClientInvoker.transport(MicroSocketClientInvoker.java:646)
at org.jboss.remoting.MicroRemoteClientInvoker.invoke(MicroRemoteClientInvoker.java:122)
at org.jboss.remoting.Client.invoke(Client.java:1634)
at org.jboss.remoting.Client.invoke(Client.java:548)
at org.jboss.invocation.unified.interfaces.UnifiedInvokerProxy.invoke(UnifiedInvokerProxy.java:183)
at org.jboss.invocation.InvokerInterceptor.invokeInvoker(InvokerInterceptor.java:365)
at org.jboss.invocation.InvokerInterceptor.invoke(InvokerInterceptor.java:197)
at org.jboss.proxy.TransactionInterceptor.invoke(TransactionInterceptor.java:61)
at org.jboss.proxy.SecurityInterceptor.invoke(SecurityInterceptor.java:70)
at org.jboss.proxy.ejb.StatelessSessionInterceptor.invoke(StatelessSessionInterceptor.java:112)
at org.jboss.proxy.ClientContainer.invoke(ClientContainer.java:100)
at $Proxy1.search(Unknown Source)
... 34 more
Caused by: java.lang.IllegalStateException: unread block data
at java.io.ObjectInputStream$BlockDataInputStream.setBlockDataMode(ObjectInputStream.java:2376)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1360)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1946)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1870)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1752)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1328)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java:350)
at org.jboss.remoting.serialization.impl.java.JavaSerializationManager.receiveObjectVersion2_2(JavaSerializationManager.java:239)
at org.jboss.remoting.serialization.impl.java.JavaSerializationManager.receiveObject(JavaSerializationManager.java:133)
at org.jboss.remoting.marshal.serializable.SerializableUnMarshaller.read(SerializableUnMarshaller.java:120)
at org.jboss.invocation.unified.marshall.InvocationUnMarshaller.read(InvocationUnMarshaller.java:59)
at org.jboss.remoting.transport.socket.MicroSocketClientInvoker.versionedRead(MicroSocketClientInvoker.java:957)
at org.jboss.remoting.transport.socket.MicroSocketClientInvoker.transport(MicroSocketClientInvoker.java:586)
... 45 more
Why this exception is comming. Do you guys have any idea to solve it?
From java.io.ObjectInputStream.BlockDataInputStream Javadoc :
boolean java.io.ObjectInputStream.BlockDataInputStream.setBlockDataMode(boolean newmode) throws IOException
Sets block data mode to the given mode (true == on, false == off) and
returns the previous mode value. If the new mode is the same as the
old mode, no action is taken. Throws IllegalStateException if block
data mode is being switched from on to off while unconsumed block data
is still present in the stream.
But in your stacktrace, the problem takes its origin from org.jboss.remoting.transport.socket.MicroSocketClientInvoker which processes deserialization on some objects.
So, you can imagine that it is hard to guess the cause of this error with just a stacktrace.
With a little luck, you could have a precise answer.
But if it is not the case, I propose you some tracks :
to update or downgrade the version of the jboss lib if possible. Maybe, it is a bug.
to run your server with breakpoints to discover the root of the problem.
to ask your question to JBoss support
I know this error has been posted before but I can't understand the stack trace and would love somebodies help.
Basically when I enter the application the getValue("client") is null:
HttpSession validuser = request.getSession();
if (validuser.getValue("client") == null) {
response.sendRedirect("/profile/factfind/includes/session_timeout.jsp");
}
And I'm thinking it's something to do with the following error:
2013-01-09 13:14:35 NamingContextListener[/Tomcat-Standalone/localhost/profile]: Creating JNDI naming context
2013-01-09 13:14:35 StandardManager[/profile]: Seeding random number generator class java.security.SecureRandom
2013-01-09 13:14:35 StandardManager[/profile]: Seeding of random number generator has been completed
2013-01-09 13:14:35 StandardContext[/profile]: Posting standard context attributes
2013-01-09 13:14:35 StandardContext[/profile]: Configuring application event listeners
2013-01-09 13:14:35 StandardContext[/profile]: Sending application start events
2013-01-09 13:14:35 StandardContext[/profile]: Starting filters
2013-01-09 13:14:35 StandardContext[/profile]: Starting completed
2013-01-09 13:14:37 StandardContext[/profile]: Servlet /profile threw load() exception
org.apache.jasper.JasperException: Unable to compile class for JSP
An error occurred at line: -1 in the jsp file: null
Generated servlet error:
[javac] Compiling 1 source file
at org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:85)
at org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:248)
at org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:343)
at org.apache.jasper.compiler.Compiler.compile(Compiler.java:356)
at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:427)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:142)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:240)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:187)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:720)
at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:888)
at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:768)
at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:3484)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:3710)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:777)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:760)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:538)
at org.apache.catalina.core.StandardHostDeployer.addChild(StandardHostDeployer.java:667)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.apache.commons.beanutils.MethodUtils.invokeMethod(MethodUtils.java:216)
at org.apache.commons.digester.SetNextRule.end(SetNextRule.java:217)
at org.apache.commons.digester.Rule.end(Rule.java:253)
at org.apache.commons.digester.Digester.endElement(Digester.java:1222)
at org.apache.xerces.parsers.AbstractSAXParser.endElement(Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanEndElement(Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.DTDConfiguration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
at org.apache.commons.digester.Digester.parse(Digester.java:1765)
at org.apache.catalina.core.StandardHostDeployer.install(StandardHostDeployer.java:343)
at org.apache.catalina.core.StandardHost.install(StandardHost.java:762)
at org.apache.catalina.startup.HostConfig.deployDescriptors(HostConfig.java:443)
at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:377)
at org.apache.catalina.startup.HostConfig.start(HostConfig.java:808)
at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:335)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:120)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1156)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:697)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1148)
at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:311)
at org.apache.catalina.core.StandardService.start(StandardService.java:450)
at org.apache.catalina.core.StandardServer.start(StandardServer.java:2213)
at org.apache.catalina.startup.Catalina.start(Catalina.java:484)
at org.apache.catalina.startup.Catalina.execute(Catalina.java:371)
at org.apache.catalina.startup.Catalina.process(Catalina.java:134)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:151)
The session exists in a different application that then loads "profile" so I'm not too sure what happens when one launches the other.
Any help would be much appreciated. Thanks.
Turns out the fix for me was the same as some forums had suggested. I create a new Tomcat installation in a directory with no spaces (i.e C:\Tomcat4.1) and that worked.
Don't know why or how but it did.
I think that's a problem
org.apache.jasper.JasperException: Unable to compile class for JSP
An error occurred at line: -1 in the jsp file: null
Cleanup your project (or manually remove all .class files) then try to compile from scratch. If error gone - check it should work. If not - you should apparently get this first error gone.
It seems getValue(String) method is deprecated. so try the following code null == validuser.getAttribute(String)
EDIT 2:
I probably should have mentioned this earlier, but I'm getting a warning after I set up the Web Service (but before it is actually made, where the error occurs). Here is the warning:
The service class
"net.rim.Indy.WebService.Functions_JSONP"
does not comply to one or more
requirements of the JAX-RPC 1.1
specification, and may not deploy or
function correctly.
And the juice:
The service class
"net.rim.Indy.WebService.Functions_JSONP"
does not comply to one or more
requirements of the JAX-RPC 1.1
specification, and may not deploy or
function correctly. The field or
property "cause" on the value type
"atg.taglib.json.util.JSONException"
used via the service class
"net.rim.Indy.WebService.Functions_JSONP"
has a data type,
"java.lang.Throwable", that is not
supported by the JAX-RPC 1.1
specification. Instances of the type
may not serialize or deserialize
correctly. Loss of data or complete
failure of the Web service may result.
If this is fixed, I have a feeling the Web Service will start working, because it is identical to another one I have except for the JSON functionality. Something needs to be changed so that my web service is fully supported by the JAX specs.
EDIT:
I'm now getting around the issue where it is automatically choosing the wrong project for me. I followed File->New->Web Service. My settings are as follows:
Web service type: Bottom up
Service implementation: net.aaa.bbb.WebService.Functions_JSONP
Server runtime: Tomcat v6
Web service runtime: Apache Axis
Service project: ABC
Client type: Java Proxy
I check off "Publish the Web service" and hit Next. Then on the next page I hit Next again to generate Functions_JSONP.wsdl and get the following error:
IWAB0398E Error in generating WSDL from Java: java.lang.ClassNotFoundException: net.aaa.bbb.WebService.Functions_JSONP
Here is the full stack trace:
IWAB0398E Error in generating WSDL from Java: java.lang.ClassNotFoundException: net.aaa.bbb.WebService.Functions_JSONP
java.lang.ClassNotFoundException: net.aaa.bbb.WebService.Functions_JSONP
at org.apache.axis.utils.ClassUtils.loadClass(ClassUtils.java:204)
at org.apache.axis.utils.ClassUtils.forName(ClassUtils.java:100)
at org.apache.axis.wsdl.fromJava.Emitter.setCls(Emitter.java:2079)
at org.apache.axis.tools.ant.wsdl.Java2WsdlAntTask.execute(Java2WsdlAntTask.java:188)
at org.eclipse.jst.ws.internal.axis.consumption.core.command.Java2WSDLCommand.executeAntTask(Java2WSDLCommand.java:180)
at org.eclipse.jst.ws.internal.axis.consumption.core.command.Java2WSDLCommand.execute(Java2WSDLCommand.java:95)
at org.eclipse.jst.ws.internal.axis.creation.ui.command.BUCodeGenOperation$BottomUpWSModifyOperation.execute(BUCodeGenOperation.java:122)
at org.eclipse.jst.ws.internal.axis.creation.ui.command.BUCodeGenOperation.execute(BUCodeGenOperation.java:86)
at org.eclipse.wst.command.internal.env.core.fragment.CommandFragmentEngine.runCommand(CommandFragmentEngine.java:419)
at org.eclipse.wst.command.internal.env.core.fragment.CommandFragmentEngine.visitTop(CommandFragmentEngine.java:359)
at org.eclipse.wst.command.internal.env.core.fragment.CommandFragmentEngine.moveForwardToNextStop(CommandFragmentEngine.java:254)
at org.eclipse.wst.command.internal.env.ui.widgets.SimpleCommandEngineManager$6.run(SimpleCommandEngineManager.java:294)
at org.eclipse.jface.operation.ModalContext.runInCurrentThread(ModalContext.java:464)
at org.eclipse.jface.operation.ModalContext.run(ModalContext.java:372)
at org.eclipse.jface.wizard.WizardDialog.run(WizardDialog.java:1008)
at org.eclipse.wst.command.internal.env.ui.widgets.SimpleCommandEngineManager.runForwardToNextStop(SimpleCommandEngineManager.java:264)
at org.eclipse.wst.command.internal.env.ui.widgets.WizardPageManager.runForwardToNextStop(WizardPageManager.java:91)
at org.eclipse.wst.command.internal.env.ui.widgets.WizardPageManager.getNextPage(WizardPageManager.java:154)
at org.eclipse.wst.command.internal.env.ui.widgets.SimpleWizardPage.getNextPage(SimpleWizardPage.java:136)
at org.eclipse.jface.wizard.WizardDialog.nextPressed(WizardDialog.java:887)
at org.eclipse.jface.wizard.WizardDialog.buttonPressed(WizardDialog.java:426)
at org.eclipse.jface.dialogs.Dialog$2.widgetSelected(Dialog.java:624)
at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:234)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1053)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:4066)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3657)
at org.eclipse.jface.window.Window.runEventLoop(Window.java:825)
at org.eclipse.jface.window.Window.open(Window.java:801)
at org.eclipse.ui.internal.handlers.WizardHandler$New.executeHandler(WizardHandler.java:254)
at org.eclipse.ui.internal.handlers.WizardHandler.execute(WizardHandler.java:274)
at org.eclipse.ui.internal.handlers.HandlerProxy.execute(HandlerProxy.java:293)
at org.eclipse.core.commands.Command.executeWithChecks(Command.java:476)
at org.eclipse.core.commands.ParameterizedCommand.executeWithChecks(ParameterizedCommand.java:508)
at org.eclipse.ui.internal.handlers.HandlerService.executeCommand(HandlerService.java:169)
at org.eclipse.ui.internal.handlers.SlaveHandlerService.executeCommand(SlaveHandlerService.java:241)
at org.eclipse.ui.internal.actions.CommandAction.runWithEvent(CommandAction.java:157)
at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:584)
at org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:501)
at org.eclipse.jface.action.ActionContributionItem$5.handleEvent(ActionContributionItem.java:411)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1053)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:4066)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3657)
at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2640)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2604)
at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2438)
at org.eclipse.ui.internal.Workbench$7.run(Workbench.java:671)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:664)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:115)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:369)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:619)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:574)
at org.eclipse.equinox.launcher.Main.run(Main.java:1407)
What could be the issue?
Thanks!
From your message it looks like a serialization problem. You seem to be exposing a throwable class as part of the public api and this is in violation with JAX-RPC. (Please check your exception classes for instances of throwable. Remove them and you should be fine).
Note: Example of occurrence. If your exception has this, then its a violation.
private Throwable throwable;
public Throwable getThrowable() {
return throwable;
}
I get this error when I use my autogenerated ServiceBindingStub.java. WebService side is working ok, so this error must be in code, but code is autogenerated, so I cannot know why it doesn't work. Some other calls work fine, but this doesn't. This call included updating, while other working calls are just fetching data from WebService.
AxisFault
faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
faultSubcode:
faultString: org.xml.sax.SAXParseException: Premature end of file.
faultActor:
faultNode:
faultDetail:
{http://xml.apache.org/axis/}stackTrace:org.xml.sax.SAXParseException: Premature end of file.
at org.apache.xerces.util.ErrorHandlerWrapper.createSAXParseException(Unknown Source)
at org.apache.xerces.util.ErrorHandlerWrapper.fatalError(Unknown Source)
at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
at org.apache.xerces.impl.XMLVersionDetector.determineDocVersion(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
at javax.xml.parsers.SAXParser.parse(Unknown Source)
at org.apache.axis.encoding.DeserializationContext.parse(DeserializationContext.java:227)
at org.apache.axis.SOAPPart.getAsSOAPEnvelope(SOAPPart.java:696)
at org.apache.axis.Message.getSOAPEnvelope(Message.java:435)
at org.apache.axis.handlers.soap.MustUnderstandChecker.invoke(MustUnderstandChecker.java:62)
at org.apache.axis.client.AxisClient.invoke(AxisClient.java:206)
at org.apache.axis.client.Call.invokeEngine(Call.java:2784)
at org.apache.axis.client.Call.invoke(Call.java:2767)
at org.apache.axis.client.Call.invoke(Call.java:2443)
at org.apache.axis.client.Call.invoke(Call.java:2366)
at org.apache.axis.client.Call.invoke(Call.java:1812)
This happens when service you are connecting to does not return SOAP response, but some text or HTML. Try opening the URL in the browser or use some SOAP debugger like SOAP UI to see what is returned from the service.
I once had the same problem. In my case, I received messages with 'binary data' between tags (imagery). Axis used a fixed size buffer to read the data, once the buffer was full it just proceeded and ran out of sync.
In fact, you should be able to find the tag or part in the xml file by debugging the stub code step by step. No guarantee, that the issue will can be solved easily but it might give you a hint that the (a) stub is not generated correctly or (b) the xml file is just not well-formed or valid against the schema that has been used to generate the stub.
Good luck! (I didn't solve my issue..)
I just had (and solved) this problem, following Superfilin's answer. In the end, the problem turned out to be that I hadn't added a <beanMapping> for one of the classes I was returning in my deployment.wsdd file. Any time the response would have included that class, I'd get a completely empty message body instead.
Even we have faced the same issue. But there are some special characters in the content. We removed those special characters and it worked fine.