체크인 시 PostgreSQL(통계용 영구 기록)과 Redis(실시간 활성 체크인)에 함께 저장. 활성 메이트 조회를 Redis ZSet(member=dogId, score=체크인시각, 24h TTL)에서 최근 24시간·최신순으로 수행. Postgres 는 이벤트마다 누적(통계). - CheckInRedisStore: ZSet + 24h 키 TTL, 조회 시 만료 정리 - application.yml: spring.data.redis (env 주입, 기본 localhost:6379) - Redis 미기동 시에도 컨텍스트 로드(Lettuce 지연연결) → CI/테스트 안전 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -23,6 +23,16 @@ spring:
|
||||
baseline-on-migrate: true
|
||||
locations: classpath:db/migration
|
||||
|
||||
# 실시간 스팟 체크인(24h TTL) 저장소. 값은 .env 에서 주입, 미설정 시 로컬 기본값.
|
||||
data:
|
||||
redis:
|
||||
host: ${REDIS_HOST:localhost}
|
||||
port: ${REDIS_PORT:6379}
|
||||
password: ${REDIS_PASSWORD:}
|
||||
# StringRedisTemplate 만 사용(RedisHash 리포지토리 없음) → JPA 리포지토리 오분류 스캔 비활성.
|
||||
repositories:
|
||||
enabled: false
|
||||
|
||||
# 스케줄러/시간 기준: 한국 시간(KST) 자정
|
||||
app:
|
||||
scheduler:
|
||||
|
||||
Reference in New Issue
Block a user