You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cxf.apache.org by Nino Saturnino Martinez Vazquez Wael <ni...@jayway.dk> on 2007/12/18 12:21:05 UTC
mvn archetype:create -DarchetypeGroupId=org.apache.cxf -DarchetypeArtifactId=cxf-http-basic
Works almost fine...
Although it ignores -DgroupId= to a certain extent. The packagenames in
helloworld.java and helloworldimpl.java are called org.apache...
eventhough they files are placed in the package specified in dgroupid.
I would also very much like for the archetype to include some very basic
tests. This would allow users to get started testing without too much
fuzz. Should I add two seperate jira issues for this(one for the
ignoring, bug and one for tests, RFE)?
--
Nino Martinez Wael
Java Specialist @ Jayway DK
http://www.jayway.dk
+45 2936 7684
Re: mvn archetype:create -DarchetypeGroupId=org.apache.cxf -DarchetypeArtifactId=cxf-http-basic
Posted by Nino Saturnino Martinez Vazquez Wael <ni...@jayway.dk>.
Okay found the error, one of the endpoints annotations had an reference
to org.apache.cxf.helloworld and not the name that I specified in
-dgroupid when creating the project with the archetype.
And had to add:
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>servlet-api</artifactId>
<version>2.5</version>
<scope>provided</scope>
</dependency>
since it was missing inorder to test. I'll go ahead and do somemore
testing and see what I find.
Nino Saturnino Martinez Vazquez Wael wrote:
> Ok so I've gone ahead and tried to create some tests for the simple
> project. But I keep getting errors, now this is what I've done so far:
>
> moved beans.xml to src/main/resources so that it will be accesible for
> spring testing. Then I've looked into SpringBusFactoryTest (in this
> package org.apache.cxf.systest.bus), I kind of figured the test would
> be to some use. I changed the reference to servlet.xml to just
> beans.xml. But both tests fails horribly:
>
> heres the current compilation:
>
> Just go to the bottom of the page and click download...
>
> http://www.fileshost.com/en/file/22469/basic-zip.html
>
> Now it could be that its just the wrong way im testing, as im
> completely new to cfx. Heres the trace I get:
>
> org.springframework.beans.factory.BeanCreationException: Error
> creating bean with name 'helloWorld': Invocation of init method
> failed; nested exception is javax.xml.ws.WebServiceException: Could
> not load Webservice SEI
> Caused by: javax.xml.ws.WebServiceException: Could not load Webservice
> SEI
> at
> org.apache.cxf.jaxws.support.JaxWsImplementorInfo.initialize(JaxWsImplementorInfo.java:280)
>
> at
> org.apache.cxf.jaxws.support.JaxWsImplementorInfo.<init>(JaxWsImplementorInfo.java:57)
>
> at org.apache.cxf.jaxws.EndpointImpl.getServer(EndpointImpl.java:282)
> at org.apache.cxf.jaxws.EndpointImpl.doPublish(EndpointImpl.java:260)
> at org.apache.cxf.jaxws.EndpointImpl.publish(EndpointImpl.java:211)
> at org.apache.cxf.jaxws.EndpointImpl.publish(EndpointImpl.java:388)
> 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:585)
> at
> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeCustomInitMethod(AbstractAutowireCapableBeanFactory.java:1240)
>
> at
> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1205)
>
> at
> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1171)
>
> at
> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:425)
>
> at
> org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:251)
>
> at
> org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:156)
>
> at
> org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:248)
>
> at
> org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:160)
>
> at
> org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:287)
>
> at
> org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:352)
>
> at
> org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:91)
>
> at
> org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:75)
>
> at
> com.jayway.SpringBusFactoryBasicTest.testLoadBusWithServletApplicationContext(SpringBusFactoryBasicTest.java:62)
>
> 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:585)
> at
> org.junit.internal.runners.TestMethodRunner.executeMethodBody(TestMethodRunner.java:99)
>
> at
> org.junit.internal.runners.TestMethodRunner.runUnprotected(TestMethodRunner.java:81)
>
> at
> org.junit.internal.runners.BeforeAndAfterRunner.runProtected(BeforeAndAfterRunner.java:34)
>
> at
> org.junit.internal.runners.TestMethodRunner.runMethod(TestMethodRunner.java:75)
>
> at
> org.junit.internal.runners.TestMethodRunner.run(TestMethodRunner.java:45)
> at
> org.junit.internal.runners.TestClassMethodsRunner.invokeTestMethod(TestClassMethodsRunner.java:71)
>
> at
> org.junit.internal.runners.TestClassMethodsRunner.run(TestClassMethodsRunner.java:35)
>
> at
> org.junit.internal.runners.TestClassRunner$1.runUnprotected(TestClassRunner.java:42)
>
> at
> org.junit.internal.runners.BeforeAndAfterRunner.runProtected(BeforeAndAfterRunner.java:34)
>
> at
> org.junit.internal.runners.TestClassRunner.run(TestClassRunner.java:52)
> at
> org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:38)
>
> at
> org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
>
> at
> org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460)
>
> at
> org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673)
>
> at
> org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386)
>
> at
> org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196)
>
> Caused by: java.lang.ClassNotFoundException: org.apache.cxf.HelloWorld
> 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
> org.apache.cxf.common.classloader.ClassLoaderUtils.loadClass2(ClassLoaderUtils.java:127)
>
> at
> org.apache.cxf.common.classloader.ClassLoaderUtils.loadClass(ClassLoaderUtils.java:116)
>
> at
> org.apache.cxf.jaxws.support.JaxWsImplementorInfo.initialize(JaxWsImplementorInfo.java:278)
>
> ... 42 more
>
>
>
> Nino Saturnino Martinez Vazquez Wael wrote:
>> np, so I guess the RFE would be relevant?
>>
>> bug report for the other thing here:
>>
>> https://issues.apache.org/jira/browse/CXF-1312
>>
>> Freeman Fang wrote:
>>> Ignore this email
>>> I make a big mistake, I thought this mail is for servicemix mailing
>>> list.
>>> Sorry for it
>>>
>>> Freeman
>>>
>>> On Dec 18, 2007 8:41 PM, Freeman Fang <fr...@gmail.com> wrote:
>>>
>>>
>>>> Hi,
>>>> Sure for create jira for -DgroupId issue.
>>>> About the test, I think we have some basic test for servicemix
>>>> archetype,
>>>> [1] for more details
>>>> [1]
>>>> http://svn.apache.org/repos/asf/servicemix/smx3/trunk/archetypes/servicemix-archetypes-itests/src/test/java/org/apache/servicemix/tooling/
>>>>
>>>>
>>>> Best Regards
>>>> Freeman
>>>>
>>>>
>>>> On Dec 18, 2007 7:21 PM, Nino Saturnino Martinez Vazquez Wael <
>>>> nino.martinez@jayway.dk> wrote:
>>>>
>>>>
>>>>> Works almost fine...
>>>>>
>>>>> Although it ignores -DgroupId= to a certain extent. The
>>>>> packagenames in
>>>>> helloworld.java and helloworldimpl.java are called org.apache...
>>>>> eventhough they files are placed in the package specified in
>>>>> dgroupid.
>>>>>
>>>>> I would also very much like for the archetype to include some very
>>>>> basic
>>>>> tests. This would allow users to get started testing without too much
>>>>> fuzz. Should I add two seperate jira issues for this(one for the
>>>>> ignoring, bug and one for tests, RFE)?
>>>>>
>>>>> --
>>>>> Nino Martinez Wael
>>>>> Java Specialist @ Jayway DK
>>>>> http://www.jayway.dk
>>>>> +45 2936 7684
>>>>>
>>>>>
>>>>>
>>>
>>>
>>
>
--
Nino Martinez Wael
Java Specialist @ Jayway DK
http://www.jayway.dk
+45 2936 7684
Re: mvn archetype:create -DarchetypeGroupId=org.apache.cxf -DarchetypeArtifactId=cxf-http-basic
Posted by Nino Saturnino Martinez Vazquez Wael <ni...@jayway.dk>.
Ok so I've gone ahead and tried to create some tests for the simple
project. But I keep getting errors, now this is what I've done so far:
moved beans.xml to src/main/resources so that it will be accesible for
spring testing. Then I've looked into SpringBusFactoryTest (in this
package org.apache.cxf.systest.bus), I kind of figured the test would be
to some use. I changed the reference to servlet.xml to just beans.xml.
But both tests fails horribly:
heres the current compilation:
Just go to the bottom of the page and click download...
http://www.fileshost.com/en/file/22469/basic-zip.html
Now it could be that its just the wrong way im testing, as im completely
new to cfx. Heres the trace I get:
org.springframework.beans.factory.BeanCreationException: Error creating
bean with name 'helloWorld': Invocation of init method failed; nested
exception is javax.xml.ws.WebServiceException: Could not load Webservice SEI
Caused by: javax.xml.ws.WebServiceException: Could not load Webservice SEI
at
org.apache.cxf.jaxws.support.JaxWsImplementorInfo.initialize(JaxWsImplementorInfo.java:280)
at
org.apache.cxf.jaxws.support.JaxWsImplementorInfo.<init>(JaxWsImplementorInfo.java:57)
at org.apache.cxf.jaxws.EndpointImpl.getServer(EndpointImpl.java:282)
at org.apache.cxf.jaxws.EndpointImpl.doPublish(EndpointImpl.java:260)
at org.apache.cxf.jaxws.EndpointImpl.publish(EndpointImpl.java:211)
at org.apache.cxf.jaxws.EndpointImpl.publish(EndpointImpl.java:388)
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:585)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeCustomInitMethod(AbstractAutowireCapableBeanFactory.java:1240)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1205)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1171)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:425)
at
org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:251)
at
org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:156)
at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:248)
at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:160)
at
org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:287)
at
org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:352)
at
org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:91)
at
org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:75)
at
com.jayway.SpringBusFactoryBasicTest.testLoadBusWithServletApplicationContext(SpringBusFactoryBasicTest.java:62)
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:585)
at
org.junit.internal.runners.TestMethodRunner.executeMethodBody(TestMethodRunner.java:99)
at
org.junit.internal.runners.TestMethodRunner.runUnprotected(TestMethodRunner.java:81)
at
org.junit.internal.runners.BeforeAndAfterRunner.runProtected(BeforeAndAfterRunner.java:34)
at
org.junit.internal.runners.TestMethodRunner.runMethod(TestMethodRunner.java:75)
at
org.junit.internal.runners.TestMethodRunner.run(TestMethodRunner.java:45)
at
org.junit.internal.runners.TestClassMethodsRunner.invokeTestMethod(TestClassMethodsRunner.java:71)
at
org.junit.internal.runners.TestClassMethodsRunner.run(TestClassMethodsRunner.java:35)
at
org.junit.internal.runners.TestClassRunner$1.runUnprotected(TestClassRunner.java:42)
at
org.junit.internal.runners.BeforeAndAfterRunner.runProtected(BeforeAndAfterRunner.java:34)
at
org.junit.internal.runners.TestClassRunner.run(TestClassRunner.java:52)
at
org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:38)
at
org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196)
Caused by: java.lang.ClassNotFoundException: org.apache.cxf.HelloWorld
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
org.apache.cxf.common.classloader.ClassLoaderUtils.loadClass2(ClassLoaderUtils.java:127)
at
org.apache.cxf.common.classloader.ClassLoaderUtils.loadClass(ClassLoaderUtils.java:116)
at
org.apache.cxf.jaxws.support.JaxWsImplementorInfo.initialize(JaxWsImplementorInfo.java:278)
... 42 more
Nino Saturnino Martinez Vazquez Wael wrote:
> np, so I guess the RFE would be relevant?
>
> bug report for the other thing here:
>
> https://issues.apache.org/jira/browse/CXF-1312
>
> Freeman Fang wrote:
>> Ignore this email
>> I make a big mistake, I thought this mail is for servicemix mailing
>> list.
>> Sorry for it
>>
>> Freeman
>>
>> On Dec 18, 2007 8:41 PM, Freeman Fang <fr...@gmail.com> wrote:
>>
>>
>>> Hi,
>>> Sure for create jira for -DgroupId issue.
>>> About the test, I think we have some basic test for servicemix
>>> archetype,
>>> [1] for more details
>>> [1]
>>> http://svn.apache.org/repos/asf/servicemix/smx3/trunk/archetypes/servicemix-archetypes-itests/src/test/java/org/apache/servicemix/tooling/
>>>
>>>
>>> Best Regards
>>> Freeman
>>>
>>>
>>> On Dec 18, 2007 7:21 PM, Nino Saturnino Martinez Vazquez Wael <
>>> nino.martinez@jayway.dk> wrote:
>>>
>>>
>>>> Works almost fine...
>>>>
>>>> Although it ignores -DgroupId= to a certain extent. The
>>>> packagenames in
>>>> helloworld.java and helloworldimpl.java are called org.apache...
>>>> eventhough they files are placed in the package specified in dgroupid.
>>>>
>>>> I would also very much like for the archetype to include some very
>>>> basic
>>>> tests. This would allow users to get started testing without too much
>>>> fuzz. Should I add two seperate jira issues for this(one for the
>>>> ignoring, bug and one for tests, RFE)?
>>>>
>>>> --
>>>> Nino Martinez Wael
>>>> Java Specialist @ Jayway DK
>>>> http://www.jayway.dk
>>>> +45 2936 7684
>>>>
>>>>
>>>>
>>
>>
>
--
Nino Martinez Wael
Java Specialist @ Jayway DK
http://www.jayway.dk
+45 2936 7684
Re: mvn archetype:create -DarchetypeGroupId=org.apache.cxf -DarchetypeArtifactId=cxf-http-basic
Posted by Nino Saturnino Martinez Vazquez Wael <ni...@jayway.dk>.
np, so I guess the RFE would be relevant?
bug report for the other thing here:
https://issues.apache.org/jira/browse/CXF-1312
Freeman Fang wrote:
> Ignore this email
> I make a big mistake, I thought this mail is for servicemix mailing list.
> Sorry for it
>
> Freeman
>
> On Dec 18, 2007 8:41 PM, Freeman Fang <fr...@gmail.com> wrote:
>
>
>> Hi,
>> Sure for create jira for -DgroupId issue.
>> About the test, I think we have some basic test for servicemix archetype,
>> [1] for more details
>> [1]
>> http://svn.apache.org/repos/asf/servicemix/smx3/trunk/archetypes/servicemix-archetypes-itests/src/test/java/org/apache/servicemix/tooling/
>>
>> Best Regards
>> Freeman
>>
>>
>> On Dec 18, 2007 7:21 PM, Nino Saturnino Martinez Vazquez Wael <
>> nino.martinez@jayway.dk> wrote:
>>
>>
>>> Works almost fine...
>>>
>>> Although it ignores -DgroupId= to a certain extent. The packagenames in
>>> helloworld.java and helloworldimpl.java are called org.apache...
>>> eventhough they files are placed in the package specified in dgroupid.
>>>
>>> I would also very much like for the archetype to include some very basic
>>> tests. This would allow users to get started testing without too much
>>> fuzz. Should I add two seperate jira issues for this(one for the
>>> ignoring, bug and one for tests, RFE)?
>>>
>>> --
>>> Nino Martinez Wael
>>> Java Specialist @ Jayway DK
>>> http://www.jayway.dk
>>> +45 2936 7684
>>>
>>>
>>>
>
>
--
Nino Martinez Wael
Java Specialist @ Jayway DK
http://www.jayway.dk
+45 2936 7684
Re: mvn archetype:create -DarchetypeGroupId=org.apache.cxf -DarchetypeArtifactId=cxf-http-basic
Posted by Freeman Fang <fr...@gmail.com>.
Ignore this email
I make a big mistake, I thought this mail is for servicemix mailing list.
Sorry for it
Freeman
On Dec 18, 2007 8:41 PM, Freeman Fang <fr...@gmail.com> wrote:
> Hi,
> Sure for create jira for -DgroupId issue.
> About the test, I think we have some basic test for servicemix archetype,
> [1] for more details
> [1]
> http://svn.apache.org/repos/asf/servicemix/smx3/trunk/archetypes/servicemix-archetypes-itests/src/test/java/org/apache/servicemix/tooling/
>
> Best Regards
> Freeman
>
>
> On Dec 18, 2007 7:21 PM, Nino Saturnino Martinez Vazquez Wael <
> nino.martinez@jayway.dk> wrote:
>
> > Works almost fine...
> >
> > Although it ignores -DgroupId= to a certain extent. The packagenames in
> > helloworld.java and helloworldimpl.java are called org.apache...
> > eventhough they files are placed in the package specified in dgroupid.
> >
> > I would also very much like for the archetype to include some very basic
> > tests. This would allow users to get started testing without too much
> > fuzz. Should I add two seperate jira issues for this(one for the
> > ignoring, bug and one for tests, RFE)?
> >
> > --
> > Nino Martinez Wael
> > Java Specialist @ Jayway DK
> > http://www.jayway.dk
> > +45 2936 7684
> >
> >
>
Re: mvn archetype:create -DarchetypeGroupId=org.apache.cxf -DarchetypeArtifactId=cxf-http-basic
Posted by Freeman Fang <fr...@gmail.com>.
Hi,
Sure for create jira for -DgroupId issue.
About the test, I think we have some basic test for servicemix archetype,
[1] for more details
[1]
http://svn.apache.org/repos/asf/servicemix/smx3/trunk/archetypes/servicemix-archetypes-itests/src/test/java/org/apache/servicemix/tooling/
Best Regards
Freeman
On Dec 18, 2007 7:21 PM, Nino Saturnino Martinez Vazquez Wael <
nino.martinez@jayway.dk> wrote:
> Works almost fine...
>
> Although it ignores -DgroupId= to a certain extent. The packagenames in
> helloworld.java and helloworldimpl.java are called org.apache...
> eventhough they files are placed in the package specified in dgroupid.
>
> I would also very much like for the archetype to include some very basic
> tests. This would allow users to get started testing without too much
> fuzz. Should I add two seperate jira issues for this(one for the
> ignoring, bug and one for tests, RFE)?
>
> --
> Nino Martinez Wael
> Java Specialist @ Jayway DK
> http://www.jayway.dk
> +45 2936 7684
>
>