You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by Dmitry Beransky <dm...@gmail.com> on 2009/06/16 22:23:57 UTC

packaging xsds

Hi,

How can I tell maven to package autogenrated xsd files?  Below's my
current pom file.


Thanks
Dmitry

<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/maven-v4_0_0.xsd">
   <dependencies>
      <dependency>
         <groupId>org.apache.ws.commons.axiom</groupId>
         <artifactId>axiom-impl</artifactId>
         <scope>compile</scope>
      </dependency>
      <dependency>
         <groupId>org.apache.ws.commons.axiom</groupId>
         <artifactId>axiom-api</artifactId>
      </dependency>
        <dependency>
            <groupId>org.apache.xmlbeans</groupId>
            <artifactId>xmlbeans</artifactId>
        </dependency>
        <dependency>
            <groupId>org.apache.axis2</groupId>
            <artifactId>axis2</artifactId>
            <version>1.3</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>wsdl4j</groupId>
            <artifactId>wsdl4j</artifactId>
            <version>1.6.2</version>
            <scope>provided</scope>
        </dependency>
    </dependencies>

   <build>
      <defaultGoal>package</defaultGoal>
      <plugins>
         <plugin>
            <groupId>org.apache.axis2</groupId>
            <artifactId>axis2-wsdl2code-maven-plugin</artifactId>
            <version>1.3</version>
            <executions>
               <execution>
                  <goals>
                     <goal>wsdl2code</goal>
                  </goals>
               </execution>
            </executions>
            <configuration>
               <packageName>com.xxxxx</packageName>
               <namespaceURIs>
                  <namespaceURI>

<packageName>com.xxxxxx.esc.service.document.client</packageName>
                     <uri>http://www.xxxxx.com/esc/services/document</uri>
                  </namespaceURI>
               </namespaceURIs>
               <wsdlFile>../service/src/main/config/DocumentService.wsdl</wsdlFile>
               <databindingName>xmlbeans</databindingName>
            </configuration>
            <dependencies>
               <dependency>
                  <groupId>wsdl4j</groupId>
                  <artifactId>wsdl4j</artifactId>
                  <version>1.6.2</version>
               </dependency>
            </dependencies>
         </plugin>

         <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-source-plugin</artifactId>
            <executions>
               <execution>
                  <id>attach-sources</id>
                  <phase>package</phase>
                  <goals>
                     <goal>jar</goal>
                  </goals>
               </execution>
            </executions>
         </plugin>

         <plugin>
            <artifactId>maven-assembly-plugin</artifactId>
            <executions>
               <execution>
                  <id>archive-distribution</id>
                  <phase>package</phase>
                  <goals>
                     <goal>assembly</goal>
                  </goals>
               </execution>
            </executions>
            <configuration>
               <descriptors>
                  <descriptor>assembly/wsdl-client.xml</descriptor>
               </descriptors>
               <format>zip</format>
            </configuration>
         </plugin>
      </plugins>
   </build>
</project>