[Jetty] Debugging With Eclipse
There are a number of options available to debug your application in Eclipse.
If not done already prepare your application for remote debugging as described here: Enable remote debugging
Via command line:
$ java -Xdebug -agentlib:jdwp=transport=dt_socket,address=9999,server=y,suspend=n -jar start.jar
Linking with Eclipse
Next we need to link the Eclipse project with the deployed webapp.
Within Eclipse, right-click on the project containing the webapp deployed into jetty and select Debug → Debug Configurations and create a new configuration of Remote Java Application. Make sure the port you choose is the same as the one you added in Enable remote debugging.

Next in your webapp you can set a breakpoint within a servlet which when it is tripped will halt the remote jvm’s processing thread to await for debugging commands from your Eclipse instance.

Accessing that servlet within your browser, pointed at your remote debug configurated jetty-distribution, should transition your Eclipse instance to the standard Debug view.

Within Eclipse
Since Jetty can be incredibly simple to embed, many people choose to create a small main method which they can launch directly within Eclipse in order to more easily debug their entire application. The best place to get started on this approach is to look through Embedding Jetty and the Embedded Examples sections.
Once you have a main method defined in order to launch your application, right-click on the source file and selectDebug As → Java Application. In your Console tab within Eclipse you should see your application startup and once it has completed startup you should be able to configure breakpoints and hit the Jetty instance as normal via your web browser.
[转] http://www.eclipse.org/jetty/documentation/9.3.x/debugging-with-eclipse.html
[Jetty] Debugging With Eclipse的更多相关文章
- [C++] Solve "No source available for main()" error when debugging on Eclipse
In Mac, the issue image: 1. A existing cmake project on disk 2. import this project into Eclipse. 3 ...
- Java Debugging with Eclipse - Tutorial
1.1. What is debugging? Debugging allows you to run a program interactively while watching the sourc ...
- maven eclipse jetty debug
可以通过查看最近版本: http://mvnrepository.com/artifact/org.eclipse.jetty/jetty-server http://search.maven.org ...
- 使用Eclipse+Maven+Jetty构建Java Web开发环境(几个教程综合集成2014发行)
工作需要使用Jetty由于web集装箱,得知Eclipse+Maven+Jetty该组合是非常好的,因此,要在网上找了很多教程,但不写或多或少特定的或过时的内容而导致最终的配置失败,易于配置为未来的同 ...
- MyEclipse 和 eclipse 最简单的安装Jetty容器插件
一.MyEclipse安装jetty 1.下载jetty插件 http://pan.baidu.com/s/1nuMYGNv 2.将下载后的jetty插件放到安装MyEclipse目录的MyEcli ...
- Jetty使用教程(一)——开始使用Jetty
一.Jetty简介 1.1 什么是Jetty Jetty是一个提供HHTP服务器.HTTP客户端和javax.servlet容器的开源项目. 这个入门教程分为五个部分: 第一部分部分重点介绍如何使 ...
- Jetty:配置JSP支持
选择JSP实现 从Jetty-9.2開始,使用Apache Jasper作为默认JSP容器实现.在前面的版本号中使用的是Glassfish Jasper,在后面的版本号中也能够继续使用它. Jetty ...
- 25个最佳最闪亮的Eclipse开发项目
http://blog.csdn.net/howareyoutodayyhz/article/details/8264599 25个最佳最闪亮的Eclipse开发项目 标签: eclipseEclip ...
- Jetty使用教程(四:28-30)—Jetty开发指南
二十八.延续机制支持 28.1 延续简介 延续是一种机制用来实现类似于Servlet 3.0异步功能的异步Servlet,但提供了一个简单易操作的接口. 28.1.1 为什么使用异步Servlets ...
随机推荐
- maven项目更换本地仓库
由于电脑重装系统更换原来maven项目的本地仓库 以前的仓库位置如图 需要更换的仓库位置 更换步骤如下: 更换后:
- SpringBoot文档
一.Spring Boot 入门 1.Hello World探究 1.POM文件 1.父项目 <parent> <groupId>org.springframework.b ...
- mybaties xml 的头部
config.xml的头部: <?xml version="1.0" encoding="UTF-8" ?> <!DOCTYPE config ...
- C# -- FTP上传下载
C# -- FTP上传下载 1. C#实现FTP下载 private static void TestFtpDownloadFile(string strFtpPath, string strFile ...
- 看到了必须要Mark啊,最全的编程中英文词汇对照汇总(里面有好几个版本的,每个版本从a到d的顺序排列)
java: 第一章: JDK(Java Development Kit) java开发工具包 JVM(Java Virtual Machine) java虚拟机 Javac 编译命令 java ...
- mysql中几个日期时间类型之间的区别和使用
MySQL中有如下几个时间类型:date.time.datetime.timestamp.year MySQL数据类型 含义 date 只存 ...
- js获取数组中最大值,最小值
遍历方法 var arr =[12,14,34,566,34,98,77] var max = arr[0]; for(var i=0;i<arr.length;i++){ if(max< ...
- Greedy分饼干
分饼干:因为饼干大小和孩子的食欲度不一定是按大小顺序排列的,所以开始要排序一下,然后从最小的饼干依次从食欲小的孩子开始看,如果他愿意吃,就++,看下一个小孩子,这回拿的就是大一点的饼干了. Examp ...
- Codeforces Round #539 (Div. 2) - C. Sasha and a Bit of Relax(思维题)
Problem Codeforces Round #539 (Div. 2) - C. Sasha and a Bit of Relax Time Limit: 2000 mSec Problem ...
- Airtest自动化测试工具
一开始知道Airtest大概是在年初的时候,当时,看了一下官方的文档,大概是类似Sikuli的一个工具,主要用来做游戏自动化的,通过截图的方式用来解决游戏自动化测试的难题.最近,移动端测试的同事尝试用 ...