URL rewriting?

From: Chris Charman <chris#bizo.com>
Date: Wed, 27 Aug 2008 11:02:51 -0700

I'm trying to see if I can do URL rewriting on the backend. First of all, is that possible?

Here's a snippet of my config:

backend data

        mode http
        log global
        # Rewrite the request to map old URLs to new services

       reqirep ^(GET\ .*)(/BzServices.*)?(.*)(clientredirurl)(.*$)

       reqirep ^(POST\ .*)(/BzServices.*)?(.*)(clientredirurl)(.*$)

       reqirep ^(GET\ .*)(/BzServices/DemographicQuery.aspx)?(.*$)

       reqirep ^(POST\ .*)(/BzServices/DemographicQuery.aspx)?(.*$)

       reqirep ^(GET\ .*)(/BzServices.*)?(.*$)

       reqirep ^(POST\ .*)(/BzServices.*)?(.*$)

        option httpchk HEAD /__LB_TEST.html
        server host01 hostname:port check
        server z_nothing               localhost:18000 backup check
# end backend data

Here's what I'm getting in the logs:
Aug 27 17:54:44 localhost.localdomain haproxy[24655]:[27/Aug/2008:17:54:44.391] http_in data/<NOSRV> -1/-1/-1/-1/3 400 187 - -
PR-- 0/0/0/0/0 0/0 {data.mydomain.co|Mozilla/5.0 (Mac||} {} "GET /BzServices/Redirect.aspx?partnerid=42 HTTP/1.1"

Is this even possible? It doesn't seem to matter if I put the rewrite rules in the frontend or the backend.

Do I need to point this at an http server running mod_rewrite or something?

Thanks in advance...

-Chris Received on 2008/08/27 20:02

This archive was generated by hypermail 2.2.0 : 2008/08/27 20:15 CEST