I also have an open pull request : https://github.com/apache/trafficserver/pull/351 that does exactly this, as you've observed with transformations it's unable to block the downstream connection and so this pull request exposes a new API to buffer the request body before allowing the downstream connection to be established. The pull request also contains sample plugins for both the C and C++ apis.
Brian On Thu, Apr 7, 2016 at 4:43 PM, Nick Kew <n...@apache.org> wrote: > On Tue, 2016-04-05 at 23:19 -0700, Rakesh Chhabra wrote: > > Hi, > > > > I need to write an ATS plugin where i need to get the post body and a few > > request headers in the call. And based on certain condition i want to > > return the OK response from ATS itself without forwarding it to any > origin > > server. > > Ironbee does that, including both the basics and workarounds > for a number of glitches. Might be worth taking something > from it as a startingpoint. > > -- > Nick Kew > >