Using the Web Console


Before delving into the specifics of how to work with the Web console, it is important to understand the basic setup of what you will be seeing, as well as how to actually access this important tool.

Web Console Architecture

The Web console is implemented as a set of portlets. Portlets are mini-applications that interact with the user as a rectangular area within a displayed Web page. The portlets in the Geronimo console are created using Apache Pluto. Geronimo has the Pluto libraries in its repository, allowing developers to use the portlet technology in any applications deployed to Geronimo. The programming API and object model for portlet programming is the subject matter of JSR-168 (see www.jcp.org/en/jsr/detail?id=168 for more information).

The Web console itself is a Web application running on Geronimo. In fact, if you examine the startup message of the Geronimo server, you should see the Web console application loading in messages similar to the following:

 Started Application Modules:   EAR: geronimo/webconsole-tomcat/1.1/car   RAR: geronimo/activemq/1.1/car   RAR: geronimo/system-database/1.1/car   WAR: geronimo/remote-deploy-tomcat/1.1/car   WAR: geronimo/welcome-tomcat/1.1/car Web Applications:   http://myhost:8080/   http://myhost:8080/console   http://myhost:8080/console-standard   http://myhost/remote-deploy

In the top-right corner of each portlet window, there is usually a help and view links. Clicking on the help link provides a page of help information. You will find some very useful information in these help pages. Many common questions and usage patterns for each portlet are fully documented in the help pages. If you click the view link, it will take you right back to the functional page of the portlet itself.

Logging on to the Web Console

You can access the Geronimo Web console at the following URL:

http://localhost:8080/console/

You will need to log in before using the console. The default user=system, password=manager will work for console login. Figure 8-1 shows the Geronimo Web console login page.

image from book
Figure 8-1: Logging on to the Geronimo Web console

The menus are on the left-hand side. You can add additional users who are allowed to access the console.

Adding More Console Users

If you need to add users, they may be added to the default console security realm by selecting the SecurityConsole Realm menu.

For our purposes, a security realm can be thought of as a database containing user, group, and password information. Chapter 15 explores in more details of exactly what a security realm is.

By default, the console realm uses the server-wide default geronimo-properties security realm.

Editing Properties Files

This realm makes use of two property files in the var/security directory, namely the following files:

  • groups.properties - Specifies the groups and the users in them

  • users.properties - Specifies the users and passwords

Let’s add a user called bruce with the password test. First, add the user bruce to the admin group. The admin group is the group that includes the Web console users. This can be done by adding the user bruce to the groups.properties file, shown in bold in the following listing:

 admin=system,bruce 

Next, add a line with the user bruce and the password test in the users.properties file. This addition is shown in the following listing:

 system=manager bruce=test

That’s it. Now, start the Geronimo server and try logging in with the new user. Now you can use either system/manager or bruce/test for accessing the Geronimo Web console.

Adding a New User through Web Console

To add the same user via the Web console, follow these steps:

  1. Select SecurityConsole Realm menu.

  2. Click on the Create New User link in the Console Realm users portlet.

  3. Add the new user bruce with password test.

  4. Click on the admin group link in the Console Realm Groups portlet.

  5. Add the bruce user to the group by clicking the Add button, then the Update button.

This series of action performs exactly the same task as editing the properties files. If you check the users.properties and groups.properties file, you can verify the change.




Professional Apache Geronimo
Professional Apache Geronimo (Wrox Professional Guides)
ISBN: 0471785431
EAN: 2147483647
Year: 2004
Pages: 148

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net