trafficserver icon indicating copy to clipboard operation
trafficserver copied to clipboard

stats_over_http c++/ipmap updates

Open ezelkow1 opened this issue 4 years ago • 6 comments

convert to c++ plugin move ip allow setup to use ipmap if a config is used link it to remap to initiate plugin reload on config change

ezelkow1 avatar Sep 20 '21 19:09 ezelkow1

@SolidWallOfCode is going to review this

bryancall avatar Sep 20 '21 23:09 bryancall

Just some notes for myself. After some discussions we want to:

  • Remove the default of _stats when being used as a remap plugin, so that the remap itself becomes the endpoint
  • Still allow setting of the path via config file when running as a remap

This would let you do map http://mystats.com http://whatever.com @plugin=stats_over_http.so and just be able to hit stats without the _stats endpoint on a remap. It would still be optionally available via the config file though for things like ATC which would require this.

We still want to leave the global usage as is, allowing a config or if the file doesnt exist use the param as the path, or default to _stats just because global usage needs its own path. On a remap though it will be config file based or nothing at all

ezelkow1 avatar Dec 02 '21 15:12 ezelkow1

Strike that, reverse it :)

So we are just taking out the remap usage all together. Much of how this plugin works is legacy implementations, so if we want a remap plugin that can serve stats it should be done as just a whole new plugin written properly and so that it can be chained with other plugins.

For now removing the new remap functionality. I will leave the existing rewrite though as we still need the proper IP parsing/map but for remap it should be a new plugin designed around using the ServerIntercept

ezelkow1 avatar Dec 02 '21 15:12 ezelkow1

[approve ci rocky]

ezelkow1 avatar Feb 18 '22 21:02 ezelkow1

See https://github.com/apache/trafficserver/pull/8797 for stats_over_http reimplemented as a ServerIntercept.

randall avatar Apr 18 '22 20:04 randall

We have been running with this in production for a good while now

ezelkow1 avatar Aug 11 '22 16:08 ezelkow1