Forum Discussion

dragonflymr's avatar
dragonflymr
Icon for Cirrostratus rankCirrostratus
May 20, 2015

How to rewrite URL returned from AAM cache

Hi,

 

I am trying to rewrite URL (host part) of responses. It works OK when there is no AAM cache used (more precisely it's IBR) but can't figure out how to do that when request is served from AAM cache.

 

So I am entering http2.shop.company.com in browser, Host header is replaced in iRule by shop.company.com and then request is send to target server. That is working without cache enabled.

 

When IBR is enabled I can see that responses are containing URLs https://shop.company.com/some_resource.

 

I tried to rewrite those using STREAM in HTTP_RESPONSE event but it seems to not be triggered at all when content is served from cache. Tried to use CACHE_REQUEST and CACHE_RESPONSE but those as well are not triggered.

 

So I am puzzled how to intercept those responses from cache and rewrite URLs

 

Piotr

 

No RepliesBe the first to reply