๐ฑ ์ด๋ฒ์ฃผ ์คํฐ๋ ๋ชฉํ, ์คํฐ๋ ๋ฒ์
- ์๋ฒ ํ ํ๋ฆฟ ์์ง๊ณผ ๋จธ์คํ ์น ์๊ฐ
- ํ๋ฉด ๋ง๋ค๊ธฐ
๐ฑ ๋จธ์คํ ์น๋ก ํ๋ฉด ๊ตฌ์ฑํ๊ธฐ - ์๋ฒ ํ ํ๋ฆฟ ์์ง๊ณผ ๋จธ์คํ ์น ์๊ฐ
- ํ ํ๋ฆฟ ์์ง
- ๋จธ์คํ ์น๋
- ๋จธ์คํ ์น ํ๋ฌ๊ทธ์ธ ์ค์น
๐ฑ ๋จธ์คํ ์น๋ก ํ๋ฉด ๊ตฌ์ฑํ๊ธฐ - ํ๋ฉด ๋ง๋ค๊ธฐ
- ๊ธฐ๋ณธ ํ์ด์ง ๋ง๋ค๊ธฐ [Spring Boot] 04์ฅ. ๋จธ์คํ ์น๋ก ํ๋ฉด ๊ตฌ์ฑํ๊ธฐ - ๊ธฐ๋ณธ ํ์ด์ง ๋ง๋ค๊ธฐ
- ๊ฒ์๊ธ ๋ฑ๋ก ํ๋ฉด ๋ง๋ค๊ธฐ [Spring Boot] 04์ฅ. ๋จธ์คํ ์น๋ก ํ๋ฉด ๊ตฌ์ฑํ๊ธฐ - ๊ฒ์๊ธ ๋ฑ๋ก ํ๋ฉด ๋ง๋ค๊ธฐ
- ์ ์ฒด ์กฐํ ํ๋ฉด ๋ง๋ค๊ธฐ [Spring Boot] 04์ฅ. ๋จธ์คํ ์น๋ก ํ๋ฉด ๊ตฌ์ฑํ๊ธฐ - ์ ์ฒด ์กฐํ ํ๋ฉด ๋ง๋ค๊ธฐ
- ๊ฒ์๊ธ ์์ ํ๋ฉด ๋ง๋ค๊ธฐ [Spring Boot] 04์ฅ. ๋จธ์คํ ์น๋ก ํ๋ฉด ๊ตฌ์ฑํ๊ธฐ - ๊ฒ์๊ธ ์์ ํ๋ฉด ๋ง๋ค๊ธฐ
- ๊ฒ์๊ธ ์ญ์ ํ๋ฉด ๋ง๋ค๊ธฐ [Spring Boot] 04์ฅ. ๋จธ์คํ ์น๋ก ํ๋ฉด ๊ตฌ์ฑํ๊ธฐ - ๊ฒ์๊ธ ์ญ์ ํ๋ฉด ๋ง๋ค๊ธฐ
๐ฑ ์คํฐ๋ํ๋ฉด์ ์ด๋ ค์ ๋ ๋ถ๋ถ (ํธ๋ฌ๋ธ ์ํ )
๐ tomcat ๊ธฐ๋ ์, 8080 ํฌํธ๊ฐ ์ด๋ฏธ ์ฌ์ฉ ์ค์ด์ด์ ๋ฌธ์ ๋ฐ์
- cmd ์ฐฝ ์คํ
- netstat -ano ๋ช ๋ น์ด ์ ๋ ฅ
- taskkill /f /pid ํ๋ก์ธ์คID ๋ช ๋ น์ด ์คํ
๐ IndexController์ ์์น๋ฅผ ๋ค๋ฅธ ๊ณณ์ผ๋ก ์ด๋ ์ ์ค๋ฅ ๋ฐ์
- gradle์์ clean ์งํ
- gradle์์ build ์งํ
- ๋ค์ ์คํํ์ฌ ํด๊ฒฐ
๐ ๋ฑ๋ก, ์์ , ์ญ์ ๋ฒํผ์ด ์๋ํ์ง ์์ ๋๋ index.js์ ์ฝ๋๋ฅผ ๋ค์ ํ์ธํด๋ณผ ๊ฒ!
๐ฑ ์๋กญ๊ฒ ๋ฐฐ์ด ๊ฒ
- ์๋ฒ ํ ํ๋ฆฟ ์์ง๊ณผ ํด๋ผ์ด์ธํธ ํ ํ๋ฆฟ ์์ง์ ์ฐจ์ด
- ๋จธ์คํ ์น๋ฅผ ํตํ ์คํ๋ง ๋ถํธ์ ํ๋ฉด ์ฒ๋ฆฌ ๋ฐฉ๋ฒ : IndexController๋ฅผ ์์ฑํ ํ @GetMapping์ ํตํด ๋จธ์คํ ์น์ URL ๋งคํ
- ๋จธ์คํ ์น ํ๋ฉด ์ด๋์๋ ํ์ํ ๋ถํธ์คํธ๋ฉ๊ณผ ์ ์ด์ฟผ๋ฆฌ๋ ๋ ์ด์์ ๋ฐฉ์์ผ๋ก ์ถ๊ฐ๋ฅผ ํด์ผ ํจ (๋ณ๋์ ํ์ผ๋ก ๋ถ๋ฆฌํด ๊ฐ์ ธ๋ค ์)
- ํ์ด์ง์ ๋ก๋ฉ ์๋๋ฅผ ๋์ด๊ธฐ ์ํด์๋ js์ css์ ์ ์ธ ์์น๋ฅผ ๋ค๋ฅด๊ฒ ํด์ผ ํจ (css๋ header์, js๋ footer์)
- ์ค์ฝํ๋ก ์ธํด ๋ฎ์ด์์์ง๋ ๋ฌธ์ ๊ฐ ๋ฐ์ํ์ง ์๊ธฐ ์ํด index ๊ฐ์ฒด ์์ function์ ์ถ๊ฐํ์ฌ ์ ํจ ๋ฒ์๋ฅผ ๋ง๋ค๊ธฐ
- ํ๋ฉด ๋ง๋ค๊ธฐ์ ํ์ํ ์ฝ๋ ๋ถ๋ถ :
- header.mustache, footer.mustache : css๋ฅผ ์ํ ๋ถํธ์คํธ๋ฉ๊ณผ js๋ฅผ ์ํ ์ ์ด์ฟผ๋ฆฌ
- index.mustache : ์ฒซ ํ์ด์ง์ ๋ค๋ฅธ ํ์ด์ง๋ก ์ด๋ํ๋ ๋ฒํผ ์์ฑ, ์ ์ฒด ์กฐํ ๋ฑ์ UI ๋ณ๊ฒฝ
- IndexController.java : @GetMapping์ ํตํด ๋จธ์คํ ์น์ ์ฐ๊ฒฐ๋๋๋ก URL ๋งคํ
- posts-save.mustache, posts-update.mustache : ํ์ด์ง์ ๋ฐ๋ฅธ UI ์์ฑ
- index.js : ๋ฒํผ ํด๋ฆญ ๋ฑ์ ์ด๋ฒคํธ ๋ฐ์ ์ API๋ฅผ ํธ์ถํ๊ธฐ ์ํ JS
- PostsRepository.java : ์ ์ฒด ์กฐํ๋ฅผ ์ํ SELECT ์ฟผ๋ฆฌ ์์ฑ
- PostsService.java : ์กฐํ ์๋ ๊ฐ์ ์ ์ํ ๋ฉ์๋ ๋ฐ ๋ฑ๋ก, ์์ , ์ญ์ API ์์ฑ์ ์ํ ์๋น์ค ๋ฉ์๋ ์์ฑ
- PostsListResponseDto.java : ์ ์ฒด ์กฐํ๋ฅผ ์ํ Dto
- PostsApiController.java : ๋ฑ๋ก, ์์ , ์กฐํ, ์ญ์ API ์์ฒญ์ ๋ฐ๋ Controller
๐ฑ PR
๐ฑ ์ฐธ์กฐํ๋ ๋งํฌ, ๋ฌธ์ ๋ฐ ์์คํ์ผ GIT ์ฃผ์
- '์คํ๋ง ๋ถํธ์ AWS๋ก ํผ์ ๊ตฌํํ๋ ์น ์๋น์ค' ๊ต์ฌ ํ์ฉ
http://www.yes24.com/Product/Goods/83849117
์คํ๋ง ๋ถํธ์ AWS๋ก ํผ์ ๊ตฌํํ๋ ์น ์๋น์ค - YES24
๊ฐ์ฅ ๋น ๋ฅด๊ณ ์ฝ๊ฒ ์น ์๋น์ค์ ๋ชจ๋ ๊ณผ์ ์ ๊ฒฝํํ๋ค. ๊ฒฝํ์ด ์ค๋ ฅ์ด ๋๋ ์๊ฐ!์ด ์ฑ ์ ์ ๋ชฉ ๊ทธ๋๋ก ์คํ๋ง ๋ถํธ์ AWS๋ก ์น ์๋น์ค๋ฅผ ๊ตฌํํ๋ค. JPA์ JUnit ํ ์คํธ, ๊ทธ๋ ์ด๋ค, ๋จธ์คํ ์น, ์คํ๋ง
www.yes24.com
https://github.com/dsc-sookmyung/2021-02-Spring-Study/tree/GaGa-Kim
GitHub - dsc-sookmyung/2021-02-Spring-Study: [2021 GDSC Sookmyung 2๊ธฐ] 1๋ถ๊ธฐ ์คํฐ๋(Spring)๋ฅผ ์ํ ์ ์ฅ์
[2021 GDSC Sookmyung 2๊ธฐ] 1๋ถ๊ธฐ ์คํฐ๋(Spring)๋ฅผ ์ํ ์ ์ฅ์. Contribute to dsc-sookmyung/2021-02-Spring-Study development by creating an account on GitHub.
github.com
Caused by: java.net.BindException: Address already in use: bind ํด๊ฒฐ
tomcat Address already in use : bind ํด๊ฒฐ๋ฐฉ๋ฒ
Spring Boot ๊ธฐ๋ ์ค ๋ค์๊ณผ ๊ฐ์ ์๋ฌ ๋ฐ์ java.net.BindException : Address already in use : bind ์๋ฌ๋ด์ฉ ๊ทธ๋๋ก tomcat ๊ธฐ๋ ์, address ๊ฐ ์ค๋ณต๋๋ค๋ ์ด์ผ๊ธฐ์ธ๋ฐ tomcat์ด ์ฃผ๋ก ์ฌ์ฉํ๋ 8080 ํฌํธ๋ฅผ..
mkil.tistory.com
Caused by: org.springframework.context.annotation.ConflictingBeanDefinitionException ํด๊ฒฐ
https://github.com/jojoldu/freelec-springboot2-webservice/issues/271
[์ค๋ฅ] indexController ํด๋ ๋ณ๊ฒฝํ bean์ค๋ณต ์ค๋ฅ · Issue #271 · jojoldu/freelec-springboot2-webservice
์ด๋ค ์ค๋ฅ์ธ๊ฐ์? ์ค๋ฅ์ค๋ช : ์๋ ํ์ธ์ indexController ํด๋์ค์์น๋ฅผ src.main.java.com.cocicalc.web.dto ๋ก ์๋ชป๋์ด ์์ด์ src.main.java.com.cocicalc.web ๋ก ์ฎ๊ฒผ๋๋ฐ ์ดํ๋ก Application.java๋ฅผ ๊ตฌ๋ํ๋ฉด org.springfram
github.com
'Community > GDSC' ์นดํ ๊ณ ๋ฆฌ์ ๋ค๋ฅธ ๊ธ
[211101-211107] 2021 GDSC Spring Study - 5์ฃผ์ฐจ (0) | 2021.11.06 |
---|---|
[211025-211031] 2021 GDSC Spring Study - 4์ฃผ์ฐจ (0) | 2021.10.31 |
[211004-211010] 2021 GDSC Spring Study - 2์ฃผ์ฐจ (0) | 2021.10.06 |
[210927-211003] 2021 GDSC Spring Study - 1์ฃผ์ฐจ (0) | 2021.10.02 |
[210924~] Github ์์ํ๊ธฐ ํธ์ฆ์จ ์ํฌ์ต ๋ฏธ์ - Pull Request (PR) (0) | 2021.09.25 |