Rewrite URL - Apache in front and jboss serving content

263 Views Asked by At

I have been trying to get this work for the last 2 days since I am relatively new to Apache server. This is what I am trying to do in my local machine.

  1. I have installed Apache Server and it acts as a front gate for all requests and sends them to JBOSS server. This is through AJP method.
  2. I have enabled the mod_rewrite in http.conf and I want to do a simple redirect in my localhost. Below is what I tried..

RewriteEngine on
RewriteRule ^first.html$ second.html

This is not working as the log says it is looking the files in the document root C:\Apacheserver\Apache2\htdocs and i dont have any files in this location as the file comes from JBOSS(For ex: C:/jboss4.0/jboss-4.0.3SP1/server/MyApp/deploy/unisysv2.ear/web-app.war).

How do I make this redirect work under this condition.

Thanks

1

There are 1 best solutions below

0
On

You should configure "bridge" between Apache an JBoss. Use mod_jk module or mod_proxy for that purpose, which are implementation of ajp communication protocol between Apache and JBoss.