我正在开发一个 Eclipse 插件,其中包括启动嵌入式码头服务器,即
Server jetty = new Server(8080);
WebAppContext webapp = new WebAppContext("webapp", "/webapp");
webapp.setWar("path/to/webapp);
jetty.setHandler(webapp);
jetty.start();
Program.launch("http://localhost:8080/webapp");
我想在包含我的插件的 Eclipse 的控制台窗口中查看码头的输出。相反,jetty 的输出出现在我正在开发插件的 Eclipse 中。