-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[DEV-267] redis cache 구현 #8
Conversation
Test Coverage
|
@Configuration | ||
class SpelConfig { | ||
@Bean | ||
fun spelExpressionParser(): SpelExpressionParser { | ||
return SpelExpressionParser() | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
이 부분을 따로 Bean으로 등록하는 이유가 있나요?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
싱글톤으로 사용하려고 빈으로 등록해둔 검다
spring에서 자동으로 생성해주지 않기 때문
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
SpelExpressionParser를 확장한 다른 클래스로 갈아끼우는 게 아니면 이 부분이 활용될 여지가 없어보여서 여쭤봅니다
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
아 답글을 이제 봤네요
SpelExpressionParser를 싱글톤으로 사용해야하는 이유가 있나요?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
빈으로 등록해서 싱글톤으로 사용하는 거 자체에 의미가 있다고 생각하는데 어떤 점에서 활용될 여지가 없는 건지
잘 이해가 되지 않슴다
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
싱크가 안 맞았네요 ㅋㅋㅋ
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
원래 AspectUtil 내부 메서드에서 호출될 때마다 인스턴스를 만들어줬는데
인스턴스를 한번만 만들도록 하고 싶어서 싱글톤으로 했슴다
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
굳이 빈으로 등록 안 하고 생성자에서 만들어줘도 충분할 거 같슴다
src/main/kotlin/com/tiketeer/TiketeerWaiting/configuration/RedisConfig.kt
Outdated
Show resolved
Hide resolved
한 티켓팅에 대해 대기 여러번 하는 테스트 시나리오가 있어서 없어도 될듯?! |
작업 내용
↓↓↓↓↓↓↓ cache 동작 확인 (select 한번 나감) ↓↓↓↓↓↓↓