{"action":"created","issue":{"url":"https://api.github.com/repos/prometheus/prometheus/issues/608","labels_url":"https://api.github.com/repos/prometheus/prometheus/issues/608/labels{/name}","comments_url":"https://api.github.com/repos/prometheus/prometheus/issues/608/comments","events_url":"https://api.github.com/repos/prometheus/prometheus/issues/608/events","html_url":"https://github.com/prometheus/prometheus/pull/608","id":63411669,"number":608,"title":"Add `sd_lookup_type` config option, to allow TCP or UDP","user":{"login":"ewr","id":204350,"avatar_url":"https://avatars.githubusercontent.com/u/204350?v=3","gravatar_id":"","url":"https://api.github.com/users/ewr","html_url":"https://github.com/ewr","followers_url":"https://api.github.com/users/ewr/followers","following_url":"https://api.github.com/users/ewr/following{/other_user}","gists_url":"https://api.github.com/users/ewr/gists{/gist_id}","starred_url":"https://api.github.com/users/ewr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ewr/subscriptions","organizations_url":"https://api.github.com/users/ewr/orgs","repos_url":"https://api.github.com/users/ewr/repos","events_url":"https://api.github.com/users/ewr/events{/privacy}","received_events_url":"https://api.github.com/users/ewr/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-03-21T14:30:43Z","updated_at":"2015-03-21T17:58:00Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/prometheus/prometheus/pulls/608","html_url":"https://github.com/prometheus/prometheus/pull/608","diff_url":"https://github.com/prometheus/prometheus/pull/608.diff","patch_url":"https://github.com/prometheus/prometheus/pull/608.patch"},"body":"I'm using Consul's DNS for discovery SRV records. Yesterday while I was trying to figure out why my graphs had lots of gaps in them, I discovered that Consul only returns three records for a SRV request made over UDP, but will return all configured records for a request made over TCP. When I had more than three nodes registered for a service, the UDP query was getting a random three each time.\r\n\r\nThis change adds an optional `sd_lookup_type` to the job config, allowing you to specify \"tcp\" on a per-job basis (mainly because it was easier than figuring out how to pass a global config setting through).\r\n\r\nDefault is `udp`, which matches the existing default when we weren't providing a setting.\r\n\r\nI'll probably just switch over to using something like consul-template to write a non-SD config for now, but this seemed like an easy and innocuous enough change that I thought I would propose it."},"comment":{"url":"https://api.github.com/repos/prometheus/prometheus/issues/comments/84410681","html_url":"https://github.com/prometheus/prometheus/pull/608#issuecomment-84410681","issue_url":"https://api.github.com/repos/prometheus/prometheus/issues/608","id":84410681,"user":{"login":"juliusv","id":538008,"avatar_url":"https://avatars.githubusercontent.com/u/538008?v=3","gravatar_id":"","url":"https://api.github.com/users/juliusv","html_url":"https://github.com/juliusv","followers_url":"https://api.github.com/users/juliusv/followers","following_url":"https://api.github.com/users/juliusv/following{/other_user}","gists_url":"https://api.github.com/users/juliusv/gists{/gist_id}","starred_url":"https://api.github.com/users/juliusv/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/juliusv/subscriptions","organizations_url":"https://api.github.com/users/juliusv/orgs","repos_url":"https://api.github.com/users/juliusv/repos","events_url":"https://api.github.com/users/juliusv/events{/privacy}","received_events_url":"https://api.github.com/users/juliusv/received_events","type":"User","site_admin":false},"created_at":"2015-03-21T17:58:00Z","updated_at":"2015-03-21T17:58:00Z","body":"@matthiasr Why would it make sense to only return three records when you request all? We don't hit this problem because we're not serving DNS directly by Consul (I think that was way too slow, or maybe there were other problems as well, such as this one)."}}