1 Reply Latest reply on Jun 29, 2011 12:40 AM by mp911de

    Apache Jboss and 500 Error

    gkrishna101

      Hi,

       

      We have our application running on JBOSS 4.2.3 fronted by apache 2.2 webserver. I am using mod_jk connector now. We are having intermittent issues with one of the JBoss server returning 500 error.

      Is there a way where the webserver can mark the app server down and not send request to that app server if it returns 500 error? Can mod_jk or mod_proxy do this?

       

      Thanks

      Ganesh

        • 1. Re: Apache Jboss and 500 Error
          mp911de

          Hi Ganesh,

          the best way to handle real 500 errors is to define an error-page in your web.xml

           

          <error-page>

          <error-code>500</error-code>

          <location>/someerror.html</location>

          </error-page>

           

          Bit when your server is down, it results to a 503 error. Then you can add to your Apache config:

           

          ErrorDocument 503 /service/server-down.html

           

          Best regards,

          Mark