본문 바로가기

반응형

Study/Java

(190)
spring-boot-properties-migrator로 custom property report 하기 spring-boot-properties-migrator 소개Spring Boot 기반 프로젝트에서 버전 변경 시 property가 변경되는 경우가 있다.spring-boot-properties-migrator depnedency를 추가하면 application 실행 시 변경된 property가 어떤 것인지 쉽게 확인할 수 있다.log로 대략 다음과 같이 안내해 준다.The use of configuration keys that have been renamed was found in the environment:Property source 'configserver:class path resource [xxxx.properties]': Key: spring.http.encoding.charset ..
Antora 사용해 보기 Spring Framework 문서가 antora로 제공된 지 꽤 시간이 지났는데 Spring Boot 문서도 이번 3.3.0부터 antora로 변경되었다.https://antora.org/요즘 오픈 소스 사이트 문서들을 보면 antora로 빌드하는 경우가 상당히 많아 antora 사용 방법에 대해 살펴보았다.Antora 소개Antora는 asciidoc 기반 문서를 기반으로 site 문서 (웹 기반 문서)를 생성하는 도구이다.https://www.algolia.com/antora를 사용하면 여러 git repository에 위치한 adoc 문서들을 취합하고 템플릿을 사용하여 하나의 통일된 스타일의 site 문서로 구성할 수 있다.git repository의 branch 단위의 문서를 가져와 버전별 문서..
Spring Boot 3.3 Release Notes 전체 Release Notes 목록은 이 곳에서 확인할 수 있습니다.https://luvstudy.tistory.com/tag/Release%20Noteshttps://github.com/spring-projects/spring-boot/wiki/Spring-Boot-3.3-Release-Notes10 revision 기준으로 작성됨Spring Boot 3.3.0 Release NotesUpgrading From Spring Boot 3.2Jersey ObservabilityMicrometer 1.13 에서는 Jersey 지원을 중단하고 Jersey의 jersey-micrometer module을 사용하게 되었습니다.Application에서 Jersey metric을 사용하는 경우 업그레이드할 때 org..
SonarQube, SonarLint issue 예외 처리하기 SonarQube나 SonarLint를 사용하면 코드 품질 관리가 편해진다.검사 대상 프로젝트의 코드 내 버그, 코드 스멜, 보안 취약점을 찾아 관련 내용을 issue로 등록하여 어느 부분에 어떤 문제가 있는지를 알려준다.하지만 issue로 등록하지 않기를 원하는 내용에 대해서도 Issue로 남기는 경우가 있다.예를 들어 아래와 같이 사용하는 경우를 가정해 보자.(Spring은 class 위치에 @RequestMapping 선언으로 각 method가 호출하는 공통된 path를 조합할 수 있지만 아래의 경우 그렇게 사용하지 않는 케이스라고 가정해 본다.)@Controllerpublic class Controller { private final String pathPrefix = "/some/prefi..
JDK 22 New Features JDK의 버전별 변경 사항은 여기를 참고하세요 Spec Java SE 22 Platform JSR 397 에 정의된 바와 같이 JSR 397 구현이 목표 실제 Spec은 Final Release Specification 문서를 참고 Final Release Specification Feature Summary 전체 JEP Feature 목록은 OpenJDK의 JDK 22 문서 에서 확인할 수 있다. JEP Component Feature JEP 423 hotspot / gc Region Pinning for G1 JEP 447 specification / language Statements before super(...) (Preview) JEP 454 Foreign Function & Memory AP..
Eclipse (STS) 에서 Parameter Name Hint 사용하기 IntelliJ는 편집기에 호출된 method에 필요한 annotation, method parameter, 사용법 등을 알려주는 추가 정보를 제공하는 특수한 marker를 제공하는 데 이를 Inlay Hint 라고 부르고 있다. https://www.jetbrains.com/help/idea/inlay-hints.html#enable_inlay_hints Inlay hints | IntelliJ IDEA www.jetbrains.com 다음과 같이 method parameter앞에 전달할 값의 Parameter Name이 무엇인지 확인할 수 있다. 이런 기능이 Eclipse에 없어서 아쉬웠는데 알고 보니 Eclipse도 4.12 (2019-06)부터 IntelliJ의 Inlay Hint 의 모든 기능은..
Spring ApplicationContext에서 GenericType 기준으로 bean 호출하기 다음과 같은 interface를 구현한@FunctionalInterfacepublic interface ServiceSupplier { T findOne(SomeParameter someParameter);}@FunctionalInterfacepublic interface ServiceListSupplier { List findList(SomeParameter someParameter);}다음과 같은 service가 있다고 가정해 보자.@Servicepublic class SomeService implements ServiceSupplier, ServiceListSupplier { @Override public SomeObject findOne(SomeParameter somePar..
Thymeleaf에서 DaisyUI Theme 사용해 보기 이전에 Spring Boot 기반의 프로젝트에서 Thymeleaf와 함께 Tailwind CSS를 사용하는 방법에 대해 소개하였었다. 2023.11.16 - [Study/Java] - Spring Boot + Thymeleaf + Tailwind CSS 사용해보기 DaisyUI 소개 Tailwind CSS가 bootstrap보다 자유도가 높은 대신 많은 설정이 필요하기 때문에 이를 보완하기 위해 Daisy UI를 사용하였다. DaisyUI는 Tailwind CSS기반에서 Bootstrap의 component 단위(Button, Form, Menu 같은...)의 CSS를 제공해 준다. 따라서 Component 단위로는 Tailwind CSS를 사용하면서 그 외의 CSS 설정은 Tailwind CSS를 같이..

반응형