Documentation ¶
Index ¶
- Variables
- func Cert(cert string) func(*solrHttp)
- func ClusterStateVersion(version int, collection string) func(url.Values)
- func Commit(commit bool) func(url.Values)
- func ConnectionTimeout(seconds int) func(*solrHttp)
- func Cursor(c string) func(url.Values)
- func DefaultRows(rows uint32) func(*solrHttp)
- func DeleteStreamBody(filter string) func(url.Values)
- func FilterQuery(fq string) func(url.Values)
- func GetDocIdFromDoc(m map[string]interface{}) string
- func GetVersionFromDoc(m map[string]interface{}) int
- func HTTPClient(cli HTTPer) func(*solrHttp)
- func Hash(key CompositeKey) int32
- func HttpLogger(logger Logger) func(*solrHttp)
- func InsecureSkipVerify(insecureSkipVerify bool) func(*solrHttp)
- func MinRF(minRf int) func(*solrHttp)
- func NewNotFoundError(error string) error
- func NewSolrBatchError(err error) error
- func NewSolrError(status int, message string) error
- func NewSolrInternalError(status int, message string) error
- func NewSolrLeaderError(docID string) error
- func NewSolrMapParseError(bucket string, userId int, m map[string]interface{}) error
- func NewSolrParseError(status int, message string) error
- func NewSolrRFError(rf, minRF int) error
- func Password(password string) func(*solrHttp)
- func PreferLocalShards(preferLocalShards bool) func(url.Values)
- func Query(q string) func(url.Values)
- func QueryRouter(router Router) func(*solrHttp)
- func ReadTimeout(seconds int) func(*solrHttp)
- func Route(r string) func(url.Values)
- func Rows(rows uint32) func(url.Values)
- func SleepTimeMS(sleepTimeMS int) func(*solrZkInstance)
- func SolrZKLogger(logger Logger) func(s *solrZkInstance)
- func Sort(s string) func(url.Values)
- func Start(start uint32) func(url.Values)
- func UrlVals(urlVals url.Values) func(url.Values)
- func User(user string) func(*solrHttp)
- func WriteTimeout(seconds int) func(*solrHttp)
- type Adds
- type ClusterProps
- type ClusterState
- type Collection
- type CompositeKey
- type DeleteRequest
- type HTTPer
- type HashRange
- type Logger
- type NotFoundError
- type Replica
- type Response
- type Router
- type Shard
- type SolrBatchError
- type SolrError
- type SolrHTTP
- type SolrHealthcheckResponse
- type SolrHttpRetrier
- type SolrInternalError
- type SolrLeaderError
- type SolrLocator
- type SolrLogger
- type SolrMapParseError
- type SolrMinRFError
- type SolrParseError
- type SolrResponse
- type SolrZK
- type UpdateResponse
- type Zookeeper
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrNotFound = NewNotFoundError("Not found")
Functions ¶
func ClusterStateVersion ¶
func ConnectionTimeout ¶ added in v1.0.26
func ConnectionTimeout(seconds int) func(*solrHttp)
func DefaultRows ¶
func DefaultRows(rows uint32) func(*solrHttp)
DefaultRows sets number of rows for pagination in calls that don't pass a number of rows in
func DeleteStreamBody ¶
func FilterQuery ¶
Helper funcs for setting the solr query params
func GetDocIdFromDoc ¶
func GetVersionFromDoc ¶
func Hash ¶
func Hash(key CompositeKey) int32
func HttpLogger ¶
func HttpLogger(logger Logger) func(*solrHttp)
func InsecureSkipVerify ¶ added in v1.0.15
func InsecureSkipVerify(insecureSkipVerify bool) func(*solrHttp)
func NewNotFoundError ¶
func NewSolrBatchError ¶
func NewSolrError ¶
func NewSolrInternalError ¶
func NewSolrLeaderError ¶
func NewSolrMapParseError ¶
func NewSolrParseError ¶
func NewSolrRFError ¶
func PreferLocalShards ¶ added in v1.0.24
func QueryRouter ¶ added in v1.0.25
func QueryRouter(router Router) func(*solrHttp)
func ReadTimeout ¶ added in v1.0.17
func ReadTimeout(seconds int) func(*solrHttp)
func SleepTimeMS ¶ added in v1.0.12
func SleepTimeMS(sleepTimeMS int) func(*solrZkInstance)
func SolrZKLogger ¶ added in v1.0.18
func SolrZKLogger(logger Logger) func(s *solrZkInstance)
func WriteTimeout ¶ added in v1.0.17
func WriteTimeout(seconds int) func(*solrHttp)
Types ¶
type ClusterProps ¶
type ClusterProps struct {
UrlScheme string `json:"urlScheme"`
}
type ClusterState ¶
type ClusterState struct { LiveNodes []string Version int Collections map[string]Collection }
type Collection ¶
type CompositeKey ¶
func NewCompositeKey ¶
func NewCompositeKey(id string) (CompositeKey, error)
type DeleteRequest ¶
type DeleteRequest struct {
Delete []string `json:"delete"`
}
type HashRange ¶
func ConvertToHashRange ¶
type NotFoundError ¶
type NotFoundError struct {
// contains filtered or unexported fields
}
func (NotFoundError) Error ¶
func (err NotFoundError) Error() string
type Router ¶ added in v1.0.25
type Router interface { GetUriFromList(urisIn []string) string AddSearchResult(t time.Duration, uri string, statusCode int, err error) }
func NewAdaptiveRouter ¶ added in v1.0.25
func NewRoundRobinRouter ¶ added in v1.0.25
func NewRoundRobinRouter() Router
type SolrBatchError ¶
type SolrBatchError struct {
// contains filtered or unexported fields
}
type SolrHTTP ¶
type SolrHTTP interface { Select(nodeUris []string, opts ...func(url.Values)) (SolrResponse, error) Update(nodeUris []string, singleDoc bool, doc interface{}, opts ...func(url.Values)) error Logger() Logger }
func NewSolrHTTP ¶
type SolrHealthcheckResponse ¶
type SolrHttpRetrier ¶
type SolrHttpRetrier struct {
// contains filtered or unexported fields
}
func (*SolrHttpRetrier) Logger ¶
func (s *SolrHttpRetrier) Logger() Logger
func (*SolrHttpRetrier) Select ¶ added in v1.0.24
func (s *SolrHttpRetrier) Select(nodeUris []string, opts ...func(url.Values)) (SolrResponse, error)
type SolrInternalError ¶
type SolrInternalError struct {
SolrError
}
type SolrLeaderError ¶
type SolrLeaderError struct {
SolrError
}
type SolrLocator ¶ added in v1.0.3
type SolrLogger ¶ added in v1.0.20
func (*SolrLogger) Debug ¶ added in v1.0.20
func (l *SolrLogger) Debug(v ...interface{})
func (*SolrLogger) Error ¶ added in v1.0.20
func (l *SolrLogger) Error(err error)
func (*SolrLogger) Info ¶ added in v1.0.20
func (l *SolrLogger) Info(v ...interface{})
func (*SolrLogger) Printf ¶ added in v1.0.20
func (l *SolrLogger) Printf(format string, v ...interface{})
type SolrMapParseError ¶
type SolrMapParseError struct {
// contains filtered or unexported fields
}
func (SolrMapParseError) Error ¶
func (err SolrMapParseError) Error() string
type SolrMinRFError ¶ added in v1.0.20
type SolrParseError ¶
type SolrParseError struct {
SolrError
}
type SolrResponse ¶
type SolrZK ¶
type SolrZK interface { GetZookeepers() string GetClusterState() (ClusterState, error) GetClusterProps() (ClusterProps, error) Listen() error Listening() bool GetSolrLocator() SolrLocator UseHTTPS() (bool, error) }
type UpdateResponse ¶
type Zookeeper ¶
type Zookeeper interface { IsConnected() bool Connect() error GetConnectionString() string Get(path string) ([]byte, int, error) Poll(path string, cb stateChanged) GetClusterState() (map[string]Collection, int, error) GetClusterStateW() (map[string]Collection, int, <-chan zk.Event, error) GetLiveNodes() ([]string, error) GetLiveNodesW() ([]string, <-chan zk.Event, error) GetLeaderElectW() (<-chan zk.Event, error) GetClusterProps() (ClusterProps, error) ZKLogger(l Logger) }
Source Files ¶
Click to show internal directories.
Click to hide internal directories.