I'm trying forward to another host when error occurs. I have this, and works:
<VirtualHost *:80>
ServerName test.com.
ServerAlias test.com
ProxyPreserveHost On
ProxyPass / http://127.0.0.1:8080/
ProxyPassReverse / http://127.0.0.1:8080/
RewriteEngine on
ErrorDocument 503 /503/
RewriteCond %{REQUEST_URI} ^/503/$
RewriteRule ^(.*)$ http://other.host.com/
</VirtualHost>
Now, when I have this URL: http://test.com/path/?param1=val1¶m2=val2
and when 503 error ocurrs, I want redirect to new URL: http://other.host.com/path/?param1=val1¶m2=val2
.
It is possible forward /path/?param1=val1¶m2=val2 to new host?
I have seen this and this, but it is not exactly my problem.
PS: I'm running a java application, not a php application