简体   繁体   English

将Java EE项目部署到WebSphere 7 WITHOUT Eclipse

[英]Deploy Java EE project to WebSphere 7 WITHOUT Eclipse

I am getting tired of all the bugs in eclipse and m2eclipse , and would like to build with maven using the command prompt, plus afterwards start the server , and deploy the application to the server and publish it using the command prompt . 我厌倦了eclipse和m2eclipse中的所有错误 ,并希望使用命令提示符构建maven,然后启动服务器 ,并将应用程序部署到服务器并使用命令提示符发布它。 Normally I do that within eclipse servers tab. 通常我在eclipse服务器选项卡中执行此操作。

If I make a change to the code, then I should just rebuild with maven and republish. 如果我对代码进行了更改,那么我应该使用maven重新构建并重新发布。

I am aware that you can deploy an EAR in Wepshere admin web console, but it is not ear I am thinking of, at least I don't think so. 我知道您可以在Wepshere管理员Web控制台中部署EAR,但这不是我想到的,至少我不这么认为。 I want to be able for example, once application is deployed, jRebel should be able to reload the clases in the jvm, but I believe the ear file is standalone so that wouldn't work. 我希望能够,例如,一旦部署了应用程序,jRebel应该能够重新加载jvm中的clases,但我相信ear文件是独立的,因此无法工作。

So, 所以,

How can I start the server from the command prompt, plus deploy a project and publish it ? 如何从命令提示符启动服务器,再部署项目并发布它?

Thanks! 谢谢!

You can automate the build so that it deploys the app as well, at least with Maven. 您可以自动化构建,以便它也部署应用程序,至少与Maven一样。 Have a look at this post: Maven 2 and WebSphere : 看看这篇文章: Maven 2和WebSphere

WebSphere has (had?) a Rapid Deploy feature that you can use for "hot" deployments. WebSphere具有(具有?)Rapid Deploy功能,可用于“热”部署。 Essentially it fired up a headless Eclipse for this, but it was much faster than a full EAR build and just as dynamic as going through WTP. 从本质上讲,它为此启动了无头Eclipse,但它比完整的EAR构建快得多,并且与通过WTP一样动态。

At the time, we had an Ant task that we used to copy the files over to the WRD directory. 当时,我们有一个Ant任务,我们用它来将文件复制到WRD目录。 I'm not sure how that would work with Maven, but I imagine one could rig up something. 我不确定这对Maven有什么用处,但我想有人可以装备一些东西。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM