Skip to content

Commit

Permalink
Added indexer to Spring sample for #131.
Browse files Browse the repository at this point in the history
  • Loading branch information
sapessi committed Apr 5, 2018
1 parent f1ccaaa commit 5c3c73d
Showing 1 changed file with 58 additions and 8 deletions.
66 changes: 58 additions & 8 deletions samples/spring/pet-store/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
<spring.version>5.0.3.RELEASE</spring.version>
<junit.version>4.12</junit.version>
<log4j.version>2.8.2</log4j.version>
</properties>

<dependencies>
Expand All @@ -42,7 +44,6 @@
<version>1.2.0</version>
</dependency>

<!-- https://mvnrepository.com/artifact/org.springframework/spring-webmvc -->
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-webmvc</artifactId>
Expand All @@ -55,11 +56,48 @@
<version>${spring.version}</version>
</dependency>

<!-- https://mvnrepository.com/artifact/io.symphonia/lambda-logging -->
<!--
the Spring Context Indexer run an annotation processor at compile time and generates
a META-INF/spring.components file that Spring can use to speed up component scanning at boot time.
For small applications, this doesn't make a big difference. However, for large applications with
complex dependencies this may improve your cold start time significantly.
-->
<dependency>
<groupId>io.symphonia</groupId>
<artifactId>lambda-logging</artifactId>
<version>1.0.1</version>
<groupId>org.springframework</groupId>
<artifactId>spring-context-indexer</artifactId>
<version>${spring.version}</version>
<optional>true</optional>
</dependency>

<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-core</artifactId>
<version>${log4j.version}</version>
</dependency>

<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-api</artifactId>
<version>${log4j.version}</version>
</dependency>

<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-slf4j-impl</artifactId>
<version>${log4j.version}</version>
</dependency>

<dependency>
<groupId>com.amazonaws</groupId>
<artifactId>aws-lambda-java-log4j2</artifactId>
<version>1.1.0</version>
</dependency>

<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>${junit.version}</version>
<scope>test</scope>
</dependency>
</dependencies>

Expand All @@ -69,17 +107,29 @@
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<version>2.3</version>
<configuration>
<createDependencyReducedPom>false</createDependencyReducedPom>
</configuration>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>shade</goal>
</goals>
<configuration>
<createDependencyReducedPom>false</createDependencyReducedPom>
<transformers>
<transformer
implementation="com.github.edwgiz.mavenShadePlugin.log4j2CacheTransformer.PluginsCacheFileTransformer">
</transformer>
</transformers>
</configuration>
</execution>
</executions>
<dependencies>
<dependency>
<groupId>com.github.edwgiz</groupId>
<artifactId>maven-shade-plugin.log4j2-cachefile-transformer</artifactId>
<version>2.8.1</version>
</dependency>
</dependencies>
</plugin>
</plugins>
</build>
Expand Down

0 comments on commit 5c3c73d

Please sign in to comment.