Documentation ¶
Index ¶
- func BoolFieldQuery(value bool, field string) *query.BoolFieldQuery
- func MatchPhraseQuery(matchPhrase, field, analyzer string, fuzziness int) *query.MatchPhraseQuery
- func NumericEqualityQuery(value int64, field string) *query.NumericRangeQuery
- func NumericRangeInclusiveQuery(min, max optional.Option[int64], field string) *query.NumericRangeQuery
- type FlushingBatch
- type Indexer
- type MappingGetter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BoolFieldQuery ¶
func BoolFieldQuery(value bool, field string) *query.BoolFieldQuery
BoolFieldQuery generates a bool field query for the given value and field
func MatchPhraseQuery ¶
func MatchPhraseQuery(matchPhrase, field, analyzer string, fuzziness int) *query.MatchPhraseQuery
MatchPhraseQuery generates a match phrase query for the given phrase, field and analyzer
func NumericEqualityQuery ¶
func NumericEqualityQuery(value int64, field string) *query.NumericRangeQuery
NumericEqualityQuery generates a numeric equality query for the given value and field
Types ¶
type FlushingBatch ¶
type FlushingBatch struct {
// contains filtered or unexported fields
}
FlushingBatch is a batch of operations that automatically flushes to the underlying index once it reaches a certain size.
func NewFlushingBatch ¶
func NewFlushingBatch(index bleve.Index, maxBatchSize int) *FlushingBatch
NewFlushingBatch creates a new flushing batch for the specified index. Once the number of operations in the batch reaches the specified limit, the batch automatically flushes its operations to the index.
func (*FlushingBatch) Delete ¶
func (b *FlushingBatch) Delete(id string) error
Delete add a delete index to batch
func (*FlushingBatch) Flush ¶
func (b *FlushingBatch) Flush() error
Flush submit the batch and create a new one
type Indexer ¶
type Indexer struct { Indexer bleve.Index // contains filtered or unexported fields }
Indexer represents a basic bleve indexer implementation
func NewIndexer ¶
type MappingGetter ¶
type MappingGetter func() (mapping.IndexMapping, error)