2023-02-25-TIL
2023-02-25-TIL
Today I Learned
Clean Code
클린 코드 책에 나온 내용들 중 좋은 내용도 많지만, 실무에 적합하지 않은 내용도 종종 있다고 한다. 클린 코드 책을 보게되면 비판적으로 읽도록 의식을 해야겠다.
- https://www.youtube.com/watch?v=HoP8qWpucWA&t=1s
- https://mangkyu.tistory.com/132
- https://hajoeun.blog/clean-code-3
- https://news.hada.io/weekly/202206
- https://shxrecord.tistory.com/254
- https://brunch.co.kr/@cleancode/19
- https://techblog.woowahan.com/2620/
- https://deepwelloper.tistory.com/entry/Clean-Code-%EA%B9%A8%EB%81%97%ED%95%9C-%EC%BD%94%EB%93%9C%EC%97%90-%EB%8C%80%ED%95%9C-%EB%8C%80%EA%B0%80%EB%93%A4%EC%9D%98-%EC%9D%98%EA%B2%AC
- https://velog.io/@baesh/%EC%84%9C%ED%8F%89-%ED%81%B4%EB%A6%B0%EC%BD%94%EB%93%9CClean-Code%EB%A5%BC-%EC%9D%BD%EA%B3%A0
- https://www.sollabs.tech/It-is-a-Developers-Problem
- https://technical-leader.tistory.com/m/94
- https://kldp.org/node/163519
- https://medium.com/naver-cloud-platform/%EB%84%A4%EC%9D%B4%EB%B2%84%ED%81%B4%EB%9D%BC%EC%9A%B0%EB%93%9C-%EA%B0%9C%EB%B0%9C%EC%9E%90-%EC%8A%A4%ED%86%A0%EB%A6%AC-%EC%A2%8B%EC%9D%80-%EC%BD%94%EB%93%9C%EB%9E%80-%EB%AC%B4%EC%97%87%EC%9D%BC%EA%B9%8C-%ED%81%B4%EB%A6%B0%EC%BD%94%EB%93%9C-%EC%9D%B4%EC%95%BC%EA%B8%B0-c7811f73a46b
Bridge Pattern
브릿지 패턴은 구현부와 추상화된 부분을 분리하여 각자 독립적으로 변형 및 확장이 가능하도록 하는 디자인 패턴이다. 여기에서 말하는 추상화 계층은 자바의 추상 클래스르 말하는 것은 아니고, 구현부에 비해서 상대적으로 상위 개념의 동작들을 의미한다. 예를 들어, Device라는 구현부가 있고 setVolume, getVolume 이라는 메서드를 가지고 있다면, 추상화 계층인 RemoteControl에서는 upVolume이라는 메서드를 통해서 setVolume(getVolume() + 10); 와 같이 구현부의 메서드를 여러가지 방식으로 조합해서 보다 상위 개념의 동작을 수행할 수 있다는 의미이다.
- https://springframework.guru/gang-of-four-design-patterns/bridge-pattern/
- https://www.baeldung.com/java-bridge-pattern
- https://springhow.com/bridge-pattern/
- https://stackoverflow.com/questions/61102147/spring-inject-two-implementations-of-an-interface-to-use-bridge-design-pattern
- https://docs.spring.io/spring-integration/reference/html/bridge.html
- https://www.javacodegeeks.com/2015/09/bridge-design-pattern.html
- https://lktprogrammer.tistory.com/35
- https://hirlawldo.tistory.com/169
- https://www.crocus.co.kr/1537
- https://refactoring.guru/design-patterns/bridge
- https://en.wikipedia.org/wiki/Orthogonality
- https://medium.com/@mertgltekin_58750/structural-design-patterns-2-bridge-pattern-7ee8d240ab59
Examples of GoF Design Patterns in Java’s core libraries
- https://stackoverflow.com/questions/1673841/examples-of-gof-design-patterns-in-javas-core-libraries/
Composition vs Inheritance
- https://incheol-jung.gitbook.io/docs/q-and-a/architecture/undefined-2
- https://ocwokocw.tistory.com/14
- https://mangkyu.tistory.com/199
- https://inpa.tistory.com/entry/OOP-%F0%9F%92%A0-%EA%B0%9D%EC%B2%B4-%EC%A7%80%ED%96%A5%EC%9D%98-%EC%83%81%EC%86%8D-%EB%AC%B8%EC%A0%9C%EC%A0%90%EA%B3%BC-%ED%95%A9%EC%84%B1Composition-%EC%9D%B4%ED%95%B4%ED%95%98%EA%B8%B0
Dependency Injection vs Composition
의존 주입은 생성자를 통해서 받은 파라미터의 인자값을 필드에 할당하는 것을 의미하고, 합성은 필드에 new를 사용해서 다른 객체를 할당하는 것을 의미한다.
- https://stackoverflow.com/questions/21022012/difference-between-dependency-and-composition
A/B Test
- https://www.oracle.com/kr/cx/marketing/what-is-ab-testing/#:~:text=%EB%8A%94%20%EB%AC%B4%EC%97%87%EC%9D%B8%EA%B0%80%EC%9A%94%3F-,A%2FB%20%ED%85%8C%EC%8A%A4%ED%8A%B8%EC%9D%98%20%EC%A0%95%EC%9D%98,A)%20%EB%B2%84%EC%A0%84%EC%9D%84%20%EA%B2%80%EC%A6%9D%ED%95%A9%EB%8B%88%EB%8B%A4.
- https://curl2ab.ahivert.dev/
javax.transaction.Transactional vs org.springframework.transaction.annotation.Transactional
- https://twitter.com/vlad_mihalcea/status/1297838022512320512
- https://theheydaze.tistory.com/366
- https://www.baeldung.com/spring-vs-jta-transactional
- https://interconnection.tistory.com/123
- https://stackoverflow.com/questions/26387399/javax-transaction-transactional-vs-org-springframework-transaction-annotation-tr
- https://docs.spring.io/spring-framework/docs/current/reference/html/data-access.html#tx-propagation
분산락
- https://velog.io/@korea3611/Spring-boot-%EC%A2%8B%EC%95%84%EC%9A%94%EC%88%98-%EC%A6%9D%EA%B0%80-%EB%B6%84%EC%82%B0%EB%9D%BD%EC%9D%84-%EC%9D%B4%EC%9A%A9%ED%95%98%EC%97%AC-%EB%8F%99%EC%8B%9C%EC%84%B1-%EC%A0%9C%EC%96%B4%ED%95%98%EA%B8%B0-redis%ED%99%9C%EC%9A%A9%ED%95%98%EA%B8%B0
- https://github.com/d-h-k/hansotdosirak
HikariCP Maximum Pool Size
- https://jaehun2841.github.io/2020/01/27/2020-01-27-hikaricp-maximum-pool-size-tuning/#%EC%9E%A5%EC%95%A0%EB%A5%BC-%EB%A7%9E%EC%95%98%EC%8A%B5%EB%8B%88%EB%8B%A4
- https://confluence.atlassian.com/bamkb/hikaricp-properties-1087518069.html
- https://stackoverflow.com/questions/55026422/default-maximumpoolsize-for-hikaricp
Configuring Hikari Connection Pool with Spring Boot
- https://howtodoinjava.com/spring-boot2/jpa-hibernate-hikaricp-config/
- https://www.baeldung.com/spring-boot-hikari
- https://www.javadevjournal.com/spring-boot/spring-boot-hikari/
Tomcat Thread Pool and JDBC Connection Pool
- https://stackoverflow.com/questions/12753219/need-help-understanding-tomcat-thread-pool-and-jdbc-connection-pool
Transactional Propagation
- https://docs.spring.io/spring-framework/docs/current/javadoc-api/org/springframework/transaction/annotation/Transactional.html
- https://n1tjrgns.tistory.com/266
Transactional Isolation Level
- https://n1tjrgns.tistory.com/267
Transactional in Coroutines
- https://github.com/spring-projects/spring-framework/issues/26705
- https://stackoverflow.com/questions/64136645/is-it-possible-to-use-transactional-and-kotlin-coroutines-in-spring-boot
Transaction Manager
- https://godekdls.github.io/Spring%20Data%20Access/transactionmanagement/
Reactive Transaction Manager
- https://spring.io/blog/2019/05/16/reactive-transactions-with-spring
Today I Thought
오늘 스터디를 하면서 몇 가지 실험을 해보았다. JPA에서 락을 변경해가면서 성능을 측정하고, 데이터의 정합성이 맞는지를 검증해보았다. 실험은 프로그래밍에서도 매우 중요한 소양 중 하나이다. 데이터베이스나 대량의 네트워크 트래픽을 다룰 때 일일이 이론적인 수치로 정해진 테이블이 있는게 아니라면, 반드시 성능 측정을 통해서 적절한 임계치를 찾아야한다. 그리고 변인의 설정을 정확하게 해서 실험의 결과가 유의미하다는 것을 확실할 수 있어야한다.
- https://namu.wiki/w/%EB%B3%80%EC%9D%B8