|
datastore: Update AllocateIDs to take keys.
Update the Datastore's AllocateIDs call to accept variadic arguments similar
to Get/Put/Delete/Exists. Structs can be supplied to populate their keys
directly, and keys or key slices can be supplied to directly allocate keys.
This adds some Key helper functions:
- SameKind, which asserts that keys reference the same kind.
- Partial, which returns a partial key given a source key.
- WithID, which returns a derivative key with the specified ID.
- NewIncompleteKeys, which allocates a slice of incomplete keys given a kind.
BUG=
Committed: https://github.com/luci/gae/commit/a212da0491a31a03fb1e9fb21a328ac1dc72354c
Total comments: 1
Total comments: 11
|
Unified diffs |
Side-by-side diffs |
Delta from patch set |
Stats (+599 lines, -183 lines) |
Patch |
 |
M |
filter/count/rds.go
|
View
|
1
2
3
|
2 chunks |
+3 lines, -4 lines |
0 comments
|
Download
|
 |
M |
filter/dscache/ds.go
|
View
|
1
2
3
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
filter/dscache/ds_txn.go
|
View
|
1
2
3
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
filter/dscache/support.go
|
View
|
1
2
3
|
2 chunks |
+2 lines, -2 lines |
0 comments
|
Download
|
 |
M |
filter/featureBreaker/rds.go
|
View
|
1
2
3
|
2 chunks |
+4 lines, -7 lines |
0 comments
|
Download
|
 |
M |
filter/txnBuf/ds_txn.go
|
View
|
1
2
3
|
1 chunk |
+3 lines, -3 lines |
0 comments
|
Download
|
 |
M |
filter/txnBuf/state.go
|
View
|
1
2
3
|
1 chunk |
+41 lines, -19 lines |
0 comments
|
Download
|
 |
M |
filter/txnBuf/txnbuf_test.go
|
View
|
1
2
3
|
1 chunk |
+3 lines, -2 lines |
0 comments
|
Download
|
 |
M |
impl/dummy/dummy.go
|
View
|
1
2
3
|
1 chunk |
+2 lines, -6 lines |
0 comments
|
Download
|
 |
M |
impl/memory/datastore.go
|
View
|
1
2
3
|
2 chunks |
+6 lines, -6 lines |
0 comments
|
Download
|
 |
M |
impl/memory/datastore_data.go
|
View
|
1
2
3
|
4 chunks |
+44 lines, -8 lines |
0 comments
|
Download
|
 |
M |
impl/memory/datastore_test.go
|
View
|
1
2
3
|
1 chunk |
+14 lines, -3 lines |
0 comments
|
Download
|
 |
M |
impl/prod/everything_test.go
|
View
|
1
2
3
|
1 chunk |
+9 lines, -2 lines |
0 comments
|
Download
|
 |
M |
impl/prod/raw_datastore.go
|
View
|
1
2
3
|
2 chunks |
+42 lines, -7 lines |
0 comments
|
Download
|
 |
M |
service/datastore/checkfilter.go
|
View
|
1
2
3
|
4 chunks |
+3 lines, -13 lines |
0 comments
|
Download
|
 |
M |
service/datastore/checkfilter_test.go
|
View
|
1
2
3
|
1 chunk |
+2 lines, -1 line |
0 comments
|
Download
|
 |
M |
service/datastore/datastore.go
|
View
|
1
2
3
|
13 chunks |
+117 lines, -23 lines |
0 comments
|
Download
|
 |
M |
service/datastore/datastore_test.go
|
View
|
1
2
3
|
10 chunks |
+115 lines, -15 lines |
0 comments
|
Download
|
 |
M |
service/datastore/finalized_query.go
|
View
|
1
2
3
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
service/datastore/interface.go
|
View
|
1
2
3
|
3 chunks |
+35 lines, -7 lines |
0 comments
|
Download
|
 |
M |
service/datastore/key.go
|
View
|
1
2
3
|
5 chunks |
+49 lines, -11 lines |
0 comments
|
Download
|
 |
M |
service/datastore/key_test.go
|
View
|
1
2
3
|
1 chunk |
+2 lines, -2 lines |
0 comments
|
Download
|
 |
M |
service/datastore/multiarg.go
|
View
|
1
2
3
|
8 chunks |
+89 lines, -30 lines |
0 comments
|
Download
|
 |
M |
service/datastore/raw_interface.go
|
View
|
1
2
3
|
4 chunks |
+11 lines, -9 lines |
0 comments
|
Download
|
Depends on Patchset:
Total messages: 11 (5 generated)
|