|
From: Sebastian E. C. <seb...@re...> - 2008-07-01 14:16:15
|
It's a simple unit test with the http client. Below is the stack trace.
Thanks for your time,
Sebastian
import org.resteasy.plugins.client.httpclient.ProxyFactory;
import junit.framework.TestCase;
public class ListaCandidatosTestCase{
public static void main(String[] args) {
try{
ListaCandidatos lista =
ProxyFactory.create(ListaCandidatos.class,
"http://localhost:8080");
System.out.println(lista.getCandidato("asd", "3434",
"ooo"));
}catch(Exception e){
e.printStackTrace();
}
}
}
java.lang.ExceptionInInitializerError
at
org.resteasy.util.MediaTypeHelper.getProduces(MediaTypeHelper.java:40)
at org.resteasy.ClientInvoker.<init>(ClientInvoker.java:80)
at
org.resteasy.plugins.client.httpclient.HttpClientInvoker.<init>(HttpClientInvoker.java:40)
at
org.resteasy.plugins.client.httpclient.GetInvoker.<init>(GetInvoker.java:18)
at
org.resteasy.plugins.client.httpclient.ProxyFactory.create(ProxyFactory.java:55)
at
org.resteasy.plugins.client.httpclient.ProxyFactory.create(ProxyFactory.java:33)
at
org.resteasy.plugins.client.httpclient.ProxyFactory.create(ProxyFactory.java:26)
at
coop.bancocredicoop.ListaCandidatosTestCase.main(ListaCandidatosTestCase.java:11)
Caused by: java.lang.RuntimeException: java.lang.ClassNotFoundException:
com.sun.ws.rs.ext.RuntimeDelegateImpl
at javax.ws.rs.ext.RuntimeDelegate.getInstance(RuntimeDelegate.java:117)
at javax.ws.rs.core.MediaType.<clinit>(MediaType.java:46)
... 8 more
Caused by: java.lang.ClassNotFoundException:
com.sun.ws.rs.ext.RuntimeDelegateImpl
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:268)
at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
at javax.ws.rs.ext.FactoryFinder.newInstance(FactoryFinder.java:44)
at javax.ws.rs.ext.FactoryFinder.find(FactoryFinder.java:141)
at javax.ws.rs.ext.RuntimeDelegate.getInstance(RuntimeDelegate.java:96)
... 9 more
El lun, 30-06-2008 a las 15:25 -0400, Bill Burke escribió:
> Looks like you're not initializing things right. How exactly are you
> using Resteasy?
>
> Sebastian E. Cao wrote:
> > Hi Bill,
> >
> > My name is Sebastian Cao and I'm the JBoss SE for LatinAmerica.
> > I'm right now spending some free time with a customer trying your reast
> > easy implementation (great stuff by the way), but under a test we get a:
> >
> > ClassNotFoundException: com.sun.ws.rs.ext.RuntimeDelegateImpl
> >
> > and I can not find where this class is, is not in the distro nor we can
> > find it at Sun's. Any pointers of where this comes from?
> >
> > Thanks for your time.
> >
> > Regards,
> > Sebastian
> >
> > ____________________________________
> > *Lic. Sebastián E. Cao*
> > JBoss Solution Architect
> > Red Hat LatinAmerica
> > Tel: (54) 11 4341 6200
> >
> > seb...@re... <<mailto:seb...@re...>
> > www.redhat.com/jboss <http://www.redhat.com/jboss>
> > www.jboss.com
> >
> >
> > IT executives: Red Hat #1 in value. Again.
> > http://www.redhat.com/promo/vendor/
> >
>
____________________________________
Lic. Sebastián E. Cao
JBoss Solution Architect
Red Hat LatinAmerica
Tel: (54) 11 4341 6200
seb...@re...
www.redhat.com/jboss
www.jboss.com
IT executives: Red Hat #1 in value. Again.
http://www.redhat.com/promo/vendor/
|