JBoss Enterprise Application Platform 6.1 on Linux Enterprise Redhat

I have seen several examples on how to have Apache forward requests to JBoss. I am looking to have a JBoss server listening on port 80 forward cgi calls to an Apache server. Can JBoss be configured to listen at port 80 and forward all requests containing "cgi-bin" to port 8080 where Apache server is listening?

The need to do this arises from

  • Jboss not supporting cgi (mod_perl in my case) AFAIK
  • Since i am migrating from a server where all web requests used port 80, needing to keep the port as 80 to avoid programming changes
  • 99% server calls are handled by JBoss, so i want it to be the primary point of contact

有帮助吗?

解决方案

Despite JBoss handling the 99% of calls, the better architecture is to have Apache in front of JBoss.

You would have Apache serve port 80 and forward to JBoss via mod_cluster or mod_jk. This will allow you to control your content via Apache. You should serve your static content directly from Apache as well.

Additionally with this architecture, you can cluster your environment and load balance across multiple servers. This gives you higher fault tolerance (session replication, failover), handle more load, and helps you avoid server outages.

mod_cluster is recommended for EAP 6, but mod_jk works just fine too.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top