fluent-plugin-docker-metrics icon indicating copy to clipboard operation
fluent-plugin-docker-metrics copied to clipboard

"name" field should be basename, which doesn't include link information

Open Hi-king opened this issue 10 years ago • 2 comments
trafficstars

When we link some containers with another, sometimes this plugin generate fields which are dfficult to deal with (like containerA/containerB). As shown in the following sample, this happens for a reason of using Docker::Container.info method. With using Docker::Container.json, we can get basename of containers.

Docker::Container.all.map{|container| container.info['Names'] }
=> [["/fluentd"],  ["/fluentd/norikra", "/norikra"]]

Docker::Container.all.map{|container| container.json['Name'] }
=> ["/fluentd", "/norikra"]

Hi-king avatar Aug 10 '15 12:08 Hi-king

@funkymonkeymonk is the main maintainer now. What do you think, @funkymonkeymonk?

kiyoto avatar Nov 12 '15 23:11 kiyoto

I agree though this could break some workflows. Maybe there needs to be a name tag and a base name tag.

funkymonkeymonk avatar Nov 13 '15 14:11 funkymonkeymonk