[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项目的本地仓库 以前的仓库位置如图 需要更换的仓库位置 更换步骤如下: 更换后:
- Linux/Ubuntu 16.04 好用的视频播放器 SMPlayer
在ubuntu上播放视频是少不了的事情,那么就安装SMPlayer吧, 终端输入 :sudo apt-add-repository ppa:rvm/smplayer ...
- memcached 学习
memcached 是什么 特点 协议简单 基于 libevent 的事件处理 内置内存存储方式 memcached 不互相通信的分布式 启动 安装 依赖 libevent 安装命令 下载地址在这个网 ...
- git 同步远程分支
1. 同步远程分支到本地 git fetch 2. 查看本地分支 git branch *dev //当前分支 master test 3.切换分支 git checkout master // 切换 ...
- 4.16 反射和jvm
- timers模块
timers模块 var timers = require('timers'); function A() { //将A对象注册到定时器里 timers.enroll(); //进行激活,如果不激活, ...
- (n)e(m)
经常会看到类似于 1e30 9e5 类似的表达式 (我一个蒟蒻不懂啊) 于是 给自己解释解释 那么 nem就是 n乘以10的m次方 (哈哈哈哈,我简直是太弱了)
- facebook marketing(市场营销) API(3)
如果你只想管理广告,而不想管理BM,那就需要市场营销API了. 相关文章 通过BM api管理完相互授权后,就可以让自己的运营参与进行投放了(市场营销API也支持非BM操作,即广告主自己操作). 市场 ...
- flutter-开发总结
### 上拉加载下拉刷新 ``` import 'dart:async'; import 'package:flutter_easyrefresh/easy_refresh.dart'; import ...
- [转帖]""(双引号) 与''(单引号) 差在哪?
""(双引号) 与''(单引号) 差在哪? http://wiki.jikexueyuan.com/project/13-questions-of-shell/double-sin ...