{"action":"opened","issue":{"url":"https://api.github.com/repos/jackc/pgx/issues/154","repository_url":"https://api.github.com/repos/jackc/pgx","labels_url":"https://api.github.com/repos/jackc/pgx/issues/154/labels{/name}","comments_url":"https://api.github.com/repos/jackc/pgx/issues/154/comments","events_url":"https://api.github.com/repos/jackc/pgx/issues/154/events","html_url":"https://github.com/jackc/pgx/issues/154","id":159185807,"number":154,"title":"A couple of questions about pgx/stdlib","user":{"login":"achiku","id":783040,"avatar_url":"https://avatars.githubusercontent.com/u/783040?v=3","gravatar_id":"","url":"https://api.github.com/users/achiku","html_url":"https://github.com/achiku","followers_url":"https://api.github.com/users/achiku/followers","following_url":"https://api.github.com/users/achiku/following{/other_user}","gists_url":"https://api.github.com/users/achiku/gists{/gist_id}","starred_url":"https://api.github.com/users/achiku/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/achiku/subscriptions","organizations_url":"https://api.github.com/users/achiku/orgs","repos_url":"https://api.github.com/users/achiku/repos","events_url":"https://api.github.com/users/achiku/events{/privacy}","received_events_url":"https://api.github.com/users/achiku/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2016-06-08T14:58:34Z","updated_at":"2016-06-08T14:58:34Z","closed_at":null,"body":"- When `*sql.DB` is created using `stdlib.OpenFromConnPool`, is it true that only one connection is used during its life cycle?\r\n    * `stdlib.Open` checks if `*stdlib.Driver` has `pgx.ConnPool`, and if it does, acqires `*pgx.Conn`. This `*pgx.Conn` is not released until `stdlib.Conn.Close` is called (inside `stdlib.Conn.Close`, `ConnPool.Release` is called and `*pgx.Conn` is returned to `pgx.ConnPool`)\r\n    * I may be wrong at all, so I wrote this piece of test case, but it seems like it uses multiple connections.\r\n    * https://github.com/achiku/sample-golang-pgx-stdlib/blob/master/main_test.go#L302\r\n- Is it possible to add `pgx.ConnPool.Acquire` type of method to `stdlib.Driver` or some other place that returns `*stdlib.Conn`? Since we are trying to use PostgreSQL session level advisory lock throughout the process, it is really helpful if we can acquire and release a connection from the pool, and execute query on the same connection (I know it is possible to keep using the same connection if we start transaction, but need to use normal connection in our case..).\r\n"}}
{"actor":{"display_login":"achiku"}}