Class RedissonTimeSeriesAuditEventRepository

java.lang.Object
se.swedenconnect.spring.saml.idp.audit.repository.FilteringAuditEventRepository
se.swedenconnect.spring.saml.idp.audit.repository.RedissonTimeSeriesAuditEventRepository
All Implemented Interfaces:
org.springframework.boot.actuate.audit.AuditEventRepository

public class RedissonTimeSeriesAuditEventRepository extends FilteringAuditEventRepository
An AuditEventRepository implementation that uses Redis time series to store events.
Author:
Martin Lindström, Felix Hellman
  • Constructor Details

    • RedissonTimeSeriesAuditEventRepository

      public RedissonTimeSeriesAuditEventRepository(org.redisson.api.RedissonClient client, String tsName, AuditEventMapper mapper)
      Constructor setting up the repository to log all events.
      Parameters:
      client - the Redis client
      tsName - the Redis timeseries name holding the audit events
      mapper - mapper for creating/reading JSON events
    • RedissonTimeSeriesAuditEventRepository

      public RedissonTimeSeriesAuditEventRepository(org.redisson.api.RedissonClient client, String tsName, AuditEventMapper mapper, Predicate<org.springframework.boot.actuate.audit.AuditEvent> filter)
      Constructor setting up the repository to log events according to the supplied filter.
      Parameters:
      client - the Redis client
      tsName - the Redis timeseries name holding the audit events
      mapper - mapper for creating/reading JSON events
      filter - filter for determining which events to log
  • Method Details

    • addEvent

      protected void addEvent(org.springframework.boot.actuate.audit.AuditEvent event)
      Logs an event.
      Specified by:
      addEvent in class FilteringAuditEventRepository
      Parameters:
      event - the audit event to log
    • find

      public List<org.springframework.boot.actuate.audit.AuditEvent> find(String principal, Instant after, String type)