Posts
Q&A
์์กด๊ด๊ณ ์ฃผ์ ๊ด๋ จ ์ง๋ฌธ
๊ฐ ์ฃผ์ ์ ์ด๊ธฐํ ์ฝ๋ฐฑ๊ณผ ์ฐ๊ด์ฑ์ด ์์ด ๋ณด์ฌ ๋ค์๊ณผ ๊ฐ์ด ์ค์ ์ ์์ ํ๊ณ ํ ์คํธ๋ฅผ ์งํํ์ฌ๋ ์ฝ๋ฐฑ์ด ํธ์ถ๋์์ต๋๋ค. @Configurationstatic class LifeCycleConfig { @Bean public NetworkClient networkClient(){ NetworkClient networkClient = new NetworkClient(); //networkClient.setUrl("http://www.dev.or.kr"); return networkClient; }} ์์ ๊ฐ์ด Setter ํธ์ถ์ ์ฃผ์์ฒ๋ฆฌ ํ์ฌ๋ ์ด๊ธฐํ ์ฝ๋ฒก์ด ํธ์ถ๋์์ต๋๋ค. ํ ์คํธ ๊ฒฐ๊ณผ: ์์ฑ์ ํธ์ถ : url = null Connect url = null (*์ด๊ธฐํ ์ฝ๋ฐฑ ํธ์ถ) Call url = null message = Single tone 11:00:48.992 [Test worker] DEBUG org.springframework.context.annotation.AnnotationConfigApplicationContext - Closing org.springframework.context.annotation.AnnotationConfigApplicationContext@62ec3495, started on Tue Aug 24 11:00:48 KST 2021 Disconnect = null ํน ์ ๊ฐ ์ดํด๋ฅผ ์๋ชปํ๊ณ ์๋๊ฑด์ง์?
- 6
- 4
- 352
Q&A
5๋ถ 30์ด์ฏค ์ง๋ฌธ ์์ต๋๋ค.
MemberRepository์์ ๋ฉค๋ฒ๊ฐ์ฒด๋ฅผ ์์ฑํ์ง ์์์ OrderService์์ NullPointException์ด ๋ฐ์ํ๊ฒ ๊ฐ์ต๋๋ค.
- 1
- 2
- 223