Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | ||
6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 | 14 | 15 | 16 | 17 | 18 | 19 |
20 | 21 | 22 | 23 | 24 | 25 | 26 |
27 | 28 | 29 | 30 | 31 |
Tags
- GIT
- tomcat
- 단축키
- Windows 10
- 네트워크
- plugin
- context
- VirtualBox
- port
- Mac
- bash
- lsof
- xargs
- vscode
- Source
- Eclipse
- 줄바꿈 문자
- ssh
- web.xml
- Windows
- grep
- maVen
- IntelliJ
- netsh
- profile
- import
- Quartz
- resource
- JavaScript
- find
Archives
- Today
- Total
develog
[springboot] spring boot 에서 servlet 등록 본문
@ServletComponentScan
import org.springframework.boot.web.servlet.ServletComponentScan;
@ServletComponentScan
@SpringBootApplication
public class ServletApplication {
public static void main(String[] args) {
SpringApplication.run(ServletApplication.class, args);
}
}
@WebServlet
import javax.servlet.annotation.WebServlet;
@WebServlet(name = "helloServlet", urlPatterns = "/hello")
public class HelloServlet extends HttpServlet {
@Override
protected void service(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
}
}
Comments