Skip to content
This repository has been archived by the owner on Feb 7, 2018. It is now read-only.

Commit

Permalink
Incorporating Pull Request #19 to fix stale sessions from overwriting…
Browse files Browse the repository at this point in the history
… active sessions.
  • Loading branch information
shorea committed Apr 2, 2015
1 parent e9214bc commit ff0d48b
Show file tree
Hide file tree
Showing 25 changed files with 1,792 additions and 535 deletions.
288 changes: 158 additions & 130 deletions pom.xml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
<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 https://maven.apache.org/maven-v4_0_0.xsd">
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.amazonaws</groupId>
<artifactId>aws-dynamodb-session-tomcat</artifactId>
<packaging>jar</packaging>
<name>Amazon DynamoDB Session Manager for Tomcat</name>
<version>1.2</version>
<version>1.0.5</version>
<description>The Amazon DynamoDB Session Manager for Tomcat provides a custom session manager for Tomcat 7 that stores session data in Amazon DynamoDB, Amazon's fully managed NoSQL database service.</description>
<url>https://aws.amazon.com/java</url>

Expand Down Expand Up @@ -34,145 +34,173 @@
</developers>

<dependencies>
<dependency>
<groupId>com.amazonaws</groupId>
<artifactId>aws-java-sdk</artifactId>
<version>1.5.4</version>
</dependency>
<dependency>
<groupId>org.apache.tomcat</groupId>
<artifactId>tomcat-catalina</artifactId>
<version>7.0.47</version>
</dependency>
<dependency>
<groupId>com.amazonaws</groupId>
<artifactId>aws-java-sdk-dynamodb</artifactId>
<version>1.9.23</version>
</dependency>
<dependency>
<groupId>org.apache.tomcat</groupId>
<artifactId>tomcat-catalina</artifactId>
<version>7.0.42</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-core</artifactId>
<version>1.10.19</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.12</version>
<scope>test</scope>
</dependency>
</dependencies>

<build>
<resources>
<resource>
<directory>${basedir}</directory>
<includes>
<include>LICENSE.txt</include>
<include>NOTICE.txt</include>
<include>README.txt</include>
</includes>
</resource>
</resources>
<resources>
<resource>
<directory>${basedir}</directory>
<includes>
<include>LICENSE.txt</include>
<include>NOTICE.txt</include>
<include>README.md</include>
</includes>
</resource>
</resources>

<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.3</version>
<configuration>
<source>1.7</source>
<target>1.7</target>
<encoding>UTF-8</encoding>
</configuration>
</plugin>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.3</version>
<configuration>
<source>1.6</source>
<target>1.6</target>
<encoding>UTF-8</encoding>
</configuration>
</plugin>

<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<version>2.2</version>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>shade</goal>
</goals>
<configuration>
<minimizeJar>true</minimizeJar>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<version>2.2</version>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>shade</goal>
</goals>
<configuration>
<transformers>
<transformer implementation="org.apache.maven.plugins.shade.resource.ApacheLicenseResourceTransformer" />
<transformer implementation="org.apache.maven.plugins.shade.resource.ApacheNoticeResourceTransformer">
<addHeader>false</addHeader>
</transformer>
</transformers>
<minimizeJar>true</minimizeJar>

<relocations>
<relocation>
<pattern>com.amazonaws</pattern>
<shadedPattern>com.amazonaws.tomcatsessionmanager.amazonaws</shadedPattern>
<excludes>
<!-- Don't shade this class, since we reference it by name in Tomcat configuration -->
<exclude>com.amazonaws.services.dynamodb.sessionmanager.DynamoDBSessionManager</exclude>
</excludes>
</relocation>
<relocation>
<pattern>org.apache.http</pattern>
<shadedPattern>com.amazonaws.tomcatsessionmanager.apache.http</shadedPattern>
</relocation>
<relocation>
<pattern>org.apache.commons.logging</pattern>
<shadedPattern>com.amazonaws.tomcatsessionmanager.apache.commons.logging</shadedPattern>
</relocation>
<relocation>
<pattern>org.apache.commons.codec</pattern>
<shadedPattern>com.amazonaws.tomcatsessionmanager.apache.commons.codec</shadedPattern>
</relocation>
<!-- TODO: This needs to be updated to the new Jackson version when we update to a later SDK version -->
<relocation>
<pattern>org.codehaus</pattern>
<shadedPattern>com.amazonaws.tomcatsessionmanager.codehaus</shadedPattern>
</relocation>
</relocations>

<artifactSet>
<includes>
<include>com.amazonaws:aws-java-sdk</include>
<include>commons-logging:*</include>
<include>org.apache.httpcomponents:*</include>
<include>commons-codec:*</include>
<include>org.codehaus.jackson:*</include>
</includes>
</artifactSet>
<relocations>
<relocation>
<pattern>com.amazonaws</pattern>
<shadedPattern>com.amazonaws.tomcatsessionmanager.amazonaws</shadedPattern>
<excludes>
<!-- Don't shade this class, since we reference it by name in Tomcat configuration -->
<exclude>com.amazonaws.services.dynamodb.sessionmanager.DynamoDBSessionManager</exclude>
</excludes>
</relocation>
<relocation>
<pattern>org.apache.http</pattern>
<shadedPattern>com.amazonaws.tomcatsessionmanager.apache.http</shadedPattern>
</relocation>
<relocation>
<pattern>org.apache.commons.logging</pattern>
<shadedPattern>com.amazonaws.tomcatsessionmanager.apache.commons.logging</shadedPattern>
</relocation>
<relocation>
<pattern>org.apache.commons.codec</pattern>
<shadedPattern>com.amazonaws.tomcatsessionmanager.apache.commons.codec</shadedPattern>
</relocation>
<relocation>
<pattern>com.fasterxml</pattern>
<shadedPattern>com.amazonaws.tomcatsessionmanager.fasterxml</shadedPattern>
</relocation>
<relocation>
<pattern>org.joda.time</pattern>
<shadedPattern>com.amazonaws.tomcatsessionmanager.joda.time</shadedPattern>
</relocation>
</relocations>

<filters>
<filter>
<!-- Pull in everything from commons-logging, so that we pick up all the adapter
implementations that may not be statically referenced, but could be needed. -->
<artifact>commons-logging:commons-logging</artifact>
<includes>
<include>**</include>
</includes>
</filter>
</filters>
<artifactSet>
<includes>
<include>com.amazonaws:aws-java-sdk*</include>
<include>commons-logging:*</include>
<include>org.apache.httpcomponents:*</include>
<include>commons-codec:*</include>
<include>com.fasterxml.jackson.core:*</include>
<include>joda-time:*</include>
</includes>
</artifactSet>

</configuration>
</execution>
</executions>
</plugin>
</plugins>
<filters>
<filter>
<!-- Pull in everything from commons-logging, so that we pick up all the adapter
implementations that may not be statically referenced, but could be needed. -->
<artifact>commons-logging:commons-logging</artifact>
<includes>
<include>**</include>
</includes>
</filter>
<filter>
<artifact>com.fasterxml.jackson.core:*</artifact>
<includes>
<include>**</include>
</includes>
</filter>
</filters>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>

<profiles>
<profile>
<id>publishing</id>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-gpg-plugin</artifactId>
<executions>
<execution>
<id>sign-artifacts</id>
<phase>verify</phase>
<goals>
<goal>sign</goal>
</goals>
</execution>
</executions>
</plugin>
<profile>
<id>publishing</id>

<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-gpg-plugin</artifactId>
<executions>
<execution>
<id>sign-artifacts</id>
<phase>verify</phase>
<goals>
<goal>sign</goal>
</goals>
</execution>
</executions>
</plugin>

<plugin>
<groupId>org.sonatype.plugins</groupId>
<artifactId>nexus-staging-maven-plugin</artifactId>
<version>1.5.1</version>
<extensions>true</extensions>
<configuration>
<serverId>sonatype-nexus-staging</serverId>
<nexusUrl>https://oss.sonatype.org</nexusUrl>
<releaseAfterClose>true</releaseAfterClose>
</configuration>
</plugin>
</plugins>
</build>
</profile>
<plugin>
<groupId>org.sonatype.plugins</groupId>
<artifactId>nexus-staging-maven-plugin</artifactId>
<version>1.5.1</version>
<extensions>true</extensions>
<configuration>
<serverId>sonatype-nexus-staging</serverId>
<nexusUrl>https://oss.sonatype.org</nexusUrl>
<releaseAfterClose>true</releaseAfterClose>
</configuration>
</plugin>
</plugins>
</build>
</profile>
</profiles>

</project>
Loading

0 comments on commit ff0d48b

Please sign in to comment.