11-15 06:12
Recent Posts
Recent Comments
Tags
- ์๋ฐ
- SQL
- ํ์ด์
- Spring
- TSQL
- JOBํ๊ณ
- ์๋์ด๋ ธ
- ์ด๋ธ์
- ํ๋ก๋ณด๋ ธ
- ์คํฝ์ค๋น
- linux
- DB
- DATABASE
- Java
- RaspberryPi
- Naver Cloud
- python
- ์จ์ผ๋ํ
- ์กํ๊ณ
- ๋ฐ์ดํฐ๋ฒ ์ด์ค
- ์คํฝ๋ ํ
- ICT
- appetizer
- ํ์ด์ฌ
- mysql
- ict๊ณต๋ชจ์
- ICT๋ฉํ ๋ง
- API MarketPlace ๊ธ๋ก๋ฒ ์ํฌํฐ์ฆ
- API๋ง์ผํ๋ ์ด์ค
- ํ์ด์๊ณต๋ชจ์
- Today
- Total
miinsun
[Spring] ํ๊ธ ํ๋ผ๋ฏธํฐ ๊นจ์ง ํด๊ฒฐ ๋ฐฉ๋ฒ ๋ณธ๋ฌธ
๐ ์์ธ : ํ๊ธ ํ๋ผ๋ฏธํฐ๋ฅผ ๋๊ฒจ api ํ ์คํธํ์ ๋ ์์ ๊ฐ์ด ํ๊ธ์ด ๊นจ์ง๋ค.
๐ ํด๊ฒฐ ๋ฐฉ๋ฒ
GET๊ณผ POST๋ฐฉ์์ด ์๋ก ๋ค๋ฅธ ๋ฐฉ๋ฒ์ผ๋ก ํด๊ฒฐ ๊ฐ๋ฅํ๋ค.
1. POST ๋ฐฉ์ ํด๊ฒฐ ๋ฐฉ๋ฒ
web.xml ์ถ๊ฐ
<filter>
<filter-name>encodingFilter</filter-name>
<filter-class>org.springframework.web.filter.CharacterEncodingFilter</filter-class>
<init-param>
<param-name>encoding</param-name>
<param-value>UTF-8</param-value>
</init-param>
</filter>
<filter-mapping>
<filter-name>encodingFilter</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>
2. GET ๋ฐฉ์ ํด๊ฒฐ ๋ฐฉ๋ฒ
server.xml ์ถ๊ฐ
<Connector connectionTimeout="20000" port="8080" protocol="HTTP/1.1" redirectPort="8443" URIEncoding="UTF-8"/>
<Connector port="8009" protocol="AJP/1.3" redirectPort="8443" URIEncoding="UTF-8"/>
๐ ํด๊ฒฐ ์๋ฃ
์๋ ์ฌ์ง๊ณผ ๊ฐ์ด ํ์ํ '์ฒ'์ ์ธ์ํด ํ์ํ ๊ฐ์ ๋ฆฌํดํด์ค๋ค.
'WebApp > Spring' ์นดํ ๊ณ ๋ฆฌ์ ๋ค๋ฅธ ๊ธ
Comments