โš™๏ธ Trouble Shooting

    [TS] Spring Security + Spring OAuth2 Client ์ ์šฉ ๊ณผ์ • ์ค‘ ๋ฐœ์ƒํ•œ ๋ฌธ์ œ ํŠธ๋Ÿฌ๋ธ” ์ŠˆํŒ…

    [TS] Spring Security + Spring OAuth2 Client ์ ์šฉ ๊ณผ์ • ์ค‘ ๋ฐœ์ƒํ•œ ๋ฌธ์ œ ํŠธ๋Ÿฌ๋ธ” ์ŠˆํŒ…

    ๐Ÿค” ์˜ค๋ฅ˜ ๋ฐœ์ƒ ์ƒˆ๋กœ์šด ํ† ์ด ํ”„๋กœ์ ํŠธ, NEO๋ฅผ ๊ฐœ๋ฐœํ•˜๋ฉด์„œ ์†Œ์…œ ๋กœ๊ทธ์ธ ๊ธฐ๋Šฅ ๊ตฌํ˜„์„ ์œ„ํ•ด OAuth2 Client ๊ฐœ๋ฐœ์„ ์ง„ํ–‰ํ–ˆ์Šต๋‹ˆ๋‹ค. ๊ฐœ๋ฐœ์ด ๋๋‚œ ํ›„, API ์š”์ฒญ์„ ํ†ตํ•ด ํ•ด๋‹น ๊ธฐ๋Šฅ์„ ๊ฒ€ํ† ํ•˜๋Š” ๋„์ค‘ ๋ฐ์ดํ„ฐ๋ฒ ์ด์Šค ์ƒ์— OAuth2 ์ธ์ฆ ๊ณผ์ •์„ ์ง„ํ–‰ํ•œ ์ดํ›„ ์ƒˆ๋กœ์šด ํšŒ์› ๊ฐ€์ž… ๋ฐ์ดํ„ฐ๊ฐ€ ์ €์žฅ๋˜์ง€ ์•Š๋Š” ์ด์ƒํ•œ ํ˜„์ƒ์„ ๋ฐœ๊ฒฌํ–ˆ์Šต๋‹ˆ๋‹ค. ๋ฐ์ดํ„ฐ๋ฒ ์ด์Šค์˜ ๋ฌธ์ œ๋ผ๋ฉด, ๋ถ„๋ช… ๋กœ๊ทธ๊ฐ€ ์ž‘์„ฑ๋˜์—ˆ์„ํ…๋ฐ, ํ•ด๋‹น ๋กœ๊ทธ๊ฐ€ ์—†๋Š” ๊ฒƒ๋„ ์ด์ƒํ•ด ๋ฌธ์ œ์˜ ์›์ธ์„ ํŠธ๋ž˜ํ‚นํ–ˆ์Šต๋‹ˆ๋‹ค. OAuth2 ์ธ์ฆ ๊ณผ์ • ์ค‘, ์‚ฌ์šฉ์ž์˜ ์ •๋ณด๋ฅผ ์–ป์–ด์™€ ๋ฐ์ดํ„ฐ๋ฒ ์ด์Šค์— ์ €์žฅํ•˜๋Š” ์ฝ”๋“œ๋Š”, OAuth2UserService๋ฅผ implementํ•œ NEOOAuth2UserService์— ์žˆ์Šต๋‹ˆ๋‹ค. @Slf4j @Service @RequiredArgsConstructor public ..

    [Trouble Shooting] Lombok ์‚ฌ์šฉ์‹œ, ์–ด๋…ธํ…Œ์ด์…˜์ด ์ ์šฉ๋˜์ง€ ์•Š๋Š” ๊ฐ„๋‹จํ•œ ๋ฌธ์ œ ํ•ด๊ฒฐ

    [Trouble Shooting] Lombok ์‚ฌ์šฉ์‹œ, ์–ด๋…ธํ…Œ์ด์…˜์ด ์ ์šฉ๋˜์ง€ ์•Š๋Š” ๊ฐ„๋‹จํ•œ ๋ฌธ์ œ ํ•ด๊ฒฐ

    Lombok์„ ์‚ฌ์šฉํ•ด ๋งŽ์€ ๋ณด์ผ๋Ÿฌ ํ”Œ๋ ˆ์ดํŠธ ์ฝ”๋“œ๋ฅผ ์ค„์ด๊ณ  ์žˆ๋‹ค. @RequiredConstructor์™€ @Builder, @Getter๋“ฑ ๋งŽ์€ ๋„์›€์„ ์ฃผ๋Š” ๋ผ์ด๋ธŒ๋Ÿฌ๋ฆฌ์ด๋‹ค. ๊ทธ๋Ÿฌ๋‚˜ iDE ์ƒ์—์„œ๋Š” ์ •์ƒ์ ์œผ๋กœ ์ธ์‹์ด ๋˜์ง€๋งŒ, ๋นŒ๋“œ ๋ฐ ์ปดํŒŒ์ผ์„ ํ•˜๋ฉด ํ•ด๋‹น ๋ฉ”์†Œ๋“œ๋ฅผ ์ฐพ์„ ์ˆ˜ ์—†๋‹ค๋Š” ๊ธฐ์ดํ•œ ๋ฌธ์ œ์˜€๋‹ค. ์˜ˆ๋ฅผ ๋“ค์–ด, @RequiredConstructor๋ฅผ ์‚ฌ์šฉํ•˜๋ฉด IDE ์ƒ์—๋Š” ๋ฌธ์ œ ์—†๋Š” ์ฝ”๋“œ๋ฅผ ์ž˜ ์ž‘์„ฑํ–ˆ์ง€๋งŒ, ์ด์™€ ๊ฐ™์ด ์ƒ์„ฑ์ž๋Š” ์•„๋ฌด๋Ÿฐ ์ธ์ž๋ฅผ ์›ํ•˜์ง€ ์•Š๋Š”๋‹ค๋Š” ์˜ค๋ฅ˜๊ฐ€ ๋‚˜์™”๋‹ค. ์‹ค๋งˆ๋ฆฌ๋ฅผ ํ‘ธ๋Š” ๊ณผ์ •์—์„œ, ์ง์ ‘ ์†์œผ๋กœ ๋ชจ๋“  ์ธ์ž์— ๋Œ€ํ•œ Constructor๋ฅผ ์ƒ์„ฑํ•˜๋‹ˆ ์˜ค๋ฅ˜๊ฐ€ ์ œ๊ฑฐ๋˜์—ˆ๋‹ค๋Š” ์ ๊ณผ, ๋‹จ์ˆœํžˆ @RequiredArgsConstructor ์™ธ์—๋„ @Getter์™€ ๊ฐ™์€ ๋‹ค๋ฅธ ๋กฌ๋ณต ์–ด๋…ธํ…Œ์ด์…˜์— ๋Œ€ํ•ด์„œ๋„ ๋™์ผํ•œ ์˜ค๋ฅ˜๊ฐ€ ๋ฐœ..

    [Trouble Shooting] Swagger-ui๋ฅผ ์ ‘์†ํ–ˆ์„ ๋•Œ 404 error๊ฐ€ ๋‚˜๋Š” ๊ฒฝ์šฐ

    [Trouble Shooting] Swagger-ui๋ฅผ ์ ‘์†ํ–ˆ์„ ๋•Œ 404 error๊ฐ€ ๋‚˜๋Š” ๊ฒฝ์šฐ

    ์ด์ „ ํ”„๋กœ์ ํŠธ์—์„œ Swagger๋ฅผ ์‚ฌ์šฉํ•ด ๊ฐ™์€ ์„ค์ •์œผ๋กœ Swagger๋ฅผ Config ํ–ˆ์œผ๋‚˜, ๋กœ์ปฌ์—์„œ ํ•ด๋‹น URL๋กœ ์ ‘์†ํ–ˆ์„ ๋•Œ 404 Error๊ฐ€ ๋‚˜์˜ค๋Š” ํ˜„์ƒ์„ ๋ฐœ๊ฒฌํ–ˆ๋‹ค. ๋ฌธ์ œ์˜ ์›์ธ์€ ๋‹ฌ๋ผ์ง„ ์Šคํ”„๋ง ๋ถ€ํŠธ์˜ ๋ฒ„์ „์œผ๋กœ, ์ด์ „์—๋Š” 2๋ฒ„์ „์„ ์‚ฌ์šฉํ–ˆ๋‹ค๋ฉด ์ง€๊ธˆ์€ 3๋ฒ„์ „์„ ์„ ํƒํ–ˆ๊ธฐ ๋•Œ๋ฌธ์— ๋ฐœ์ƒํ•œ ์˜ค๋ฅ˜๋‹ค. ํ•ด๊ฒฐ์ฑ…์„ ์ฐพ์€๊ณณ์€ Stack Overflow์˜€๋‹ค. https://stackoverflow.com/questions/74614369/how-to-run-swagger-3-on-spring-boot-3 How to run Swagger 3 on Spring Boot 3 Using a fresh Spring Initialzr with Java17 and Spring Boot 3.0.0, and an extra addi..

    [TS] JPA error - Specified key was too long; max key length is 1000 bytes

    [TS] JPA error - Specified key was too long; max key length is 1000 bytes

    ํ”„๋กœ์ ํŠธ ๊ฐœ๋ฐœ ๋„์ค‘, ํ•œ ์‚ฌ๋žŒ๋‹น ํ•˜๋‚˜์˜ ๊ณ„์ •๊ณผ ๋ฉค๋ฒ„ ์†Œ์†์„ ๊ฐ€์งˆ ์ˆ˜ ์žˆ๋„๋ก ํ•˜๊ธฐ ์œ„ํ•ด์„œ, unique ํ‚ค๋ฅผ ์„ค์ •ํ•˜๋ ค๊ณ  ํ–ˆ์Šต๋‹ˆ๋‹ค. ๋‹น์‹œ unique ํ‚ค๋กœ ์ง€์ •ํ•œ ๊ฒƒ์€, ์ด๋ฆ„๊ณผ tel1, tel2, tel3์™€ ๊ฐ™์€ ์ „ํ™”๋ฒˆํ˜ธ๋ฅผ ๊ธฐ์ค€์œผ๋กœ unique ํ‚ค๋ฅผ ์„ ํƒํ–ˆ์Šต๋‹ˆ๋‹ค. ๊ทธ๋Ÿฌ์ž ํ•˜๋‹จ๊ณผ ๊ฐ™์€ ์˜ค๋ฅ˜๊ฐ€ ๋ฐœ์ƒํ–ˆ์Šต๋‹ˆ๋‹ค. Specified key was too long; max key length is 1000 bytes ์šฐ์„ , ๋‹น์‹œ Java์—์„œ ์—”ํ‹ฐํ‹ฐ ๊ฐ์ฒด๋ฅผ ์ƒ์„ฑํ•  ๋•Œ ์ด๋ฆ„๊ณผ tel1, tel2, tel3์— ๋Œ€ํ•ด์„œ String ํƒ€์ž…์œผ๋กœ ์„ค์ •ํ•˜๊ณ  ์–ด๋– ํ•œ ์ œํ•œ์„ ๋‘์ง€ ์•Š์•˜์Šต๋‹ˆ๋‹ค. JPA์—์„œ spring.jpa.hibernate.ddl-auto=create ์˜ต์…˜์œผ๋กœ ์ž๋™์œผ๋กœ ํ…Œ์ด๋ธ”์„ ์ƒ์„ฑํ•  ๋•Œ MyISAM ์—”์ง„์„ ์‚ฌ์šฉํ•œ๋‹ค๋ฉด, ..

    [TS] ์ƒˆ๋กœ์šด ํ”„๋กœ์ ํŠธ ์ƒ์„ฑ ๋ฐ Spring WebFlux ์ ์šฉ ๊ณผ์ • ์ค‘ ์ƒ๊ธด ํŠธ๋Ÿฌ๋ธ” ์ŠˆํŒ…

    [TS] ์ƒˆ๋กœ์šด ํ”„๋กœ์ ํŠธ ์ƒ์„ฑ ๋ฐ Spring WebFlux ์ ์šฉ ๊ณผ์ • ์ค‘ ์ƒ๊ธด ํŠธ๋Ÿฌ๋ธ” ์ŠˆํŒ…

    ๐Ÿ›  1. Unable to load io.netty.resolver.dns.macos.MacOSDnsServerAddressStreamProvider ์˜ค๋ฅ˜ > ์ฐธ๊ณ  ๊ธ€ OSX - M1 ๊ฐœ๋ฐœํ™˜๊ฒฝ ์˜ค๋ฅ˜ - could not load a native library: netty_resolver_dns_native_macos_aarch_64 ์ง€๋‚œ๋ฒˆ ํฌ์ŠคํŒ…๊ณผ ๋น„์Šทํ•œ ๋‚ด์šฉ์ž…๋‹ˆ๋‹ค. OSX - M1 ๊ฐœ๋ฐœํ™˜๊ฒฝ ์˜ค๋ฅ˜ - [FAILED_TO_LOAD_NATIVE_LIBRARY] no native library is found for os.name=Mac and os.arch=aarch6. #g ์–ผ๋งˆ ์ „ ์ง€๊ธ‰๋ฐ›์€ M1๋งฅ๋ถ์—์„œ ๊ฐœ๋ฐœํ™˜๊ฒฝ์„ ์„ธํŒ…ํ•˜๋ฉด์„œ ๊ฒช์€ junho85.pe.kr ํ”„๋กœ์ ํŠธ๋ฅผ ์‹คํ–‰ํ•˜์ž ๋‹ค์Œ๊ณผ ๊ฐ™์€ ์—๋Ÿฌ๊ฐ€ ๋‚˜์™”์Šต๋‹ˆ๋‹ค...