java.lang.ClassCastException

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • When I try to consume a webservice I get this error I can see the wsdl of the webservice. The webservice was basically a function in one of my EJBs ..being exposed as a webservice, iow. (The code [shown below error] works in my jdeveloper env (with axis installed similarly as on sturdy orion server) Jdeveloper has a mini-me orion server in it...so hypothetically things should work same in both places...but on Orion server ..No) ===Start error============== AxisFault faultCode: {http://xml.apache.org/axis/}HTTP faultSubcode: faultString: (500)Internal Server Error faultActor: faultNode: faultDetail: {}:return code: 500 &lt;HTML&gt;&lt;HEAD&gt;&lt;TITLE&gt;500 Internal Server Error&lt;/TITLE&gt;&lt; /HEAD&gt;&lt;BODY&gt;&lt;H1&gt;500 Internal Server Error&lt;/H1&gt;&lt;PRE&gt;ja &lt;br&gt; at org.apache.axis.Message.&amp;lt;init&amp;gt;(Message.java:232 &lt;br&gt; at org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet &lt;br&gt; at org.apache.axis.transport.http.AxisServletBase.service(AxisSe &lt;br&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;&lt;/BODY&gt;&lt;/HTML&gt;:336) {http://xml.apache.org/axis/}HttpErrorCode:500 (500)Internal Server Error at org.apache.axis.transport.http.HTTPSender.readFromSocket(HTTPSender.j ava:744) at org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java:144) at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrateg y.java:32) at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118) at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83) at org.apache.axis.client.AxisClient.invoke(AxisClient.java:165) at org.apache.axis.client.Call.invokeEngine(Call.java:2765) at org.apache.axis.client.Call.invoke(Call.java:2748) at org.apache.axis.client.Call.invoke(Call.java:2424) at org.apache.axis.client.Call.invoke(Call.java:2347) at org.apache.axis.client.Call.invoke(Call.java:1804) at <line in my application which says call.invoke()> at org.apache.struts.action.RequestProcessor.processActionPerform(Reques tProcessor.java:484) at org.apache.struts.action.RequestProcessor.process(RequestProcessor.ja va:274) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:148 2) at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:525) at javax.servlet.http.HttpServlet.service(HttpServlet.java:211) at javax.servlet.http.HttpServlet.service(HttpServlet.java:309) at javax.servlet.http.HttpServlet.service(HttpServlet.java:336) at com.evermind._cub._phd(.:518) at com.evermind._cub._bgc(.:174) at com.evermind._ax._lqc(.:614) at com.evermind._ax._tvb(.:189) at com.evermind._bf.run(.:62) ====End Error======== ==Start code=== try { String endpoint = "http://localhost:8081/axis/services/ValidateCreditCardService"; Service service = new Service(); Call call = (Call)service.createCall(); call.setTargetEndpointAddress(endpoint); call.setOperationName(new QName("validateCreditCardWS")); Object ret = call.invoke(new Object[] { "abcd", "u000001", "90210", "junglee jaanwar", "4111111111111111", "02", "06", "", "2.30" }); System.out.println("return from validate credit card web service: " + ret); } catch(Exception e) { e.printStackTrace(); } ====End code===
    via by neal ravindran,
  • When I try to consume a webservice I get this error I can see the wsdl of the webservice. The webservice was basically a function in one of my EJBs ..being exposed as a webservice, iow. (The code [shown below error] works in my jdeveloper env (with axis installed similarly as on sturdy orion server) Jdeveloper has a mini-me orion server in it...so hypothetically things should work same in both places...but on Orion server ..No) ===Start error============== AxisFault faultCode: {http://xml.apache.org/axis/}HTTP faultSubcode: faultString: (500)Internal Server Error faultActor: faultNode: faultDetail: {}:return code: 500 &lt;HTML&gt;&lt;HEAD&gt;&lt;TITLE&gt;500 Internal Server Error&lt;/TITLE&gt;&lt; /HEAD&gt;&lt;BODY&gt;&lt;H1&gt;500 Internal Server Error&lt;/H1&gt;&lt;PRE&gt;ja &lt;br&gt; at org.apache.axis.Message.&amp;lt;init&amp;gt;(Message.java:232 &lt;br&gt; at org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet &lt;br&gt; at org.apache.axis.transport.http.AxisServletBase.service(AxisSe &lt;br&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;&lt;/BODY&gt;&lt;/HTML&gt;:336) {http://xml.apache.org/axis/}HttpErrorCode:500 (500)Internal Server Error at org.apache.axis.transport.http.HTTPSender.readFromSocket(HTTPSender.j ava:744) at org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java:144) at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrateg y.java:32) at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118) at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83) at org.apache.axis.client.AxisClient.invoke(AxisClient.java:165) at org.apache.axis.client.Call.invokeEngine(Call.java:2765) at org.apache.axis.client.Call.invoke(Call.java:2748) at org.apache.axis.client.Call.invoke(Call.java:2424) at org.apache.axis.client.Call.invoke(Call.java:2347) at org.apache.axis.client.Call.invoke(Call.java:1804) at <line in my application which says call.invoke()> at org.apache.struts.action.RequestProcessor.processActionPerform(Reques tProcessor.java:484) at org.apache.struts.action.RequestProcessor.process(RequestProcessor.ja va:274) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:148 2) at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:525) at javax.servlet.http.HttpServlet.service(HttpServlet.java:211) at javax.servlet.http.HttpServlet.service(HttpServlet.java:309) at javax.servlet.http.HttpServlet.service(HttpServlet.java:336) at com.evermind._cub._phd(.:518) at com.evermind._cub._bgc(.:174) at com.evermind._ax._lqc(.:614) at com.evermind._ax._tvb(.:189) at com.evermind._bf.run(.:62) ====End Error======== ==Start code=== try { String endpoint = "http://localhost:8081/axis/services/ValidateCreditCardService"; Service service = new Service(); Call call = (Call)service.createCall(); call.setTargetEndpointAddress(endpoint); call.setOperationName(new QName("validateCreditCardWS")); Object ret = call.invoke(new Object[] { "abcd", "u000001", "90210", "junglee jaanwar", "4111111111111111", "02", "06", "", "2.30" }); System.out.println("return from validate credit card web service: " + ret); } catch(Exception e) { e.printStackTrace(); } ====End code===
    via by neal ravindran,
  • When Run Cli and CSUM are both installed on Confluence 5.9.2 and you perform a restart of the Confluence instance; for each call of the macro cli we have in the view mode the following error in the screen: {code} Cause: org.apache.axis.ConfigurationException: java.lang.ClassCastException: org.apache.axis.handlers.http.URLMapper cannot be cast to org.apache.axis.Handler java.lang.ClassCastException: org.apache.axis.handlers.http.URLMapper cannot be cast to org.apache.axis.Handler at org.apache.axis.deployment.wsdd.WSDDDeployableItem.makeNewInstance(WSDDDeployableItem.java:302) at org.apache.axis.deployment.wsdd.WSDDDeployableItem.getNewInstance(WSDDDeployableItem.java:274) at org.apache.axis.deployment.wsdd.WSDDDeployableItem.getInstance(WSDDDeployableItem.java:260) at org.apache.axis.deployment.wsdd.WSDDDeployment.getHandler(WSDDDeployment.java:394) at org.apache.axis.deployment.wsdd.WSDDDeployableItem.getNewInstance(WSDDDeployableItem.java:276) at org.apache.axis.deployment.wsdd.WSDDDeployableItem.getInstance(WSDDDeployableItem.java:260) at org.apache.axis.deployment.wsdd.WSDDChain.makeNewInstance(WSDDChain.java:125) at org.apache.axis.deployment.wsdd.WSDDDeployableItem.getNewInstance(WSDDDeployableItem.java:274) at org.apache.axis.deployment.wsdd.WSDDDeployableItem.getInstance(WSDDDeployableItem.java:260) at org.apache.axis.deployment.wsdd.WSDDTargetedChain.makeNewInstance(WSDDTargetedChain.java:151) at org.apache.axis.deployment.wsdd.WSDDDeployableItem.getNewInstance(WSDDDeployableItem.java:274) at org.apache.axis.deployment.wsdd.WSDDDeployableItem.getInstance(WSDDDeployableItem.java:260) at org.apache.axis.deployment.wsdd.WSDDDeployment.getTransport(WSDDDeployment.java:410) at org.apache.axis.configuration.FileProvider.getTransport(FileProvider.java:257) at org.apache.axis.configuration.SimpleProvider.getTransport(SimpleProvider.java:208) at org.apache.axis.AxisEngine.getTransport(AxisEngine.java:332) at org.apache.axis.server.AxisServer.invoke(AxisServer.java:234) at org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:699) at javax.servlet.http.HttpServlet.service(HttpServlet.java:648) at org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327) at javax.servlet.http.HttpServlet.service(HttpServlet.java:729) at com.atlassian.confluence.rpc.axis.AxisSoapServer.serviceInTransaction(AxisSoapServer.java:130) at com.atlassian.confluence.rpc.axis.AxisSoapServer.access$000(AxisSoapServer.java:26) at com.atlassian.confluence.rpc.axis.AxisSoapServer$1.doInTransaction(AxisSoapServer.java:81) at com.atlassian.confluence.rpc.axis.AxisSoapServer$1.doInTransaction(AxisSoapServer.java:75) ... {code} And in the Catalina.out : {code} log4j:ERROR A "com.atlassian.confluence.logging.ConfluenceHomeLogAppender" object is not assignable to a "org.apache.log4j.Appender" variable. log4j:ERROR The class "org.apache.log4j.Appender" was loaded by log4j:ERROR [com.atlassian.plugins.document-conversion-library [225]] whereas object of type log4j:ERROR "com.atlassian.confluence.logging.ConfluenceHomeLogAppender" was loaded by [WebappClassLoader context: ROOT delegate: false ----------> Parent Classloader: java.net.URLClassLoader@19469ea2 ]. log4j:ERROR Could not instantiate appender named "confluencelog". log4j:ERROR A "com.atlassian.core.logging.ThreadLocalErrorLogAppender" object is not assignable to a "org.apache.log4j.Appender" variable. log4j:ERROR The class "org.apache.log4j.Appender" was loaded by log4j:ERROR [com.atlassian.plugins.document-conversion-library [225]] whereas object of type log4j:ERROR "com.atlassian.core.logging.ThreadLocalErrorLogAppender" was loaded by [WebappClassLoader context: ROOT delegate: false ----------> Parent Classloader: java.net.URLClassLoader@19469ea2 ]. log4j:ERROR Could not instantiate appender named "errorlog". log4j:ERROR A "com.atlassian.confluence.logging.ConfluenceHomeLogAppender" object is not assignable to a "org.apache.log4j.Appender" variable. log4j:ERROR The class "org.apache.log4j.Appender" was loaded by log4j:ERROR [com.atlassian.plugins.document-conversion-library [225]] whereas object of type log4j:ERROR "com.atlassian.confluence.logging.ConfluenceHomeLogAppender" was loaded by [WebappClassLoader context: ROOT delegate: false ----------> Parent Classloader: java.net.URLClassLoader@19469ea2 ]. log4j:ERROR Could not instantiate appender named "confluencelog". {code} Thank you for your help. Best Regards, Cyrille Martin
    via by cyrille martin,
  • When Run Cli and CSUM are both installed on Confluence 5.9.2 and you perform a restart of the Confluence instance; for each call of the macro cli we have in the view mode the following error in the screen: {code} Cause: org.apache.axis.ConfigurationException: java.lang.ClassCastException: org.apache.axis.handlers.http.URLMapper cannot be cast to org.apache.axis.Handler java.lang.ClassCastException: org.apache.axis.handlers.http.URLMapper cannot be cast to org.apache.axis.Handler at org.apache.axis.deployment.wsdd.WSDDDeployableItem.makeNewInstance(WSDDDeployableItem.java:302) at org.apache.axis.deployment.wsdd.WSDDDeployableItem.getNewInstance(WSDDDeployableItem.java:274) at org.apache.axis.deployment.wsdd.WSDDDeployableItem.getInstance(WSDDDeployableItem.java:260) at org.apache.axis.deployment.wsdd.WSDDDeployment.getHandler(WSDDDeployment.java:394) at org.apache.axis.deployment.wsdd.WSDDDeployableItem.getNewInstance(WSDDDeployableItem.java:276) at org.apache.axis.deployment.wsdd.WSDDDeployableItem.getInstance(WSDDDeployableItem.java:260) at org.apache.axis.deployment.wsdd.WSDDChain.makeNewInstance(WSDDChain.java:125) at org.apache.axis.deployment.wsdd.WSDDDeployableItem.getNewInstance(WSDDDeployableItem.java:274) at org.apache.axis.deployment.wsdd.WSDDDeployableItem.getInstance(WSDDDeployableItem.java:260) at org.apache.axis.deployment.wsdd.WSDDTargetedChain.makeNewInstance(WSDDTargetedChain.java:151) at org.apache.axis.deployment.wsdd.WSDDDeployableItem.getNewInstance(WSDDDeployableItem.java:274) at org.apache.axis.deployment.wsdd.WSDDDeployableItem.getInstance(WSDDDeployableItem.java:260) at org.apache.axis.deployment.wsdd.WSDDDeployment.getTransport(WSDDDeployment.java:410) at org.apache.axis.configuration.FileProvider.getTransport(FileProvider.java:257) at org.apache.axis.configuration.SimpleProvider.getTransport(SimpleProvider.java:208) at org.apache.axis.AxisEngine.getTransport(AxisEngine.java:332) at org.apache.axis.server.AxisServer.invoke(AxisServer.java:234) at org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:699) at javax.servlet.http.HttpServlet.service(HttpServlet.java:648) at org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327) at javax.servlet.http.HttpServlet.service(HttpServlet.java:729) at com.atlassian.confluence.rpc.axis.AxisSoapServer.serviceInTransaction(AxisSoapServer.java:130) at com.atlassian.confluence.rpc.axis.AxisSoapServer.access$000(AxisSoapServer.java:26) at com.atlassian.confluence.rpc.axis.AxisSoapServer$1.doInTransaction(AxisSoapServer.java:81) at com.atlassian.confluence.rpc.axis.AxisSoapServer$1.doInTransaction(AxisSoapServer.java:75) ... {code} And in the Catalina.out : {code} log4j:ERROR A "com.atlassian.confluence.logging.ConfluenceHomeLogAppender" object is not assignable to a "org.apache.log4j.Appender" variable. log4j:ERROR The class "org.apache.log4j.Appender" was loaded by log4j:ERROR [com.atlassian.plugins.document-conversion-library [225]] whereas object of type log4j:ERROR "com.atlassian.confluence.logging.ConfluenceHomeLogAppender" was loaded by [WebappClassLoader context: ROOT delegate: false ----------> Parent Classloader: java.net.URLClassLoader@19469ea2 ]. log4j:ERROR Could not instantiate appender named "confluencelog". log4j:ERROR A "com.atlassian.core.logging.ThreadLocalErrorLogAppender" object is not assignable to a "org.apache.log4j.Appender" variable. log4j:ERROR The class "org.apache.log4j.Appender" was loaded by log4j:ERROR [com.atlassian.plugins.document-conversion-library [225]] whereas object of type log4j:ERROR "com.atlassian.core.logging.ThreadLocalErrorLogAppender" was loaded by [WebappClassLoader context: ROOT delegate: false ----------> Parent Classloader: java.net.URLClassLoader@19469ea2 ]. log4j:ERROR Could not instantiate appender named "errorlog". log4j:ERROR A "com.atlassian.confluence.logging.ConfluenceHomeLogAppender" object is not assignable to a "org.apache.log4j.Appender" variable. log4j:ERROR The class "org.apache.log4j.Appender" was loaded by log4j:ERROR [com.atlassian.plugins.document-conversion-library [225]] whereas object of type log4j:ERROR "com.atlassian.confluence.logging.ConfluenceHomeLogAppender" was loaded by [WebappClassLoader context: ROOT delegate: false ----------> Parent Classloader: java.net.URLClassLoader@19469ea2 ]. log4j:ERROR Could not instantiate appender named "confluencelog". {code} Thank you for your help. Best Regards, Cyrille Martin
    via by cyrille martin,
  • db:: 7.01::ClassCastException (ClassLoader Error) 8k
    via by Unknown author,
  • Hello, I want to use the JiraSoapService in my plugin to communicate with another Jira. I add this to my pom.xml: {code:xml} <dependency> <groupId>com.atlassian.jira.plugins</groupId> <artifactId>jira-soapclient</artifactId> <version>${jira.version}</version> </dependency> {code} But when I try to login to another Jira. {code:java} String baseUrl = url + "/rpc/soap/jirasoapservice-v2"; JiraSoapService jiraSoapService = jiraSoapServiceLocator.getJirasoapserviceV2(new URL(baseUrl)); String login = jiraSoapService.login("admin", "admin"); {code} I get a ClassCastException: AxisFault [INFO] [talledLocalContainer] faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException [INFO] [talledLocalContainer] faultSubcode: [INFO] [talledLocalContainer] faultString: java.lang.ClassCastException: org.apache.axis.attachments.AttachmentsImpl cannot be cast to org.apache.axis.attachments.Attachments [INFO] [talledLocalContainer] faultActor: [INFO] [talledLocalContainer] faultNode: [INFO] [talledLocalContainer] faultDetail: [INFO] [talledLocalContainer] {http://xml.apache.org/axis/}stackTrace:java.lang.ClassCastException: org.apache.axis.attachments.AttachmentsImpl cannot be cast to org.apache.axis.attachments.Attachments [INFO] [talledLocalContainer] at org.apache.axis.Message.setup(Message.java:352) [INFO] [talledLocalContainer] at org.apache.axis.Message.<init>(Message.java:246) [INFO] [talledLocalContainer] at org.apache.axis.client.Call.invoke(Call.java:2425) [INFO] [talledLocalContainer] at org.apache.axis.client.Call.invoke(Call.java:2366) [INFO] [talledLocalContainer] at org.apache.axis.client.Call.invoke(Call.java:1812)
    via by Christian Schulze,
    • java.lang.ClassCastException at org.apache.axis.Message.setup(Message.java:341) at org.apache.axis.Message.<init>(Message.java:232) at org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:628) at javax.servlet.http.HttpServlet.service(HttpServlet.java:211) at javax.servlet.http.HttpServlet.service(HttpServlet.java:309) at org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327) at javax.servlet.http.HttpServlet.service(HttpServlet.java:336)
    No Bugmate found.