Using Tomcat with Apache via mod_webapp

Loto

Registered
I have attempted to configure the HTTPD.conf file to use the mod_webapp add-on using the following code offered by Apple. http://developer.apple.com/internet/macosx/tomcat1.html

LoadModule webapp_module libexec/httpd/mod_webapp.so

AddModule mod_webapp.c

<IfModule mod_webapp.c>

WebAppConnection warpConnection warp localhost:8008
WebAppDeploy examples warpConnection /examples/

</IfModule>

This didn't seem to work. Has anyone had any success setting this up?

I'm NEW to UNIX and I would appreciate any help!

Thanks,
 
Hi Buddy!

Yes!! I spend all day yesterday setting it up - always had one re-occuring problem with all the developer.apple.com examples - for Hi and Mail it would always give me a 404 (file not available in the Tomcat Error Message style [ blue and white sort of...]).

Yes, I kept all the settings from the example. Only in web.xml in Mine, be sure to delete the other servlet references...
read through the web.xml inline documentation to decide what you need and don't need. I deleted the description and essentially only have the servlet thingy and the second servlet thingy part (don't have it in front of me, but essentially only include what the example gives).

Still, I kept on receiving the error message.

This is what I did to solve issue:

Normally my .class and .java files were in mine/WEB-INF/classes

Upon moving these files to mine/ (so essentially down two directories), I was able to "execute" them.

http://localhost:8080/mine/Hi
http://localhost:8080/mine/mail

put all of your .jsp files here, too.

http://localhost:8080/mine/test.jsp


Regarding your APACHE httpd.conf question. I am not quite sure what the problem is...

all you have to do is add the LoadModule and AddModule lines (as specified in developer.apple.com) and add the <IfModule tag thing

This last one simply says that now you don't have to specify 8080 when accessing the "examples" folder.

If these lines are the ones from the apple example, then this is exactly the same thing that I did.

reply if you have problems....

- pbmac
 
pbMac
After I used edit the httpd.conf file I restarted Apache, but I never received a 404 error. As a matter of fact, I attempted to load localhost and it wouldn't. I commented out the "If" portion of the code and restarted Apache and the success page loaded.
I've visted message boards all over and I have seen dozens of variations of the same code. But none of the changes yielded a positive result.
I'll take a look at the web.xml documentation.

Additionally, I want to include what I hope to achieve. I want Apache to handle the static portion of a site and have it pass off the .jsp portions to Tomcat.
Does this sound right?

Thanks,
Loto

Titanium 500
G4 500
 
I have been having some problems too. For starters, there are no examples when I am going from jakobie.net:8080. I get the sucsess page, but errors on the example pages. When I changed httpd.conf, and went to jakobie.net/exmples I get my 404.
 
Nevermind. I was renaming jakarta...... to something a little bit easier to type like simply, tomcat. I reinstalled keeping the name the same, and everything works now.
:)
 
I know this is an old thread, but I have a related question.

I found that Macromedia now has an OS X Specific installer for JRun 4.

However I am stubmling when trying to make it work with Apache. It has an interface for doing that, but gives a useless error message that says "/Applications/Internet/JRun4/lib/wsconfig/1/mod_jrun.so (Not a directory)" .

../lib/wsconfig is there, but there is nothing under that...

What is it trying to do? Read or Write?

Is this a permissions thing? If it is writing, what user is it using?

Help!
 
Back
Top