]> Cypherpunks repositories - gostls13.git/commit
database/sql: add context helper methods and transaction types
authorDaniel Theophanes <kardianos@gmail.com>
Mon, 17 Oct 2016 06:11:55 +0000 (23:11 -0700)
committerBrad Fitzpatrick <bradfitz@golang.org>
Sun, 30 Oct 2016 17:05:28 +0000 (17:05 +0000)
commitce6aa2ebdab0c6616ef17acc9282b0e168f5f21a
treed2760dee9bb27c34f113f15152b72431b1d1497c
parent042264ef1b073b1b485e6e24977e506e1a6bdb3f
database/sql: add context helper methods and transaction types

Prior to this change, it was implied that transaction properties
would be carried in the context value. However, no such properties
were defined, not even common ones. Define two common properties:
isolation level and read-only. Drivers may choose to support
additional transaction properties. It is not expected any
further transaction properties will be added in the future.

Change-Id: I2f680115a14a1333c65ba6f943d9a1149d412918
Reviewed-on: https://go-review.googlesource.com/31258
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
src/database/sql/ctxutil.go
src/database/sql/driver/driver.go
src/database/sql/internal/types.go [new file with mode: 0644]
src/database/sql/sql.go
src/go/build/deps_test.go