You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cxf.apache.org by Joel Turkel <jt...@Endeca.com> on 2007/06/19 19:26:20 UTC

Maven Java2WSDL Plugin

Hi,

 

I'm trying to use the latest snapshot of the Maven codegen plugin to
generate WSDL from a JAX-WS annotated class and I'm getting the
following error: "Can not find the ServiceBulider for style: Jaxws".
Here's the plugin configuration from my pom.xml:

 

<plugin>

            <groupId>org.apache.cxf</groupId>

            <artifactId>cxf-codegen-plugin</artifactId>

            <version>2.0-incubator-SNAPSHOT</version>

            <executions>

                        <execution>

                                    <id>generate-wsdl</id>

                                    <phase>process-classes</phase>

                                    <configuration>

                                                <className>

 
com.endeca.service.MyService

                                                </className>


                                    </configuration>

                                    <goals>

                                                <goal>java2wsdl</goal>

                                    </goals>

                        </execution>

            </executions>

</plugin>  

 

Perhaps the codegen plugin is missing the dependency to
cxf-rt-frontend-jaxws ?

 

Thanks,

Joel

 

Principal Software Engineer

Endeca Technologies


Re: Maven Java2WSDL Plugin

Posted by James Mao <ja...@iona.com>.
One thing that i would like to mention, is that why the java2wsdl 
looking for the jaxws frontend,
It's that the MyService is annotated with the jaxws annotation, so the 
tool detected it should use the jaxws frontend to generate the wsdl.

If you feed a plain java class without any annotations, then the tool 
will automatically detect it's a simple frontend,
in that case, the jaxws dependency is not required, you can change it to 
the rt-simple frontend.

We should add an option to mandate which frontend to use(overwrite the 
default behavior), it will be the next release.

James

> Thanks James. Adding that dependency to the plugin configuration did the
> trick i.e.
>
> <build>
>    <plugins>         
>          <plugin>
>          <groupId>org.apache.cxf</groupId>
>          <artifactId>cxf-codegen-plugin</artifactId>
>          <version>${cxfVersion}</version>
>          <dependencies>
>             <dependency>
>                <groupId>org.apache.cxf</groupId>
>                <artifactId>cxf-rt-frontend-jaxws</artifactId>
>                <version>${cxfVersion}</version>
>             </dependency>
>          </dependencies>
>          <executions>
>             <execution>
>                <id>generate-wsdl</id>
>                <phase>process-classes</phase>
>                <configuration>
>                   <className>
>                      com.endeca.service.MyService
>                   </className>
>                </configuration>
>                <goals>
>                   <goal>java2wsdl</goal>
>                </goals>
>             </execution>
>          </executions>
>       </plugin>
>    </plugins>
> </build>
>
> -Joel
>
> -----Original Message-----
> From: James Mao [mailto:james.mao@iona.com] 
> Sent: Wednesday, June 20, 2007 2:18 AM
> To: cxf-user@incubator.apache.org
> Subject: Re: Maven Java2WSDL Plugin
>
> Forgot to tell you the reason,
>
> We treat the frontend as a plugin in java2wsdl codegen-plugin now, so 
> you have to put those dependencies in your pom.
>
> The benefit of this mechanism is that java2wsdl is like a framework,
> later if someone implement the jax-rpc , or some other front-ends, just 
> put the artifact in your class-path, we don't need to change the tool 
> itself.
>
> James
>
>   
>> It require the rt-jaxws frontend, and also need the rt-simple
>>     
> frontend.
>   
>> James
>>
>>
>> Joel Turkel wrote:
>>     
>>> Hi,
>>>
>>>  
>>>
>>> I'm trying to use the latest snapshot of the Maven codegen plugin to
>>> generate WSDL from a JAX-WS annotated class and I'm getting the
>>> following error: "Can not find the ServiceBulider for style: Jaxws".
>>> Here's the plugin configuration from my pom.xml:
>>>
>>>  
>>>
>>> <plugin>
>>>
>>>             <groupId>org.apache.cxf</groupId>
>>>
>>>             <artifactId>cxf-codegen-plugin</artifactId>
>>>
>>>             <version>2.0-incubator-SNAPSHOT</version>
>>>
>>>             <executions>
>>>
>>>                         <execution>
>>>
>>>                                     <id>generate-wsdl</id>
>>>
>>>                                     <phase>process-classes</phase>
>>>
>>>                                     <configuration>
>>>
>>>                                                 <className>
>>>
>>>  
>>> com.endeca.service.MyService
>>>
>>>                                                 </className>
>>>
>>>
>>>                                     </configuration>
>>>
>>>                                     <goals>
>>>
>>>
>>>       
> <goal>java2wsdl</goal>
>   
>>>                                     </goals>
>>>
>>>                         </execution>
>>>
>>>             </executions>
>>>
>>> </plugin> 
>>>  
>>>
>>> Perhaps the codegen plugin is missing the dependency to
>>> cxf-rt-frontend-jaxws ?
>>>
>>>  
>>>
>>> Thanks,
>>>
>>> Joel
>>>
>>>  
>>>
>>> Principal Software Engineer
>>>
>>> Endeca Technologies
>>>
>>>
>>>   
>>>       
>
>   

RE: Maven Java2WSDL Plugin

Posted by Joel Turkel <jt...@Endeca.com>.
Thanks James. Adding that dependency to the plugin configuration did the
trick i.e.

<build>
   <plugins>         
         <plugin>
         <groupId>org.apache.cxf</groupId>
         <artifactId>cxf-codegen-plugin</artifactId>
         <version>${cxfVersion}</version>
         <dependencies>
            <dependency>
               <groupId>org.apache.cxf</groupId>
               <artifactId>cxf-rt-frontend-jaxws</artifactId>
               <version>${cxfVersion}</version>
            </dependency>
         </dependencies>
         <executions>
            <execution>
               <id>generate-wsdl</id>
               <phase>process-classes</phase>
               <configuration>
                  <className>
                     com.endeca.service.MyService
                  </className>
               </configuration>
               <goals>
                  <goal>java2wsdl</goal>
               </goals>
            </execution>
         </executions>
      </plugin>
   </plugins>
</build>

-Joel

-----Original Message-----
From: James Mao [mailto:james.mao@iona.com] 
Sent: Wednesday, June 20, 2007 2:18 AM
To: cxf-user@incubator.apache.org
Subject: Re: Maven Java2WSDL Plugin

Forgot to tell you the reason,

We treat the frontend as a plugin in java2wsdl codegen-plugin now, so 
you have to put those dependencies in your pom.

The benefit of this mechanism is that java2wsdl is like a framework,
later if someone implement the jax-rpc , or some other front-ends, just 
put the artifact in your class-path, we don't need to change the tool 
itself.

James

> It require the rt-jaxws frontend, and also need the rt-simple
frontend.
>
>
> James
>
>
> Joel Turkel wrote:
>> Hi,
>>
>>  
>>
>> I'm trying to use the latest snapshot of the Maven codegen plugin to
>> generate WSDL from a JAX-WS annotated class and I'm getting the
>> following error: "Can not find the ServiceBulider for style: Jaxws".
>> Here's the plugin configuration from my pom.xml:
>>
>>  
>>
>> <plugin>
>>
>>             <groupId>org.apache.cxf</groupId>
>>
>>             <artifactId>cxf-codegen-plugin</artifactId>
>>
>>             <version>2.0-incubator-SNAPSHOT</version>
>>
>>             <executions>
>>
>>                         <execution>
>>
>>                                     <id>generate-wsdl</id>
>>
>>                                     <phase>process-classes</phase>
>>
>>                                     <configuration>
>>
>>                                                 <className>
>>
>>  
>> com.endeca.service.MyService
>>
>>                                                 </className>
>>
>>
>>                                     </configuration>
>>
>>                                     <goals>
>>
>>
<goal>java2wsdl</goal>
>>
>>                                     </goals>
>>
>>                         </execution>
>>
>>             </executions>
>>
>> </plugin> 
>>  
>>
>> Perhaps the codegen plugin is missing the dependency to
>> cxf-rt-frontend-jaxws ?
>>
>>  
>>
>> Thanks,
>>
>> Joel
>>
>>  
>>
>> Principal Software Engineer
>>
>> Endeca Technologies
>>
>>
>>   
>

Re: Maven Java2WSDL Plugin

Posted by James Mao <ja...@iona.com>.
Forgot to tell you the reason,

We treat the frontend as a plugin in java2wsdl codegen-plugin now, so 
you have to put those dependencies in your pom.

The benefit of this mechanism is that java2wsdl is like a framework,
later if someone implement the jax-rpc , or some other front-ends, just 
put the artifact in your class-path, we don't need to change the tool 
itself.

James

> It require the rt-jaxws frontend, and also need the rt-simple frontend.
>
>
> James
>
>
> Joel Turkel wrote:
>> Hi,
>>
>>  
>>
>> I'm trying to use the latest snapshot of the Maven codegen plugin to
>> generate WSDL from a JAX-WS annotated class and I'm getting the
>> following error: "Can not find the ServiceBulider for style: Jaxws".
>> Here's the plugin configuration from my pom.xml:
>>
>>  
>>
>> <plugin>
>>
>>             <groupId>org.apache.cxf</groupId>
>>
>>             <artifactId>cxf-codegen-plugin</artifactId>
>>
>>             <version>2.0-incubator-SNAPSHOT</version>
>>
>>             <executions>
>>
>>                         <execution>
>>
>>                                     <id>generate-wsdl</id>
>>
>>                                     <phase>process-classes</phase>
>>
>>                                     <configuration>
>>
>>                                                 <className>
>>
>>  
>> com.endeca.service.MyService
>>
>>                                                 </className>
>>
>>
>>                                     </configuration>
>>
>>                                     <goals>
>>
>>                                                 <goal>java2wsdl</goal>
>>
>>                                     </goals>
>>
>>                         </execution>
>>
>>             </executions>
>>
>> </plugin> 
>>  
>>
>> Perhaps the codegen plugin is missing the dependency to
>> cxf-rt-frontend-jaxws ?
>>
>>  
>>
>> Thanks,
>>
>> Joel
>>
>>  
>>
>> Principal Software Engineer
>>
>> Endeca Technologies
>>
>>
>>   
>

Re: Maven Java2WSDL Plugin

Posted by James Mao <ja...@iona.com>.
It require the rt-jaxws frontend, and also need the rt-simple frontend.


James


Joel Turkel wrote:
> Hi,
>
>  
>
> I'm trying to use the latest snapshot of the Maven codegen plugin to
> generate WSDL from a JAX-WS annotated class and I'm getting the
> following error: "Can not find the ServiceBulider for style: Jaxws".
> Here's the plugin configuration from my pom.xml:
>
>  
>
> <plugin>
>
>             <groupId>org.apache.cxf</groupId>
>
>             <artifactId>cxf-codegen-plugin</artifactId>
>
>             <version>2.0-incubator-SNAPSHOT</version>
>
>             <executions>
>
>                         <execution>
>
>                                     <id>generate-wsdl</id>
>
>                                     <phase>process-classes</phase>
>
>                                     <configuration>
>
>                                                 <className>
>
>  
> com.endeca.service.MyService
>
>                                                 </className>
>
>
>                                     </configuration>
>
>                                     <goals>
>
>                                                 <goal>java2wsdl</goal>
>
>                                     </goals>
>
>                         </execution>
>
>             </executions>
>
> </plugin>  
>
>  
>
> Perhaps the codegen plugin is missing the dependency to
> cxf-rt-frontend-jaxws ?
>
>  
>
> Thanks,
>
> Joel
>
>  
>
> Principal Software Engineer
>
> Endeca Technologies
>
>
>