2023-06-28-TIL

Today I Learned

Redis HA

  • https://nesoy.github.io/articles/2020-05/Redis-HA
  • https://redis.io/docs/management/sentinel/
  • https://redis.com/redis-enterprise/technology/highly-available-redis/
  • https://success.outsystems.com/documentation/how_to_guides/infrastructure/configuring_outsystems_with_redis_in_memory_session_storage/redis_cluster_high_availability_architecture/
  • https://lifeplan-b.tistory.com/35
  • https://charsyam.wordpress.com/2020/11/20/%EC%9E%85-%EA%B0%9C%EB%B0%9C-redis-%EC%9E%A5%EC%95%A0-%EC%A2%85%EB%A5%98-%EC%A0%95%EB%A6%AC/
  • https://s-core.co.kr/insight/view/redis-%EB%82%B4%EB%B6%80-%EB%8F%99%EC%9E%91-%EC%9B%90%EB%A6%AC%EC%99%80-%EC%B5%9C%EC%A0%81%ED%99%94-%EB%B0%A9%EC%95%88/
  • https://www.oss.kr/storage/app/public/festival/track2/2-1.pdf
  • https://zdnet.co.kr/view/?no=20131119174125

Lettuce

  • https://jronin.tistory.com/126
  • https://lettuce.io/core/release/reference/index.html

Redis Cluster

  • https://brunch.co.kr/@springboot/218
  • https://jojoldu.tistory.com/297

Spring Data JPA Performance Pitfalls

  • https://thorben-janssen.com/6-performance-pitfalls-when-using-spring-data-jpa/

Spring Data JPA findById Anti-Pattern

findById.orElseThrow로 엔티티를 가져와서 child에 set하고 저장하는 방식의 단점은 일일이 select쿼리가 나간다는 것이다. 따라서 getReferenceById로 프록시 객체를 통해서 세팅하고 저장하면 select쿼리는 나가지 않고, 만약 존재하지 않는 ID라면 제약조건에서 걸릴것이다. 하지만 외래키로 매핑되어있지 않다면?

  • https://vladmihalcea.com/spring-data-jpa-findbyid/

Soft Delete

  • https://stackoverflow.com/questions/2549839/are-soft-deletes-a-good-idea

findAllById

  • https://dabok407.tistory.com/73
  • https://www.baeldung.com/spring-data-jpa-find-by-vs-find-all-by

JPA Keywords

  • https://docs.spring.io/spring-data/jpa/docs/current/reference/html/#appendix.query.method.subject