{"action":"closed","issue":{"url":"https://api.github.com/repos/openzipkin/zipkin-java/issues/248","repository_url":"https://api.github.com/repos/openzipkin/zipkin-java","labels_url":"https://api.github.com/repos/openzipkin/zipkin-java/issues/248/labels{/name}","comments_url":"https://api.github.com/repos/openzipkin/zipkin-java/issues/248/comments","events_url":"https://api.github.com/repos/openzipkin/zipkin-java/issues/248/events","html_url":"https://github.com/openzipkin/zipkin-java/issues/248","id":156742146,"number":248,"title":"LazyCloseable could wait on exception","user":{"login":"adriancole","id":64215,"avatar_url":"https://avatars.githubusercontent.com/u/64215?v=3","gravatar_id":"","url":"https://api.github.com/users/adriancole","html_url":"https://github.com/adriancole","followers_url":"https://api.github.com/users/adriancole/followers","following_url":"https://api.github.com/users/adriancole/following{/other_user}","gists_url":"https://api.github.com/users/adriancole/gists{/gist_id}","starred_url":"https://api.github.com/users/adriancole/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adriancole/subscriptions","organizations_url":"https://api.github.com/users/adriancole/orgs","repos_url":"https://api.github.com/users/adriancole/repos","events_url":"https://api.github.com/users/adriancole/events{/privacy}","received_events_url":"https://api.github.com/users/adriancole/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":8,"created_at":"2016-05-25T12:48:34Z","updated_at":"2016-05-27T00:17:08Z","closed_at":"2016-05-27T00:17:08Z","body":"LazyCloseable (an internal class) is used for for network connections. The attempt to do something like creating a connection has a cost. It is even more expensive to try to do something like install a schema.\r\n\r\nThere was a comment on an otherwise unrelated issue that we should slow down attempts to connect to cassandra to [no more than once per second](https://github.com/openzipkin/zipkin-java/pull/240#discussion-diff-64503761).\r\n\r\nIn practice, there would only be one attempt per second if using brave because brave schedules span writes to a single thread, and that polling interval can be no shorter than one second. However, this \"being saved by the bell\" is something that only applies if using brave's base class, and wouldn't apply to normal collectors, which may have unbounded callers (who don't stand in a nice 1 second spaced line!).\r\n\r\nInstead of being \"saved by the bell\", we could make either a global decision or a configuration option available to slow down tries.\r\n\r\nFor example, making lazy closeables try no more than once per second is a simple thing we could do, even by hard-coding at first. By hard-coding, we don't give flexibility, but we also don't have to bubble up a configuration option through the several components that would be impacted.\r\n\r\nThoughts?"}}
{"actor":{"display_login":"adriancole"}}