SV: Wsdl2java code generation

2009-03-04 Thread Daniel.Q.Pfeifer
Well, I had the same problem, check out my blog: 
http://www.mindbug.org/2009/02/adding-endorsements-to-mavens-plugins.html


-Ursprungligt meddelande-
Från: Vishal Pahwa [mailto:vpa...@sapient.com] 
Skickat: den 4 mars 2009 14:14
Till: Maven Users List
Ämne: RE: Wsdl2java code generation


Hi

If I use the plugin u asked to use then m getting the following error, don't 
know what is this endorsed directory mechanism:(


[INFO] 
[INFO] JAXB 2.0 API is being loaded from the bootstrap classloader, but this RI
(from jar:file:/C:/Documents and Settings/vpahwa/.m2/repository/com/sun/xml/bind
/jaxb-impl/2.1.7/jaxb-impl-2.1.7.jar!/com/sun/xml/bind/v2/model/impl/ModelBuilde
r.class) needs 2.1 API. Use the endorsed directory mechanism to place jaxb-api.j
ar in the bootstrap classloader. (See http://java.sun.com/j2se/1.5.0/docs/guide/
standards/) 


Regards

Vishal

-Original Message-
From: Tobias Gierke [mailto:tobias.gie...@code-sourcery.de] 
Sent: Wednesday, March 04, 2009 5:34 PM
To: Maven Users List
Subject: Re: Wsdl2java code generation

Hi Vishal
> Hi
>
> Following is the declaration for the two pluging:
>
>
> 1:
>
>
> 
>   org.apache.cxf
>   cxf-codegen-plugin
>   2.0.6
>   
I just had a look at my pom.xml that is working correctly. I'm actually
using a later plugin version  (2.1.2) than you ... did you try using
this one ?


Regards,

Tobi

P.S. Here's my plugin declaration:

  
org.apache.cxf
cxf-codegen-plugin
2.1.2

  
generate-sources
generate-sources

 
${basedir}/target/generated/src/main/java
  

 
${basedir}/src/main/wsdl/serviceOLD20080411.wsdl
  
-p
my.fancy.client.package
-b
   
${basedir}/src/main/wsdl/jaxb_binding.xml
  

  


  wsdl2java

  

  




> Regards
>
> Vishal
>
> -Original Message-
> From: Tobias Gierke [mailto:t...@code-sourcery.de] 
> Sent: Wednesday, March 04, 2009 2:23 PM
> To: Maven Users List
> Subject: Re: Wsdl2java code generation
>
> Hi Vishal,
>   
>> Maven of "Maven" build technology,
>> Greetings !!
>>
>> I need some help with the maven plugin to generate code from wsdl file.
>> If you have tried the same earlier please email me separately.
>>
>> What has been tried:
>>
>> Option 1
>> "wsdl2java" plugin (CXF WSDL-to-Java code generation)
>> This generates the code from wsdl file but the java files it generates are 
>> not proper. For instance, the java files (VO) are not implementing 
>> Serializable interface, and other classes which needs to implement Remote 
>> interface are not doing so, etc. Thus we are not able to use the java code 
>> which this plugin generates.
>>
>> Option 2
>> "wsdl2code" plugin (axis2-wsdl2code-maven-plugin)
>> The java classes generated by this plugin does not create the correct 
>> package structure, thus compilation fails.
>>   
>> 
> Could you post the  declarations you used ? Is there anything 
> special about the WSDL you're using ? Last year I used a (now definitely 
> outdated) version of the CXF plugin to generate code from a 
> document/literal WSDL and didn't notice any broken generated code. I 
> first tried to use axis2 as well but wasn't even able to get the plugin 
> up and running (maybe my fault but I remember the documentation being 
> kind of  ...uhm...lacking).
>
> Regards,
>
> Tobias
>   
>> What we want?
>> 1) Any pointers around any argument or property etc which can be set so as 
>> to properly generate the java files using wsdl2java.
>> 2) Pointers to generate the correct package structure for java files using 
>> wsdl2code.
>>
>> Please let me know in case you require more information.
>>
>> Regards,
>> Vishal
>>
>>
>>
>>   
>> 
>
>
> -
> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> For additional commands, e-mail: users-h...@maven.apache.org
>
>
> -
> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> For additional commands, e-mail: users-h...@maven.apache.org
>
>
>   


-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org


-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



SV: Wsdl2java code generation

2009-03-04 Thread Daniel.Q.Pfeifer
The wsconsume ant task could be used with the maven-antrun-plugin! In my case I 
am using JBossWS and I simply use the task found in the jbossws-spi.jar, i.e.


maven-antrun-plugin


generatewsdlsources
generate-sources

run




http://localhost:8080/myWs?wsdl";
wsdl="${basedir}/src/main/config/my.wsdl" />





/Daniel

-Ursprungligt meddelande-
Från: Vishal Pahwa [mailto:vpa...@sapient.com] 
Skickat: den 4 mars 2009 05:57
Till: Maven Users List
Ämne: Wsdl2java code generation

Maven of "Maven" build technology,
Greetings !!

I need some help with the maven plugin to generate code from wsdl file.
If you have tried the same earlier please email me separately.

What has been tried:

Option 1
"wsdl2java" plugin (CXF WSDL-to-Java code generation)
This generates the code from wsdl file but the java files it generates are not 
proper. For instance, the java files (VO) are not implementing Serializable 
interface, and other classes which needs to implement Remote interface are not 
doing so, etc. Thus we are not able to use the java code which this plugin 
generates.

Option 2
"wsdl2code" plugin (axis2-wsdl2code-maven-plugin)
The java classes generated by this plugin does not create the correct package 
structure, thus compilation fails.

What we want?
1) Any pointers around any argument or property etc which can be set so as to 
properly generate the java files using wsdl2java.
2) Pointers to generate the correct package structure for java files using 
wsdl2code.

Please let me know in case you require more information.

Regards,
Vishal



-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



SV: "mvn site" triggers generate-sources

2009-03-04 Thread Daniel.Q.Pfeifer
Naturally... I had a hunch that it would be like that... Thanks a bunch for 
your help.

-Ursprungligt meddelande-
Från: Wayne Fay [mailto:wayne...@gmail.com] 
Skickat: den 3 mars 2009 19:46
Till: Maven Users List
Ämne: Re: "mvn site" triggers generate-sources

> That works just fine, the problem is, the very same phase is executed
> when I do generate the Project Site using "mvn site". Thus, the task
> bound to "generate-sources" is triggered several times for every site
> thats built.

My best guess without seeing your poms and knowing more about your
project is that you are probably using some plugins (PMD, etc) that
want to use/analyze the source code to include a report in the
generation of the site, and they are causing generate-sources to be
executed.

Wayne

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org


-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



"mvn site" triggers generate-sources

2009-03-03 Thread Daniel.Q.Pfeifer
Hi,

I was wondering if any of you guys encountered the same problem.

I am generating some source code using an ANT Task, the task is
triggered when the Maven lifecycle reaches the "generate-sources" phase.

That works just fine, the problem is, the very same phase is executed
when I do generate the Project Site using "mvn site". Thus, the task
bound to "generate-sources" is triggered several times for every site
thats built.

Any smart ideas, because I don't seem to find the solution to this.

Thanks in advance,
/Daniel

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org