Advertisement
Javi

REST: Swagger Maven POM

Jan 27th, 2014
201
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
XML 5.48 KB | None | 0 0
  1. <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  2.         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
  3.     <modelVersion>4.0.0</modelVersion>
  4.  
  5.     <groupId>com.javiermoreno.rest</groupId>
  6.     <artifactId>07_banco_jersey_swagger</artifactId>
  7.     <version>0.0.1-SNAPSHOT</version>
  8.     <packaging>war</packaging>
  9.  
  10.     <name>05_banco_jersey_swagger</name>
  11.  
  12.     <properties>
  13.         <endorsed.dir>${project.build.directory}/endorsed</endorsed.dir>
  14.         <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
  15.     </properties>
  16.  
  17.     <dependencies>
  18.         <dependency>
  19.             <groupId>com.javiermoreno.rest</groupId>
  20.             <artifactId>02_banco_modelo</artifactId>
  21.             <version>0.0.2-SNAPSHOT</version>
  22.         </dependency>
  23.         <dependency>
  24.             <groupId>javax</groupId>
  25.             <artifactId>javaee-web-api</artifactId>
  26.             <version>6.0</version>
  27.             <scope>provided</scope>
  28.         </dependency>
  29.        
  30.         <dependency>
  31.             <groupId>javax.ws.rs</groupId>
  32.             <artifactId>javax.ws.rs-api</artifactId>
  33.             <version>2.0</version>
  34.         </dependency>
  35.            
  36.         <dependency>
  37.             <groupId>org.glassfish.jersey.containers</groupId>
  38.             <artifactId>jersey-container-servlet</artifactId>
  39.             <version>2.5.1</version>
  40.         </dependency>      
  41.        
  42.         <dependency>
  43.             <groupId>org.glassfish.jersey.media</groupId>
  44.             <artifactId>jersey-media-moxy</artifactId>
  45.             <version>2.5.1</version>
  46.         </dependency>        
  47.        
  48.        
  49.  
  50.  
  51.         <dependency>
  52.             <groupId>com.wordnik</groupId>
  53.             <artifactId>swagger-jaxrs_2.10</artifactId>
  54.             <version>1.3.1</version>
  55.             <scope>compile</scope>
  56.         </dependency>
  57.  
  58.  
  59.        
  60.     </dependencies>
  61.  
  62.     <build>
  63.         <plugins>
  64.             <plugin>
  65.                 <groupId>org.apache.maven.plugins</groupId>
  66.                 <artifactId>maven-compiler-plugin</artifactId>
  67.                 <version>2.3.2</version>
  68.                 <configuration>
  69.                     <source>1.6</source>
  70.                     <target>1.6</target>
  71.                     <compilerArguments>
  72.                         <endorseddirs>${endorsed.dir}</endorseddirs>
  73.                     </compilerArguments>
  74.                 </configuration>
  75.             </plugin>
  76.             <plugin>
  77.                 <groupId>org.apache.maven.plugins</groupId>
  78.                 <artifactId>maven-war-plugin</artifactId>
  79.                 <version>2.1.1</version>
  80.                 <configuration>
  81.                     <failOnMissingWebXml>false</failOnMissingWebXml>
  82.                 </configuration>
  83.             </plugin>
  84.             <plugin>
  85.                 <groupId>org.apache.maven.plugins</groupId>
  86.                 <artifactId>maven-dependency-plugin</artifactId>
  87.                 <version>2.1</version>
  88.                 <executions>
  89.                     <execution>
  90.                         <phase>validate</phase>
  91.                         <goals>
  92.                             <goal>copy</goal>
  93.                         </goals>
  94.                         <configuration>
  95.                             <outputDirectory>${endorsed.dir}</outputDirectory>
  96.                             <silent>true</silent>
  97.                             <artifactItems>
  98.                                 <artifactItem>
  99.                                     <groupId>javax</groupId>
  100.                                     <artifactId>javaee-endorsed-api</artifactId>
  101.                                     <version>6.0</version>
  102.                                     <type>jar</type>
  103.                                 </artifactItem>
  104.                             </artifactItems>
  105.                         </configuration>
  106.                     </execution>
  107.                 </executions>
  108.             </plugin>
  109.            
  110.             <!-- Resultado tras build en 07_banco_jersey_swagger\target\classes\apidocs -->
  111.             <plugin>
  112.                 <groupId>org.apache.maven.plugins</groupId>
  113.                 <artifactId>maven-javadoc-plugin</artifactId>
  114.                 <version>2.9.1</version>
  115.                 <executions>
  116.                     <execution>
  117.                         <id>generate-service-docs</id>
  118.                         <phase>generate-resources</phase>
  119.                         <configuration>
  120.                             <doclet>com.hypnoticocelot.jaxrs.doclet.ServiceDoclet</doclet>
  121.                             <docletArtifact>
  122.                                 <groupId>com.hypnoticocelot</groupId>
  123.                                 <artifactId>jaxrs-doclet</artifactId>
  124.                                 <version>0.0.2</version>
  125.                             </docletArtifact>
  126.                             <reportOutputDirectory>${project.build.outputDirectory}</reportOutputDirectory>
  127.                             <useStandardDocletOptions>false</useStandardDocletOptions>
  128.                             <additionalparam>-apiVersion 1 -docBasePath /apidocs -apiBasePath /</additionalparam>
  129.                         </configuration>
  130.                         <goals>
  131.                             <goal>javadoc</goal>
  132.                         </goals>
  133.                     </execution>
  134.                 </executions>
  135.             </plugin>            
  136.            
  137.            
  138.         </plugins>
  139.     </build>
  140.  
  141. </project>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement