VibhorGupta1991 commented on issue #8185:
URL: https://github.com/apache/trafficserver/issues/8185#issuecomment-901832669
Hi shukitchan,
Sorry for the delay, had been struggling with few other things so didn't
find time to look at this.
About your queries:
1) Yes, we would eventually want to run the same transform on both the
original and retry response but for now only running the transform also works.
Few queries about the do_os_response method, can you confirm?
a) Only one of the functions either do_remap or do_os_response gets called
for a transaction?
b) I believe only few hooks can be attached in the do_os_response function,
so I can't attach other hooks in do_remap() which are not allowed in
do_os_response?
c) I can't find any documentation around this do_os_response() function
hence struggling a little bit with it.
2) I am trying to use do_os_response as per your suggestion but my response
is not getting modified even for the original response. I even tried to put a
debug message in the do_os_response() function but it doesn't get called it
seems. Is there something I am doing wrong here?
function do_os_response()
ts.debug("HELLO")
ts.hook(TS_LUA_RESPONSE_TRANSFORM,modify_response)
end
Please find the remap statement for escalate and lua plugin below:
map / http://server.com @plugin=/usr/local/libexec/trafficserver/escalate.so
@pparam=500,404:retry.com @pparam=--pristine
@plugin=/usr/local/libexec/trafficserver/tslua.so
@pparam=/usr/local/etc/trafficserver/script/L1/simple.lua
Thanks in advance.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]