728x90
반응형
@Service
@CacheConfig(cacheNames = "square")
@Scope(proxyMode = ScopedProxyMode.TARGET_CLASS)
public class MathService {
@Autowired
private MathService self;
// other code
public double sumOfSquareOf3() {
return self.square(3) + self.square(3);
}
}
https://www.baeldung.com/spring-invoke-cacheable-other-method-same-bean
728x90
반응형
'공부 (@Deprecated)' 카테고리의 다른 글
| [git] git init & git remote add origin https://github.com/user/repo.git (0) | 2023.11.11 |
|---|---|
| [slack] /github subscribe owner/repo [feature] (0) | 2023.11.04 |
| [Spring] JPA (0) | 2023.11.03 |
| [Spring] HikariCP - maximumPoolSize (0) | 2023.11.03 |
| [Spring] myBatis typeHandler (0) | 2023.11.03 |