<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<body link="#355491" alink="#4262a1" vlink="#355491" style="background: #e2e2e2; margin: 0; padding: 20px;">
<div>
        <table cellpadding="0" bgcolor="#FFFFFF" border="0" cellspacing="0" style="border: 1px solid #dadada; margin-bottom: 30px; width: 100%; -moz-border-radius: 6px; -webkit-border-radius: 6px;">
                <tbody>
                        <tr>
                                <td>
                                        <table border="0" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF" style="border: solid 2px #ccc; background: #dadada; width: 100%; -moz-border-radius: 6px; -webkit-border-radius: 6px;">
                                                <tbody>
                                                        <tr>
                                                                <td bgcolor="#000000" valign="middle" height="58px" style="border-bottom: 1px solid #ccc; padding: 20px; -moz-border-radius-topleft: 3px; -moz-border-radius-topright: 3px; -webkit-border-top-right-radius: 5px; -webkit-border-top-left-radius: 5px;">
                                                                        <h1 style="color: #333333; font: bold 22px Arial, Helvetica, sans-serif; margin: 0; display: block !important;">
                                                                        <!-- To have a header image/logo replace the name below with your img tag -->
                                                                        <!-- Email clients will render the images when the message is read so any image -->
                                                                        <!-- must be made available on a public server, so that all recipients can load the image. -->
                                                                        <a href="https://community.jboss.org/index.jspa" style="text-decoration: none; color: #E1E1E1">JBoss Community</a></h1>
                                                                </td>
                                                        </tr>
                                                        <tr>
                                                                <td bgcolor="#FFFFFF" style="font: normal 12px Arial, Helvetica, sans-serif; color:#333333; padding: 20px; -moz-border-radius-bottomleft: 4px; -moz-border-radius-bottomright: 4px; -webkit-border-bottom-right-radius: 5px; -webkit-border-bottom-left-radius: 5px;"><h3 style="margin: 10px 0 5px; font-size: 17px; font-weight: normal;">
Call a jBossWS results in java.lang.NoClassDefFoundError: Could not initialize class $Proxy2341
</h3>
<span style="margin-bottom: 10px;">
created by <a href="https://community.jboss.org/people/stdaparks">Steven Parks</a> in <i>JBoss Web Services Development</i> - <a href="https://community.jboss.org/message/717608#717608">View the full discussion</a>
</span>
<hr style="margin: 20px 0; border: none; background-color: #dadada; height: 1px;">
<div class="jive-rendered-content"><p>I used wsconsume to generate a proxy class to web-service enabled beans.  </p><p>In trying to test that it works, using a test-cradle JSP I get the following error:</p><p style="min-height: 8pt; height: 8pt; padding: 0px;"> </p><p>13:52:15,039 ERROR [[jsp]] Servlet.service() for servlet jsp threw exception</p><p>     [exec] java.lang.NoClassDefFoundError: Could not initialize class $Proxy2341</p><p>     [exec]           at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)</p><p>     [exec]           at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)</p><p>     [exec]           at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)</p><p>     [exec]           at java.lang.reflect.Constructor.newInstance(Constructor.java:513)</p><p>     [exec]           at java.lang.reflect.Proxy.newProxyInstance(Proxy.java:588)</p><p>     [exec]           at org.jboss.ws.core.jaxws.spi.ServiceDelegateImpl.createProxy(ServiceDelegateImpl.java:451)</p><p>     [exec]           at org.jboss.ws.core.jaxws.spi.ServiceDelegateImpl.getPortInternal(ServiceDelegateImpl.java:304)</p><p>     [exec]           at org.jboss.ws.core.jaxws.spi.ServiceDelegateImpl.getPort(ServiceDelegateImpl.java:225)</p><p>     [exec]           at javax.xml.ws.Service.getPort(Service.java:92)</p><p>     [exec]           at com.bcaa.ccprocessing.service.ws.VaultTransactionManagementWebService.getVaultTransactionManagementServicePort(VaultTransactionManagementWebService.java:56)</p><p style="min-height: 8pt; height: 8pt; padding: 0px;"> </p><p>which results from the JSP code</p><p style="min-height: 8pt; height: 8pt; padding: 0px;"> </p><p>[exec] 13:52:15,057 ERROR [STDERR] org.apache.jasper.JasperException: An exception occurred processing JSP page /html/portlet/insurance/find_policy.jsp at line 334</p><p>     [exec] 331:  //com.bcaa.ccprocessing.service.ws.VaultTransactionManagementService wsService = service.getPort(com.bcaa.ccprocessing.service.ws.VaultTransactionManagementService.class);</p><p>     [exec] 332:  com.bcaa.ccprocessing.service.ws.VaultTransactionManagementWebService bb = new com.bcaa.ccprocessing.service.ws.VaultTransactionManagementWebService(url, qname);</p><p>     [exec] 333:  System.out.println("WebService endpoint loaded..." + bb.toString());</p><p>     [exec] 334:  com.bcaa.ccprocessing.service.ws.VaultTransactionManagementService wsService = bb.getVaultTransactionManagementServicePort();</p><p>     [exec] 335:  System.out.println("WebService class loaded " + wsService.toString());</p><p>     [exec] 336:  </p><p>     [exec] 337:  com.bcaa.ccprocessing.service.ws.Creditcard creditCard = wsService.fetchVaultCardDetails(11);</p><p style="min-height: 8pt; height: 8pt; padding: 0px;"> </p><p>jBossWS/services lists my service and the WSDL is available.  The line which fails is the Service.getPort call (javax,xml.ws.Service and its implementation).</p><p>    public <T> T getPort(QName portName,</p><p>            Class<T> serviceEndpointInterface) {</p><p>        return delegate.getPort(portName, serviceEndpointInterface);</p><p>    }</p><p style="min-height: 8pt; height: 8pt; padding: 0px;"> </p><p>What am I missing.  I am stuck as I don't have a lot of information to go on.</p><p style="min-height: 8pt; height: 8pt; padding: 0px;"> </p><p>Thanks in advance...</p></div>
<div style="background-color: #f4f4f4; padding: 10px; margin-top: 20px;">
<p style="margin: 0;">Reply to this message by <a href="https://community.jboss.org/message/717608#717608">going to Community</a></p>
        <p style="margin: 0;">Start a new discussion in JBoss Web Services Development at <a href="https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2047">Community</a></p>
</div></td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</div>
</body>
</html>