tomcat-cache-realm

A caching Tomcat realm

License

License

Categories

Categories

Tomcat Container Application Servers Realm Data Databases
GroupId

GroupId

com.s24.tomcat
ArtifactId

ArtifactId

tomcat-cache-realm
Last Version

Last Version

0.1.0
Release Date

Release Date

Type

Type

jar
Description

Description

tomcat-cache-realm
A caching Tomcat realm
Project URL

Project URL

https://github.com/shopping24/tomcat-cache-realm
Project Organization

Project Organization

Shopping24 GmbH
Source Code Management

Source Code Management

https://github.com/shopping24/tomcat-cache-realm

Download tomcat-cache-realm

How to add to project

<!-- https://jarcasting.com/artifacts/com.s24.tomcat/tomcat-cache-realm/ -->
<dependency>
    <groupId>com.s24.tomcat</groupId>
    <artifactId>tomcat-cache-realm</artifactId>
    <version>0.1.0</version>
</dependency>
// https://jarcasting.com/artifacts/com.s24.tomcat/tomcat-cache-realm/
implementation 'com.s24.tomcat:tomcat-cache-realm:0.1.0'
// https://jarcasting.com/artifacts/com.s24.tomcat/tomcat-cache-realm/
implementation ("com.s24.tomcat:tomcat-cache-realm:0.1.0")
'com.s24.tomcat:tomcat-cache-realm:jar:0.1.0'
<dependency org="com.s24.tomcat" name="tomcat-cache-realm" rev="0.1.0">
  <artifact name="tomcat-cache-realm" type="jar" />
</dependency>
@Grapes(
@Grab(group='com.s24.tomcat', module='tomcat-cache-realm', version='0.1.0')
)
libraryDependencies += "com.s24.tomcat" % "tomcat-cache-realm" % "0.1.0"
[com.s24.tomcat/tomcat-cache-realm "0.1.0"]

Dependencies

compile (2)

Group / Artifact Type Version
org.apache.tomcat : tomcat-catalina jar 7.0.67
com.google.guava : guava jar 19.0

Project Modules

There are no modules declared in this project.

Tomcat CachingRealm

travis-ci

This projects adds a cache to your authentication Realm in Tomcat. In high-throughput environments it might be a good idea to cache the underlying authentication infrastructure (LDAP/JDBC).

Use this project

Download the project from Maven Central and drop the jar-with-dependencies into your Tomcat /lib folder. Then wrap your existing authentication realm(s) with the caching realm (in your server.xml or context.xml):

<Realm className="com.s24.tomcat.CachingRealm">
   <Realm className="org.apache.catalina.realm.JNDIRealm" 
       connectionURL="..."
</Realm>

By default, successful authentications are cached for 5 minutes. Use the cacheSettings property to supply Google Guava cache builder specs to configure cache size and retention time.

Building the project

This should install the current version into your local repository

$ mvn clean verify

Releasing the project to maven central

Define new versions

$ export NEXT_VERSION=<version>
$ export NEXT_DEVELOPMENT_VERSION=<version>-SNAPSHOT

Then execute the release chain

$ mvn org.codehaus.mojo:versions-maven-plugin:2.0:set -DgenerateBackupPoms=false -DnewVersion=$NEXT_VERSION
$ git commit -a -m "pushes to release version $NEXT_VERSION"
$ mvn -P release

Then, increment to next development version:

$ git tag -a v$NEXT_VERSION -m "`curl -s http://whatthecommit.com/index.txt`"
$ mvn org.codehaus.mojo:versions-maven-plugin:2.0:set -DgenerateBackupPoms=false -DnewVersion=$NEXT_DEVELOPMENT_VERSION
$ git commit -a -m "pushes to development version $NEXT_DEVELOPMENT_VERSION"
$ git push origin tag v$NEXT_VERSION && git push origin

Contributing

We're looking forward to your comments, issues and pull requests!

License

This project is licensed under the Apache License, Version 2.

com.s24.tomcat

shopping24 commerce network

Versions

Version
0.1.0