Cherry
Cherry

Reputation: 33554

How generate wsdl or/and client source from class with Spring @Endpoint by maven plugin?

There is jasws-maven-plugin which can be used to generate wsdl or/and client code from classes with @javax.jws.Webservice annotation. Is there plugin which can generate wsdl or/and client code from classes with spring @Endpoint (org.springframework.ws.server.endpoint.annotation.Endpoint) annotation?

Important

I know that there is org.springframework.ws.wsdl.wsdl11.DefaultWsdl11Definition bean that scans classes with @Endpoint and generate wsdl. But this generation occurs in runtime! And I want to generate on compile time with maven plugin, without packaging web application and going to the some url.

Upvotes: 0

Views: 739

Answers (1)

constantlearner
constantlearner

Reputation: 5247

You can use wsgen to generate the wsdl.

From the example in the documentation

wsgen -wsdl -d stock -cp myclasspath stock.StockService This will generate the wsdl and schema files in the "stock" directory.

There is also a wsgen Ant task.

Upvotes: 0

Related Questions