Documentation ¶
Index ¶
- func FromRPCFetchTaggedRequest(req *rpc.FetchTaggedRequest, pools FetchTaggedConversionPools) (ident.ID, index.Query, index.QueryOptions, bool, error)
- func FromRPCQuery(query *rpc.Query) (idx.Query, error)
- func ToDuration(timeType rpc.TimeType) (time.Duration, error)
- func ToRPCError(err error) *rpc.Error
- func ToRPCFetchTaggedRequest(ns ident.ID, q index.Query, opts index.QueryOptions, fetchData bool) (rpc.FetchTaggedRequest, error)
- func ToTagsIter(r *rpc.WriteTaggedRequest) (ident.TagIterator, error)
- func ToTime(value int64, timeType rpc.TimeType) (time.Time, error)
- func ToTimeType(unit xtime.Unit) (rpc.TimeType, error)
- func ToUnit(timeType rpc.TimeType) (xtime.Unit, error)
- func ToValue(t time.Time, timeType rpc.TimeType) (int64, error)
- type FetchTaggedConversionPools
- type ToSegmentsResult
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FromRPCFetchTaggedRequest ¶
func FromRPCFetchTaggedRequest( req *rpc.FetchTaggedRequest, pools FetchTaggedConversionPools, ) (ident.ID, index.Query, index.QueryOptions, bool, error)
FromRPCFetchTaggedRequest converts the rpc request type for FetchTaggedRequest into corresponding Go API types.
func FromRPCQuery ¶
FromRPCQuery will create a m3ninx index query from an RPC query
func ToDuration ¶
ToDuration converts a time type to a duration
func ToRPCError ¶
ToRPCError converts a server error to a RPC error.
func ToRPCFetchTaggedRequest ¶
func ToRPCFetchTaggedRequest( ns ident.ID, q index.Query, opts index.QueryOptions, fetchData bool, ) (rpc.FetchTaggedRequest, error)
ToRPCFetchTaggedRequest converts the Go `client/` types into rpc request type for FetchTaggedRequest.
func ToTagsIter ¶
func ToTagsIter(r *rpc.WriteTaggedRequest) (ident.TagIterator, error)
ToTagsIter returns a tag iterator over the given request.
func ToTimeType ¶
ToTimeType converts a unit to a time type
Types ¶
type FetchTaggedConversionPools ¶
type FetchTaggedConversionPools interface { // ID returns an ident.Pool ID() ident.Pool // CheckedBytesWrapperPool returns a CheckedBytesWrapperPool. CheckedBytesWrapper() xpool.CheckedBytesWrapperPool }
FetchTaggedConversionPools allows users to pass a pool for conversions.
type ToSegmentsResult ¶
ToSegmentsResult is the result of a convert to segments call, if the segments were merged then checksum is ptr to the checksum otherwise it is nil.
func ToSegments ¶
func ToSegments(blocks []xio.BlockReader) (ToSegmentsResult, error)
ToSegments converts a list of blocks to segments.