Skip to content

Commit

Permalink
Merge pull request #334 from uber-go/v3-multidoc
Browse files Browse the repository at this point in the history
Add comment discouraging MultiRead
  • Loading branch information
phliar authored May 30, 2018
2 parents 78d1bed + 271e696 commit 3e39c50
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions client.go
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,9 @@ type Client interface {
// Otherwise the DomainObject as key and an error message as value will be saved into
// MultiResult map.
// NOTE: This API only fetches objects of same entity type from same scope.
//
// Range should be preferred over MultiRead. If you are not sure which endpoint to use,
// use Range instead of MultiRead.
MultiRead(context.Context, []string, ...DomainObject) (MultiResult, error)

// Upsert creates or update a row. A list of fields to update can be
Expand All @@ -176,6 +179,9 @@ type Client interface {
// TODO: Coming in v2.1
// MultiUpsert creates or updates multiple rows. A list of fields to
// update can be specified. Use All() or nil for all fields.
//
// Upsert should be preferred over MultiUpsert. If you are not sure which endpoint to use,
// use Upsert instead of MultiUpsert.
// MultiUpsert(context.Context, []string, ...DomainObject) (MultiResult, error)

// Remove removes a row by primary key. The passed-in entity should contain
Expand Down

0 comments on commit 3e39c50

Please sign in to comment.