On 3/18/07, Owen Thomas <[EMAIL PROTECTED]> wrote:
Hello again.
Thank you again Bruce for your help. I created the project fine.
However, looking at ExampleService.java in my NB editor, I see that it
is complaining that it can't find the classes javax.jws.WebMethod and
javax.jws.WebService.
If this were in Eclipse, I could tell you exactly what to do.
Unfortunately I know nothing about NetBeans.
Before I wrote this message, I said to myself to hang on, it might be
just that Maven needs to download the required jars from the remote
repository, so I attempted to build the project to get these files.
So I built, and Maven returned the following error:
*
****** Start of output
[INFO]------------------------------------------------------------------
------
[ERROR]BUILD ERROR
[INFO]------------------------------------------------------------------
------
[INFO]Failed to resolve artifact.
Missing:
----------
1) org.codehaus.xfire:xfire-jaxws:jar:${xfire-version}
[INFO]
[INFO] Try downloading the file manually from the project website.
[INFO]
[INFO] Then, install it using the command:
[INFO] mvn install:install-file -DgroupId=org.codehaus.xfire
-DartifactId=xfire-jaxws \
-Dversion=${xfire-version} -Dpackaging=jar
-Dfile=/path/to/file
[INFO]
****** End of output
*
I assume that xfire-version is to be substituted somewhere, and this was
why, when I looked on http://mvnrepository.com/ without substituting any
intended value for this, I could not locate the jar. When I searched the
site again using just xfire-jaxws, I observed that 1.2.5 appeared the
most recent stable version.
Following the vervicemix-version declaration, I declared a property tag
in the POM called xfire-version, and assigned it 1.2.5 as its value.
This substituted correctly as I had deduced in the project tree in
NetBeans.
The $xfire-version should be 1.2.2 as shown in the red box on this page:
http://incubator.apache.org/servicemix/orchestration-with-jsr181.html
I also added the following dependency when I searched the Maven
repository for 'javax.jws':
<dependency>
<groupId>javax.jws</groupId>
<artifactId>jsr181</artifactId>
<version>1.0</version>
</dependency>
This should be defined a bit differently. There's an example in the
ServiceMix parent POM here:
https://svn.apache.org/repos/asf/incubator/servicemix/trunk/pom.xml
As shown in that POM, here is the dependency for the JAX-WS:
<dependency>
<groupId>javax.xml.ws</groupId>
<artifactId>jaxws-api</artifactId>
<version>2.0</version>
</dependency>
I'm showing you this version because the groupId and the version are
different that what you are using. Because I pulled this directly from
ServiceMix, I know it plays well with XFire 1.2.2.
After attempting another build, I received the following error and
instruction on how to remedy it:
*
****** Start of output
[INFO]------------------------------------------------------------------
------
[ERROR]BUILD ERROR
[INFO]------------------------------------------------------------------
------
[INFO]Failed to resolve artifact.
Missing:
----------
1) javax.jws:jsr181:jar:1.0
[INFO]
[INFO] Try downloading the file manually from:
[INFO] http://ftpna2.bea.com/pub/downloads/jwsri-1.0.zip
[INFO]
[INFO] Then, install it using the command:
[INFO] mvn install:install-file -DgroupId=javax.jws
-DartifactId=jsr181 \
-Dversion=1.0 -Dpackaging=jar -Dfile=/path/to/file
****** End of output
*
After following the instructions, I try to build again.
This time, I received the following error:
*
****** Start of output
[INFO]------------------------------------------------------------------
------
[ERROR]BUILD ERROR
[INFO]------------------------------------------------------------------
------
[INFO]Failed to generate jbi.xml
Embedded error: Unable to generate service unit descriptor!
<component-task-result
xmlns="http://java.sun.com/xml/ns/jbi/management-message">
<component-name>null</component-name>
<component-task-result-details>
<task-result-details>
<task-id>deploy</task-id>
<task-result>FAILED</task-result>
<message-type>ERROR</message-type>
<task-status-msg><msg-loc-info><loc-token/><loc-message>java.lang.Illega
lArgumentException: Invalid name
[]</loc-message></msg-loc-info></task-status-msg>
<exception-info>
<nesting-level>1</nesting-level>
<msg-loc-info>
<loc-token />
<loc-message>Invalid name
[]</loc-message>
<stack-trace><![CDATA[java.lang.IllegalArgumentException: Invalid name
I'm not quite sure what the error above indicates as it is generic.
The recommendation I can provide is to get the XFire and JAX-WS
versions sync'd up correctly before proceeding. Let's do this first
and see what is next.
Bruce
--
perl -e 'print unpack("u30","D0G)[EMAIL
PROTECTED]&5R\"F)R=6-E+G-N>61E<D\!G;6%I;\"YC;VT*"
);'
Apache Geronimo - http://geronimo.apache.org/
Apache ActiveMQ - http://activemq.org/
Apache ServiceMix - http://servicemix.org/
Castor - http://castor.org/