www.grootersnet.nl

Web Services

Tomcat


Tomcat

First to install after Apache. Just follow the installation guide.

Even if you upgrade, don't forget to run @Sys$manager:apache$jakarta_configure:

1 should be done, since installation is typically done using the SYSTEM account, all files are owned by SYSTEM and so APACHE$WWW (SWS) will not be able to access them. This option will ask for tyhe username of the new owner; it should be the same as for apache (so: APACHE$WWW).

2 is a requirement as well, it will allow APACHE$WWW to access all files

3 is a requirement as well, it will add a line to apache$common:[conf]httpd.conf - be sure to choose for modjk2:

Include /SYS$COMMON/APACHE/JAKARTA/TOMCAT/CONF/JK2/MOD_JK2.CONF

4 shows the current configuration:

This is basically what's needed. 

Now stop Apache, if needed, and start Tomcat:

$ @sys$startup:apache$jakarta_startup

and when Tomcat startedm startup Apache:

$ @sys$startup:apache$startup

The basic Tomcat screen should now be accessable on port 8080:

To be able to access and use the Tomcat manager page, some extra work needs to be done; It involves changing a file in the Tomcat area: DKA0:[SYS0.SYSCOMMON.APACHE.JAKARTA.TOMCAT.conf]tomcat-users.xml

<?xml version='1.0' encoding='utf-8'?>
<tomcat-users>
<role rolename="tomcat"/>
<role rolename="role1"/>
<role rolename="standard"/>
<role rolename="manager"/>
<user username="tomcat" password="tomcat" roles="tomcat"/>
<user username="TheBoss" password="expected_to_be_secret" roles="standard,manager"/>
<user username="role1" password="tomcat" roles="role1"/>
<user username="both" password="tomcat" roles="tomcat,role1"/>
</tomcat-users>

The Bold Blue lines have been added, making the Tomcat Manager page accessable. 
(*use the right username and a proper password, of course!)

To access and use the Administrator pages, I guess you need to do something similar, with role "Admin" or something like that, but I haven't found that yet.

Mind that Tomcat needs to be stopped and started before this change is effective!

(This is rather normal. Don't ask why.)

VERY handy:

Define CATALINA$HOME and/or CATALINA_HOME to refer to the base directory of TOMCAT: 

$ a = F$TRNLNM("APACHE_COMMON") - "]"
$ DEFINE/SYSTEM/TRANSLATION=(Concelead, terminal) CATALINA$HOME 'a'JAKARTA.TOMCAT.] 

assuming you installed tomcat on it's default location (below apache$common). 
Now these configuration files can be accessed as catalina$home:[conf].

Check the examples (links are on the same page) to see it all works.

Now you can start using JSP pages, Java code access - so basic web services! However, if you want a more elaborate access, for example using callable services, think of SOAP - simple Object Access Protocol, as defined by IBM (for the java side) and Microsoft (for the .NET side).  Use the latest specification, for which the Apache Software Foundation has created a package named AXIS. 

Apache (Temporary link)

Axis

Back to WebServices

Back to HOWTO

Back to OpenVMS

Back Home


(c) 2003- 2006 W. Grooters    Last updated 20-11-2006