Has anybody solved the docker hostname problem?

32 views
Skip to first unread message

Timothy Ehlers

unread,
Nov 9, 2016, 10:48:32 AM11/9/16
to metrics-user
We are having a big problem with how docker + dropwizard + hostname are setup.

Most users either use the hostname or maybe dropwizard does it by default. The problem comes when you use Mesos/ECS whatever and a container has a problem and gets restarted repeatidly.

For example in 7 days one of my apps restarted 110,000 times filling my graphite disk.
stats.gauges.foo-app.asdb78213as.metric.foo
stats.gauges.foo-app.haeer78213as.metric.foo
stats.gauges.foo-app.zdfadfs3as.metric.foo
stats.gauges.foo-app.earer78213as.metric.foo
stats.gauges.foo-app.aasdf78213as.metric.foo
stats.gauges.foo-app.bhnm8213as.metric.foo

What i'd like to do is something like this, maybe using service discovery to see what other hosts are up and just naming yourself server1/2/3/4/5 based on the count:
stats.gauges.foo-app.server1.metric.foo
stats.gauges.foo-app.server2.metric.foo
stats.gauges.foo-app.server3.metric.foo
stats.gauges.foo-app.server4.metric.foo
stats.gauges.foo-app.server5.metric.foo


Has anybody solved this problem? and yes i know the first problem is the app shouldn't restart 110k times in 7 days.

Erik van Oosten

unread,
Nov 25, 2016, 4:03:23 AM11/25/16
to metric...@googlegroups.com

We pass the hostname to use for metrics via an environment property.

Kind regards,
    Erik.


Op 09-11-16 om 16:48 schreef Timothy Ehlers:
--
You received this message because you are subscribed to the Google Groups "metrics-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email to metrics-user...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages