How can I customize "http_response" plugin output for telegraf

telegraf
#1

In http_response plugin how can I customize the default output value “http_response” to something specific to my application say “MyWebApp1”

Default Output is:
http_response,method=GET,server=http://www.github.com http_response_code=200i,response_time=6.223266528 1459419354977857955

Desired Output:
MyWebApp1,method=GET,server=http://www.github.com http_response_code=200i,response_time=6.223266528 1459419354977857955

#2

You can use the name_override input configuration option:

[[inputs.http_response]]
  name_override = "MyWebApp1"
2 Likes
#3

That helps, thank you very much

#4

Hello,
How can i overriide the server=http://www.github.com name,
The URL i use for http_response is a big one and has almost 100 chars.
i want output like server = server1

Default Output is:
http_response,method=GET,server=http://www.github.com http_response_code=200i,response_time=6.223266528 1459419354977857955

Desired Output:
http_response,method=GET,server=server1
http_response_code=200i,response_time=6.223266528 1459419354977857955