JBoss and Eclipse

User Rating: 5 / 5

Star ActiveStar ActiveStar ActiveStar ActiveStar Active
 

JBoss and Eclipse

This tutorial shows how to get started with JBoss AS / WildFly and Eclipse. Developing application with JBoss can be performed with any Java EE IDE or even with as little as a common text editor and the Apache Maven tool. Most frequentely, developers will use Eclipse with JBoss tools plugins to achieve the best development experience.

JBoss tools includes a set of subprojects which are related to JBoss products: for example you can use JBoss AS Tools to create, deploy and debug applications on JBoss AS. The Hibernate tools can be used to simplify mapping and querying your data with Hibernate. The Seam tools can be an handy guide to develop applications with JBoss AS Seam project, and so on.

We will now show how to install the JBoss AS Tools. There are several ways to install Eclipse plugins: basically this boils down to intalling the plugin from within Eclipse environment and downloading and manually installing the tools. The simplest way to do it is through the Help | Eclipse Market Place and enter in the search box "JBoss Tools". You will see several JBoss Tools releases available. Choose to install or update the latest stable JBoss Tools plugin:

wildfly eclipse jboss tools

In the following screen select the "JBoss AS tools" plugin and restart Eclipse once completed. Now choose from the upper Menu: File | New | Server and expand the JBoss Community option. A "WildFly 10" Server is included:

wildfly deploy eclipse

In the next screen you have to choose if the Server is locally installed (Local) or it's a remote server (Remote) and how the Server Lifecycle is managed:

wildfly10 eclipse configure

Finally, point to the location where the application server is installed, the JRE execution environment and the configuration file to be used (default is standalone.xml) :

wildfly10 eclipse

Remember that WildFly 10 application server requires a JDK 1.8, therefore you will not be able to start it with an older JDK version. Click Finish. WildFly is now configured on your Eclipse environment!

Ok, at this point you should find out in the Eclipse tool bar the following three icons:

jboss with eclipse jboss and eclipse tutorial

This icon (1) can be used to select the server version in case you have installed multiple AS version
This icon (2) can be used to boot the application server
This icon (3) can be used to debug the application server

Additionally, you can choose from the Menu: Window | Show View | Server
The following tab GUI will be accessible to start/stop/debug and deploy applications on JBoss AS.
wildfly10 eclipse 4
Let's try to start the server. Right click on the Server icon and choose "Start" from the Menu.
The Console Tab GUI will activate, showing the server boot logs. At the end of the process, the Console will display f the server started correctly.
wildfly10 eclipse

Follow us on Twitter