Thursday, April 30, 2009

JBossAS now has an admin-console!

JBoss AS users have always asked why JBoss does not have an admin console. Personally, i have always liked working directly on the configuration files without needing any web application or any other tool for doing the same. That's because i like spending more and more time on the AS. But for users who want to just get things done without having to worry about how it is done or which file gets placed where and want to manage the deployments through a web application, a decent admin console was always a neccessity. Its good news now for all JBoss AS users - starting 5.1.0.CR1 version, JBoss AS now has an excellent admin console!

I decided to give it a try, during this weekend, to see what features it provides. This article is just to give you some idea about what the admin-console has. The best place to look for all other details and feature list of the admin-console, is the Embedded Jopr project page. So here's an account of what i found about the admin-console.

The admin console is available by default in the "default" and "all" server configurations. The application is available as a WAR file "admin-console.war" in the deploy folder of these configurations. You can access the admin-console at the following URL http://localhost:8080/admin-console. By default, the username for the application is "admin" and the password is "admin".

Once you login to the admin-console, you will notice a list of menu items on the left hand side of the screen. The right hand side of the screen is a multi-tabbed details page. So let's click on the "Applications" menu item on the left hand side menu. This shows a list of all applications on the server. Each of these applications is categorized based on the type of the application. Some of the categories are : EJB2.x application, EJB3.x application, WAR, EAR, MC beans. There's also Embedded WARs - these are WAR files which are deployed within an EAR file. Apart from applications, the admin-console also displays resources like JMS factories, JMS destinations (queues/topics), datasources. For each of these applications and resources, the admin-console shows the status (UP/DOWN) of those applications/resources. You can delete existing resources or applications by clicking on the "Delete" button on the details page.

The admin-console allows you to deploy new applications (WAR, EAR etc...) and also add new resources. So let's see how to deploy an EAR file. On the left hand side menu, click on the Enterprise Application (EARs) link under the Applications. Then on the details page, you will notice a "Add a new resource" button. Click on it. Use the Browse button to select the EAR you want to deploy. This page also gives you an option to deploy the EAR either as an archive or in a exploded format. Select appropriate option and click Continue. That's it, if the application is deployed successfully, you will see an appropriate message and also the status of the application will be shown as "UP". For all those who want to deploy applications in the traditional way (copying to deploy folder), you can still do it. The admin-console dynamically updates it list of deployed applications and on the next refresh, you will notice your application being listed.

As i mentioned earlier, the details page is a multi-tabbed page. It has a Metrics tab, Control tab, Configuration tab etc... So let's see what the "Control" tab can be used for. Select the Enterprise Application link (from the left hand menu) and drill down to the application of your choice. Then click on the "Control" tab. You will notice options to "Start", "Stop" and "Restart" the application. The other tabs like "Configuration", "Metrics" show many details about the selected application or resource.

Overall, the admin-console is a great addition to JBoss AS and provides that you expect from a decent admin-console. Users who have long waited for such an admin-console in JBoss will finally get what they asked for! So go to the JBossAS download page and get the latest 5.1.0.CR1 version and start playing with the console.

As always, if you have any suggestions or issues to report, feel free to do so in the Embedded Jopr forum.

6 comments:

Giri Vardhan said...

I have installed the new jboss AS verion 5.1.0 AS.
I am able to run Jboss and load the war file into it and run the application. The application works file.
As per my project objective I wanted to run JBoss as a service.
I created the jboss service in Windows by running the following command: service.bat install
The windows service is created and JBoss listens to the default port 8080, but the admin-console doesn't come up and also the appliciton doesn't work.
Is there any other configurtion setting I need to do?

Giri

Anonymous said...

Is there a way to change the deploy location of the application while deploying from admin console ? (that is application by default gets deplyoed in /JBOSS_HOME/server//deploy . How to change this location ?

Divya said...

Does admin-console provide a feature like to start an application serving after deployment like in weblogic.

Jaikiran said...

Divya, once the application is deployed via the admin-console, it is automatically available for access (assuming it deployed successfully). Is that what you were asking about?

Sathish said...

Hi,

We are using JBoss 4.0.2 with Liferay content management portal as our corporate site.

The default page will be our corporate site home page.

Now, I am trying to open the admin console to do deployments and other admin stuff.
But I am not able to get this page. As soon as I type the url http://siteaddress.com/admin-console it goes to our corporate site home page.

So, hw to access the admin console.

Please help.

Thanks in advance.

Anonymous said...

The one issue I have tried to resolve is a 3rd party penetration test coming back and flagging the admin console as a major security issue. The reason is the login form is not encrypted and the only way that you can encrypt it is to force SSL via Apache HTTPD. I haven't found a way to do that without hosing the JMX and other web apps. I now am looking to remove the admin console altogether.