Apereo CAS 6.0.0 JPA Ticket Registry configuration
Auther: Marvin Create date 2019/03/23

We need to config JPA ticket registry when we use Apereo CAS and config in HA environment. Otherwise we login from different client app will get different ticket and will show login form many times. Today I make a sample to tell you how to config it. It tested on version 6.0.0.

 

# JPA Ticket Registry

cas.ticket.registry.jpa.ticketLockType=NONE

cas.ticket.registry.jpa.jpaLockingTimeout=3600

# cas.ticket.registry.jpa.user=sa

# cas.ticket.registry.jpa.password=

# cas.ticket.registry.jpa.driverClass=com.ibm.db2.jcc.DB2Driver

# cas.ticket.registry.jpa.url=jdbc:

cas.ticket.registry.jpa.dialect=org.hibernate.dialect.DB2Dialect

cas.ticket.registry.jpa.failFastTimeout=1

# cas.ticket.registry.jpa.isolationLevelName=ISOLATION_READ_COMMITTED

cas.ticket.registry.jpa.healthQuery=

cas.ticket.registry.jpa.isolateInternalQueries=false

cas.ticket.registry.jpa.leakThreshold=10

# cas.ticket.registry.jpa.propagationBehaviorName=PROPAGATION_REQUIRED

cas.ticket.registry.jpa.batchSize=25

# cas.ticket.registry.jpa.defaultCatalog=

cas.ticket.registry.jpa.defaultSchema=cas

cas.ticket.registry.jpa.ddlAuto=create-drop

cas.ticket.registry.jpa.physicalNamingStrategyClassName=org.hibernate.boot.model.naming.PhysicalNamingStrategyStandardImpl

cas.ticket.registry.jpa.autocommit=false

cas.ticket.registry.jpa.idleTimeout=5000

cas.ticket.registry.jpa.dataSourceName=java:comp/env/jndi/CASDS

cas.ticket.registry.jpa.dataSourceProxy=false

# Hibernate-specific properties (i.e. `hibernate.globally_quoted_identifiers`)

cas.ticket.registry.jpa.properties.propertyName=propertyValue

 

make sure your pom.xml file have follow configuration.

<dependency>

<groupId>org.apereo.cas</groupId>

<artifactId>cas-server-support-jpa-ticket-registry</artifactId>

<version>${cas.version}</version>

</dependency>

You can reference our cas-overlay project at https://github.com/MarvinHsu/cas-overlay to see whole setting.