The storage read service would return a nil cursor if there was no data
and no shards to read from. This modifies it to return an empty cursor
instead.
(cherry picked from commit 2852bf0399
)
Co-authored-by: Jonathan A. Sternberg <jonathan@influxdata.com>
pull/20951/head
parent
df46a86326
commit
849221b709
|
@ -207,8 +207,8 @@ func (s *Store) TagKeys(ctx context.Context, req *datatypes.TagKeysRequest) (cur
|
|||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if len(shardIDs) == 0 { // TODO(jeff): this was a typed nil
|
||||
return nil, nil
|
||||
if len(shardIDs) == 0 {
|
||||
return cursors.NewStringSliceIterator(nil), nil
|
||||
}
|
||||
|
||||
var expr influxql.Expr
|
||||
|
@ -282,8 +282,8 @@ func (s *Store) TagValues(ctx context.Context, req *datatypes.TagValuesRequest)
|
|||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if len(shardIDs) == 0 { // TODO(jeff): this was a typed nil
|
||||
return nil, nil
|
||||
if len(shardIDs) == 0 {
|
||||
return cursors.NewStringSliceIterator(nil), nil
|
||||
}
|
||||
|
||||
var expr influxql.Expr
|
||||
|
|
Loading…
Reference in New Issue