Java – eclipse – > run as – > run on the server – how do I make it run with JBoss?

I use eclipse Juno, and I have done two projects:

>One of them is actually an ear containing EJB projects and a project that only holds EJB interfaces By going to: deploy it on the server: ear project – > export – > Java EE – > ear file, in the target box, I set the automatic deployment folder of the server (JBoss as 6) Then deploy the project and initialize the EJB. > The second project is a simple war project, depending on the project that holds the interface Among them, I have a virtual servlet that calls EJB The deployment process is almost the same The difference is that I select web – > export the war file in the navigation menu After deploying the war, everything is normal

Now I do the whole "export" because run as – > running on the server will not build and deploy my project I think this is its primary goal Am I wrong? Is there any way to make this command work as I expected? I think it works with Tomcat and the web project

I know this can be easily done by building scripts, but that's not my point!

Thank you for your help and advice

Solution

First, check whether JBoss tools is installed in the eclipse ide You can find them here

By default, JBoss as adapter uses Metadata / . plugins / org. jboss. ide. eclipse. as. core / JBoss-AS-5.1. 0. GA / deploy folder to deploy the project, and then register this temporary folder in JBoss In other words, if you start JBoss as from eclipse, you must deploy the project to this directory

You can try this (from JBoss community site) to help me:

>Server configuration (in the servers view of the eclipse IDE) > deploy > use JBoss deploy folder > save server configuration > select a project on the server and use the project context menu to "ful publish" > start the server

If you have configured everything correctly, the "add and remove" method in the previous answer should also work properly

If you let it work, please let me know

The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
分享
二维码
< <上一篇
下一篇>>