Documentation ¶
Index ¶
- Constants
- Variables
- func WriteError(resp http.ResponseWriter, err error)
- type Cluster
- func (*Cluster) Descriptor() ([]byte, []int)deprecated
- func (x *Cluster) GetAuth() *ClusterAuth
- func (x *Cluster) GetEndpoint() string
- func (x *Cluster) GetIndexSetCount() int64
- func (x *Cluster) GetName() string
- func (*Cluster) ProtoMessage()
- func (x *Cluster) ProtoReflect() protoreflect.Message
- func (x *Cluster) Reset()
- func (x *Cluster) String() string
- type ClusterAuth
- type DeleteClusterRequest
- func (*DeleteClusterRequest) Descriptor() ([]byte, []int)deprecated
- func (x *DeleteClusterRequest) GetName() string
- func (*DeleteClusterRequest) ProtoMessage()
- func (x *DeleteClusterRequest) ProtoReflect() protoreflect.Message
- func (x *DeleteClusterRequest) Reset()
- func (x *DeleteClusterRequest) String() string
- type DeleteClusterResponse
- type DeleteIndexSetRequest
- func (*DeleteIndexSetRequest) Descriptor() ([]byte, []int)deprecated
- func (x *DeleteIndexSetRequest) GetName() string
- func (*DeleteIndexSetRequest) ProtoMessage()
- func (x *DeleteIndexSetRequest) ProtoReflect() protoreflect.Message
- func (x *DeleteIndexSetRequest) Reset()
- func (x *DeleteIndexSetRequest) String() string
- type DeleteIndexSetResponse
- type EnabledFilter
- func (EnabledFilter) Descriptor() protoreflect.EnumDescriptor
- func (x EnabledFilter) Enum() *EnabledFilter
- func (EnabledFilter) EnumDescriptor() ([]byte, []int)deprecated
- func (x EnabledFilter) Number() protoreflect.EnumNumber
- func (x EnabledFilter) String() string
- func (EnabledFilter) Type() protoreflect.EnumType
- type HTTPClient
- type IndexSet
- func (*IndexSet) Descriptor() ([]byte, []int)deprecated
- func (x *IndexSet) GetActive() bool
- func (x *IndexSet) GetCluster() string
- func (x *IndexSet) GetEnabled() bool
- func (x *IndexSet) GetName() string
- func (x *IndexSet) GetPosition() int64
- func (*IndexSet) ProtoMessage()
- func (x *IndexSet) ProtoReflect() protoreflect.Message
- func (x *IndexSet) Reset()
- func (x *IndexSet) String() string
- type ListClustersRequest
- type ListClustersResponse
- func (*ListClustersResponse) Descriptor() ([]byte, []int)deprecated
- func (x *ListClustersResponse) GetClusters() []*Cluster
- func (*ListClustersResponse) ProtoMessage()
- func (x *ListClustersResponse) ProtoReflect() protoreflect.Message
- func (x *ListClustersResponse) Reset()
- func (x *ListClustersResponse) String() string
- type ListIndexSetsRequest
- func (*ListIndexSetsRequest) Descriptor() ([]byte, []int)deprecated
- func (x *ListIndexSetsRequest) GetCluster() string
- func (x *ListIndexSetsRequest) GetCursor() string
- func (x *ListIndexSetsRequest) GetOnlyActive() bool
- func (x *ListIndexSetsRequest) GetStatus() EnabledFilter
- func (*ListIndexSetsRequest) ProtoMessage()
- func (x *ListIndexSetsRequest) ProtoReflect() protoreflect.Message
- func (x *ListIndexSetsRequest) Reset()
- func (x *ListIndexSetsRequest) String() string
- type ListIndexSetsResponse
- func (*ListIndexSetsResponse) Descriptor() ([]byte, []int)deprecated
- func (x *ListIndexSetsResponse) GetIndexSets() []*IndexSet
- func (x *ListIndexSetsResponse) GetNextPage() string
- func (*ListIndexSetsResponse) ProtoMessage()
- func (x *ListIndexSetsResponse) ProtoReflect() protoreflect.Message
- func (x *ListIndexSetsResponse) Reset()
- func (x *ListIndexSetsResponse) String() string
- type Management
- type PartialReindexRequest
- func (*PartialReindexRequest) Descriptor() ([]byte, []int)deprecated
- func (x *PartialReindexRequest) GetIndexSet() string
- func (x *PartialReindexRequest) GetPosition() int64
- func (*PartialReindexRequest) ProtoMessage()
- func (x *PartialReindexRequest) ProtoReflect() protoreflect.Message
- func (x *PartialReindexRequest) Reset()
- func (x *PartialReindexRequest) String() string
- type PartialReindexResponse
- type RegisterClusterAuth
- func (*RegisterClusterAuth) Descriptor() ([]byte, []int)deprecated
- func (x *RegisterClusterAuth) GetIam() bool
- func (*RegisterClusterAuth) ProtoMessage()
- func (x *RegisterClusterAuth) ProtoReflect() protoreflect.Message
- func (x *RegisterClusterAuth) Reset()
- func (x *RegisterClusterAuth) String() string
- type RegisterClusterRequest
- func (*RegisterClusterRequest) Descriptor() ([]byte, []int)deprecated
- func (x *RegisterClusterRequest) GetAuth() *RegisterClusterAuth
- func (x *RegisterClusterRequest) GetEndpoint() string
- func (x *RegisterClusterRequest) GetName() string
- func (*RegisterClusterRequest) ProtoMessage()
- func (x *RegisterClusterRequest) ProtoReflect() protoreflect.Message
- func (x *RegisterClusterRequest) Reset()
- func (x *RegisterClusterRequest) String() string
- type RegisterClusterResponse
- type ReindexRequest
- type ReindexResponse
- type SetIndexSetStatusRequest
- func (*SetIndexSetStatusRequest) Descriptor() ([]byte, []int)deprecated
- func (x *SetIndexSetStatusRequest) GetActive() bool
- func (x *SetIndexSetStatusRequest) GetEnabled() bool
- func (x *SetIndexSetStatusRequest) GetForceActive() bool
- func (x *SetIndexSetStatusRequest) GetName() string
- func (*SetIndexSetStatusRequest) ProtoMessage()
- func (x *SetIndexSetStatusRequest) ProtoReflect() protoreflect.Message
- func (x *SetIndexSetStatusRequest) Reset()
- func (x *SetIndexSetStatusRequest) String() string
- type SetIndexSetStatusResponse
- type TwirpServer
Constants ¶
const ManagementPathPrefix = "/twirp/elephant.index.Management/"
ManagementPathPrefix is a convenience constant that may identify URL paths. Should be used with caution, it only matches routes generated by Twirp Go clients, with the default "/twirp" prefix and default CamelCase service and method names. More info: https://twitchtv.github.io/twirp/docs/routing.html
Variables ¶
var ( EnabledFilter_name = map[int32]string{ 0: "STATUS_UNSPECIFIED", 1: "STATUS_ENABLED", 3: "STATUS_DISABLED", } EnabledFilter_value = map[string]int32{ "STATUS_UNSPECIFIED": 0, "STATUS_ENABLED": 1, "STATUS_DISABLED": 3, } )
Enum value maps for EnabledFilter.
var File_index_service_proto protoreflect.FileDescriptor
Functions ¶
func WriteError ¶
func WriteError(resp http.ResponseWriter, err error)
WriteError writes an HTTP response with a valid Twirp error format (code, msg, meta). Useful outside of the Twirp server (e.g. http middleware), but does not trigger hooks. If err is not a twirp.Error, it will get wrapped with twirp.InternalErrorWith(err)
Types ¶
type Cluster ¶
type Cluster struct { // Name used to identify the cluster. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // Endpoint for the cluster. Endpoint string `protobuf:"bytes,2,opt,name=endpoint,proto3" json:"endpoint,omitempty"` // Number of index sets in the cluster. IndexSetCount int64 `protobuf:"varint,3,opt,name=index_set_count,json=indexSetCount,proto3" json:"index_set_count,omitempty"` // Auth options for the cluster. Auth *ClusterAuth `protobuf:"bytes,4,opt,name=auth,proto3" json:"auth,omitempty"` // contains filtered or unexported fields }
func (*Cluster) Descriptor
deprecated
func (*Cluster) GetAuth ¶
func (x *Cluster) GetAuth() *ClusterAuth
func (*Cluster) GetEndpoint ¶
func (*Cluster) GetIndexSetCount ¶
func (*Cluster) ProtoMessage ¶
func (*Cluster) ProtoMessage()
func (*Cluster) ProtoReflect ¶
func (x *Cluster) ProtoReflect() protoreflect.Message
type ClusterAuth ¶
type ClusterAuth struct { // IAM authentication. Iam bool `protobuf:"varint,1,opt,name=iam,proto3" json:"iam,omitempty"` // contains filtered or unexported fields }
func (*ClusterAuth) Descriptor
deprecated
func (*ClusterAuth) Descriptor() ([]byte, []int)
Deprecated: Use ClusterAuth.ProtoReflect.Descriptor instead.
func (*ClusterAuth) GetIam ¶
func (x *ClusterAuth) GetIam() bool
func (*ClusterAuth) ProtoMessage ¶
func (*ClusterAuth) ProtoMessage()
func (*ClusterAuth) ProtoReflect ¶
func (x *ClusterAuth) ProtoReflect() protoreflect.Message
func (*ClusterAuth) Reset ¶
func (x *ClusterAuth) Reset()
func (*ClusterAuth) String ¶
func (x *ClusterAuth) String() string
type DeleteClusterRequest ¶
type DeleteClusterRequest struct { // Name of the cluster to delete. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // contains filtered or unexported fields }
func (*DeleteClusterRequest) Descriptor
deprecated
func (*DeleteClusterRequest) Descriptor() ([]byte, []int)
Deprecated: Use DeleteClusterRequest.ProtoReflect.Descriptor instead.
func (*DeleteClusterRequest) GetName ¶
func (x *DeleteClusterRequest) GetName() string
func (*DeleteClusterRequest) ProtoMessage ¶
func (*DeleteClusterRequest) ProtoMessage()
func (*DeleteClusterRequest) ProtoReflect ¶
func (x *DeleteClusterRequest) ProtoReflect() protoreflect.Message
func (*DeleteClusterRequest) Reset ¶
func (x *DeleteClusterRequest) Reset()
func (*DeleteClusterRequest) String ¶
func (x *DeleteClusterRequest) String() string
type DeleteClusterResponse ¶
type DeleteClusterResponse struct {
// contains filtered or unexported fields
}
func (*DeleteClusterResponse) Descriptor
deprecated
func (*DeleteClusterResponse) Descriptor() ([]byte, []int)
Deprecated: Use DeleteClusterResponse.ProtoReflect.Descriptor instead.
func (*DeleteClusterResponse) ProtoMessage ¶
func (*DeleteClusterResponse) ProtoMessage()
func (*DeleteClusterResponse) ProtoReflect ¶
func (x *DeleteClusterResponse) ProtoReflect() protoreflect.Message
func (*DeleteClusterResponse) Reset ¶
func (x *DeleteClusterResponse) Reset()
func (*DeleteClusterResponse) String ¶
func (x *DeleteClusterResponse) String() string
type DeleteIndexSetRequest ¶
type DeleteIndexSetRequest struct { // Name of the index set to delete. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // contains filtered or unexported fields }
func (*DeleteIndexSetRequest) Descriptor
deprecated
func (*DeleteIndexSetRequest) Descriptor() ([]byte, []int)
Deprecated: Use DeleteIndexSetRequest.ProtoReflect.Descriptor instead.
func (*DeleteIndexSetRequest) GetName ¶
func (x *DeleteIndexSetRequest) GetName() string
func (*DeleteIndexSetRequest) ProtoMessage ¶
func (*DeleteIndexSetRequest) ProtoMessage()
func (*DeleteIndexSetRequest) ProtoReflect ¶
func (x *DeleteIndexSetRequest) ProtoReflect() protoreflect.Message
func (*DeleteIndexSetRequest) Reset ¶
func (x *DeleteIndexSetRequest) Reset()
func (*DeleteIndexSetRequest) String ¶
func (x *DeleteIndexSetRequest) String() string
type DeleteIndexSetResponse ¶
type DeleteIndexSetResponse struct {
// contains filtered or unexported fields
}
func (*DeleteIndexSetResponse) Descriptor
deprecated
func (*DeleteIndexSetResponse) Descriptor() ([]byte, []int)
Deprecated: Use DeleteIndexSetResponse.ProtoReflect.Descriptor instead.
func (*DeleteIndexSetResponse) ProtoMessage ¶
func (*DeleteIndexSetResponse) ProtoMessage()
func (*DeleteIndexSetResponse) ProtoReflect ¶
func (x *DeleteIndexSetResponse) ProtoReflect() protoreflect.Message
func (*DeleteIndexSetResponse) Reset ¶
func (x *DeleteIndexSetResponse) Reset()
func (*DeleteIndexSetResponse) String ¶
func (x *DeleteIndexSetResponse) String() string
type EnabledFilter ¶
type EnabledFilter int32
const ( EnabledFilter_STATUS_UNSPECIFIED EnabledFilter = 0 // STATUS_ENABLED means that documents are currently being indexed to the // index set. EnabledFilter_STATUS_ENABLED EnabledFilter = 1 // STATUS_DISABLED means that no documents are being indexed to the index set. EnabledFilter_STATUS_DISABLED EnabledFilter = 3 )
func (EnabledFilter) Descriptor ¶
func (EnabledFilter) Descriptor() protoreflect.EnumDescriptor
func (EnabledFilter) Enum ¶
func (x EnabledFilter) Enum() *EnabledFilter
func (EnabledFilter) EnumDescriptor
deprecated
func (EnabledFilter) EnumDescriptor() ([]byte, []int)
Deprecated: Use EnabledFilter.Descriptor instead.
func (EnabledFilter) Number ¶
func (x EnabledFilter) Number() protoreflect.EnumNumber
func (EnabledFilter) String ¶
func (x EnabledFilter) String() string
func (EnabledFilter) Type ¶
func (EnabledFilter) Type() protoreflect.EnumType
type HTTPClient ¶
HTTPClient is the interface used by generated clients to send HTTP requests. It is fulfilled by *(net/http).Client, which is sufficient for most users. Users can provide their own implementation for special retry policies.
HTTPClient implementations should not follow redirects. Redirects are automatically disabled if *(net/http).Client is passed to client constructors. See the withoutRedirects function in this file for more details.
type IndexSet ¶
type IndexSet struct { // Name of the index set. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // Cluster that the index set has been created in. Cluster string `protobuf:"bytes,2,opt,name=cluster,proto3" json:"cluster,omitempty"` // Enabled status of the index set. Enabled bool `protobuf:"varint,3,opt,name=enabled,proto3" json:"enabled,omitempty"` // Active status of the index set. Active bool `protobuf:"varint,4,opt,name=active,proto3" json:"active,omitempty"` // Position in the repository content log. Position int64 `protobuf:"varint,5,opt,name=position,proto3" json:"position,omitempty"` // contains filtered or unexported fields }
func (*IndexSet) Descriptor
deprecated
func (*IndexSet) GetCluster ¶
func (*IndexSet) GetEnabled ¶
func (*IndexSet) GetPosition ¶
func (*IndexSet) ProtoMessage ¶
func (*IndexSet) ProtoMessage()
func (*IndexSet) ProtoReflect ¶
func (x *IndexSet) ProtoReflect() protoreflect.Message
type ListClustersRequest ¶
type ListClustersRequest struct {
// contains filtered or unexported fields
}
func (*ListClustersRequest) Descriptor
deprecated
func (*ListClustersRequest) Descriptor() ([]byte, []int)
Deprecated: Use ListClustersRequest.ProtoReflect.Descriptor instead.
func (*ListClustersRequest) ProtoMessage ¶
func (*ListClustersRequest) ProtoMessage()
func (*ListClustersRequest) ProtoReflect ¶
func (x *ListClustersRequest) ProtoReflect() protoreflect.Message
func (*ListClustersRequest) Reset ¶
func (x *ListClustersRequest) Reset()
func (*ListClustersRequest) String ¶
func (x *ListClustersRequest) String() string
type ListClustersResponse ¶
type ListClustersResponse struct { Clusters []*Cluster `protobuf:"bytes,1,rep,name=clusters,proto3" json:"clusters,omitempty"` // contains filtered or unexported fields }
func (*ListClustersResponse) Descriptor
deprecated
func (*ListClustersResponse) Descriptor() ([]byte, []int)
Deprecated: Use ListClustersResponse.ProtoReflect.Descriptor instead.
func (*ListClustersResponse) GetClusters ¶
func (x *ListClustersResponse) GetClusters() []*Cluster
func (*ListClustersResponse) ProtoMessage ¶
func (*ListClustersResponse) ProtoMessage()
func (*ListClustersResponse) ProtoReflect ¶
func (x *ListClustersResponse) ProtoReflect() protoreflect.Message
func (*ListClustersResponse) Reset ¶
func (x *ListClustersResponse) Reset()
func (*ListClustersResponse) String ¶
func (x *ListClustersResponse) String() string
type ListIndexSetsRequest ¶
type ListIndexSetsRequest struct { // Cluster can be used to filter by cluster. Cluster string `protobuf:"bytes,1,opt,name=cluster,proto3" json:"cluster,omitempty"` // OnlyActive only returns the currently active index set. OnlyActive bool `protobuf:"varint,2,opt,name=only_active,json=onlyActive,proto3" json:"only_active,omitempty"` // Status can be used to filter index sets by their enabled/disabled status. Status EnabledFilter `protobuf:"varint,3,opt,name=status,proto3,enum=elephant.index.EnabledFilter" json:"status,omitempty"` // Cursor to the page that should be returned. Omit to get the first page. Cursor string `protobuf:"bytes,4,opt,name=cursor,proto3" json:"cursor,omitempty"` // contains filtered or unexported fields }
func (*ListIndexSetsRequest) Descriptor
deprecated
func (*ListIndexSetsRequest) Descriptor() ([]byte, []int)
Deprecated: Use ListIndexSetsRequest.ProtoReflect.Descriptor instead.
func (*ListIndexSetsRequest) GetCluster ¶
func (x *ListIndexSetsRequest) GetCluster() string
func (*ListIndexSetsRequest) GetCursor ¶
func (x *ListIndexSetsRequest) GetCursor() string
func (*ListIndexSetsRequest) GetOnlyActive ¶
func (x *ListIndexSetsRequest) GetOnlyActive() bool
func (*ListIndexSetsRequest) GetStatus ¶
func (x *ListIndexSetsRequest) GetStatus() EnabledFilter
func (*ListIndexSetsRequest) ProtoMessage ¶
func (*ListIndexSetsRequest) ProtoMessage()
func (*ListIndexSetsRequest) ProtoReflect ¶
func (x *ListIndexSetsRequest) ProtoReflect() protoreflect.Message
func (*ListIndexSetsRequest) Reset ¶
func (x *ListIndexSetsRequest) Reset()
func (*ListIndexSetsRequest) String ¶
func (x *ListIndexSetsRequest) String() string
type ListIndexSetsResponse ¶
type ListIndexSetsResponse struct { // IndexSets that matched the criteria. IndexSets []*IndexSet `protobuf:"bytes,1,rep,name=index_sets,json=indexSets,proto3" json:"index_sets,omitempty"` // NextPage cursor to use to get the next page of index sets. Empty if no more // index sets exist. NextPage string `protobuf:"bytes,2,opt,name=next_page,json=nextPage,proto3" json:"next_page,omitempty"` // contains filtered or unexported fields }
func (*ListIndexSetsResponse) Descriptor
deprecated
func (*ListIndexSetsResponse) Descriptor() ([]byte, []int)
Deprecated: Use ListIndexSetsResponse.ProtoReflect.Descriptor instead.
func (*ListIndexSetsResponse) GetIndexSets ¶
func (x *ListIndexSetsResponse) GetIndexSets() []*IndexSet
func (*ListIndexSetsResponse) GetNextPage ¶
func (x *ListIndexSetsResponse) GetNextPage() string
func (*ListIndexSetsResponse) ProtoMessage ¶
func (*ListIndexSetsResponse) ProtoMessage()
func (*ListIndexSetsResponse) ProtoReflect ¶
func (x *ListIndexSetsResponse) ProtoReflect() protoreflect.Message
func (*ListIndexSetsResponse) Reset ¶
func (x *ListIndexSetsResponse) Reset()
func (*ListIndexSetsResponse) String ¶
func (x *ListIndexSetsResponse) String() string
type Management ¶
type Management interface { // RegisterCluster for use with index sets. RegisterCluster(context.Context, *RegisterClusterRequest) (*RegisterClusterResponse, error) // ListClusters returns a list of clusters together with information about the // number of index sets they contain. ListClusters(context.Context, *ListClustersRequest) (*ListClustersResponse, error) // DeleteCluster deletes a registered cluster. A cluster cannot be deleted as // long as it has associated index sets. DeleteCluster(context.Context, *DeleteClusterRequest) (*DeleteClusterResponse, error) // DeleteIndexSet deletes an index set. The set cannot be active or enabled. DeleteIndexSet(context.Context, *DeleteIndexSetRequest) (*DeleteIndexSetResponse, error) // Reindex set creates a new index set in the specified cluster and starts // indexing documents to it. Reindex(context.Context, *ReindexRequest) (*ReindexResponse, error) // PartialReindex restarts an existing index set from a given point in the // repository eventlog. PartialReindex(context.Context, *PartialReindexRequest) (*PartialReindexResponse, error) // ListIndexSets lists the available index set, with optional filtering. ListIndexSets(context.Context, *ListIndexSetsRequest) (*ListIndexSetsResponse, error) // SetIndexSetStatus is used to change the status of an index set. SetIndexSetStatus(context.Context, *SetIndexSetStatusRequest) (*SetIndexSetStatusResponse, error) }
func NewManagementJSONClient ¶
func NewManagementJSONClient(baseURL string, client HTTPClient, opts ...twirp.ClientOption) Management
NewManagementJSONClient creates a JSON client that implements the Management interface. It communicates using JSON and can be configured with a custom HTTPClient.
func NewManagementProtobufClient ¶
func NewManagementProtobufClient(baseURL string, client HTTPClient, opts ...twirp.ClientOption) Management
NewManagementProtobufClient creates a Protobuf client that implements the Management interface. It communicates using Protobuf and can be configured with a custom HTTPClient.
type PartialReindexRequest ¶
type PartialReindexRequest struct { // IndexSet to re-index. IndexSet string `protobuf:"bytes,1,opt,name=index_set,json=indexSet,proto3" json:"index_set,omitempty"` // Position to start from. Position int64 `protobuf:"varint,2,opt,name=position,proto3" json:"position,omitempty"` // contains filtered or unexported fields }
func (*PartialReindexRequest) Descriptor
deprecated
func (*PartialReindexRequest) Descriptor() ([]byte, []int)
Deprecated: Use PartialReindexRequest.ProtoReflect.Descriptor instead.
func (*PartialReindexRequest) GetIndexSet ¶
func (x *PartialReindexRequest) GetIndexSet() string
func (*PartialReindexRequest) GetPosition ¶
func (x *PartialReindexRequest) GetPosition() int64
func (*PartialReindexRequest) ProtoMessage ¶
func (*PartialReindexRequest) ProtoMessage()
func (*PartialReindexRequest) ProtoReflect ¶
func (x *PartialReindexRequest) ProtoReflect() protoreflect.Message
func (*PartialReindexRequest) Reset ¶
func (x *PartialReindexRequest) Reset()
func (*PartialReindexRequest) String ¶
func (x *PartialReindexRequest) String() string
type PartialReindexResponse ¶
type PartialReindexResponse struct {
// contains filtered or unexported fields
}
func (*PartialReindexResponse) Descriptor
deprecated
func (*PartialReindexResponse) Descriptor() ([]byte, []int)
Deprecated: Use PartialReindexResponse.ProtoReflect.Descriptor instead.
func (*PartialReindexResponse) ProtoMessage ¶
func (*PartialReindexResponse) ProtoMessage()
func (*PartialReindexResponse) ProtoReflect ¶
func (x *PartialReindexResponse) ProtoReflect() protoreflect.Message
func (*PartialReindexResponse) Reset ¶
func (x *PartialReindexResponse) Reset()
func (*PartialReindexResponse) String ¶
func (x *PartialReindexResponse) String() string
type RegisterClusterAuth ¶
type RegisterClusterAuth struct { // IAM authentication. Iam bool `protobuf:"varint,1,opt,name=iam,proto3" json:"iam,omitempty"` // contains filtered or unexported fields }
func (*RegisterClusterAuth) Descriptor
deprecated
func (*RegisterClusterAuth) Descriptor() ([]byte, []int)
Deprecated: Use RegisterClusterAuth.ProtoReflect.Descriptor instead.
func (*RegisterClusterAuth) GetIam ¶
func (x *RegisterClusterAuth) GetIam() bool
func (*RegisterClusterAuth) ProtoMessage ¶
func (*RegisterClusterAuth) ProtoMessage()
func (*RegisterClusterAuth) ProtoReflect ¶
func (x *RegisterClusterAuth) ProtoReflect() protoreflect.Message
func (*RegisterClusterAuth) Reset ¶
func (x *RegisterClusterAuth) Reset()
func (*RegisterClusterAuth) String ¶
func (x *RegisterClusterAuth) String() string
type RegisterClusterRequest ¶
type RegisterClusterRequest struct { // Name used to identify the cluster. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // Endpoint for the cluster. Endpoint string `protobuf:"bytes,2,opt,name=endpoint,proto3" json:"endpoint,omitempty"` // Auth is used to specify the authentication method. Auth *RegisterClusterAuth `protobuf:"bytes,3,opt,name=auth,proto3" json:"auth,omitempty"` // contains filtered or unexported fields }
func (*RegisterClusterRequest) Descriptor
deprecated
func (*RegisterClusterRequest) Descriptor() ([]byte, []int)
Deprecated: Use RegisterClusterRequest.ProtoReflect.Descriptor instead.
func (*RegisterClusterRequest) GetAuth ¶
func (x *RegisterClusterRequest) GetAuth() *RegisterClusterAuth
func (*RegisterClusterRequest) GetEndpoint ¶
func (x *RegisterClusterRequest) GetEndpoint() string
func (*RegisterClusterRequest) GetName ¶
func (x *RegisterClusterRequest) GetName() string
func (*RegisterClusterRequest) ProtoMessage ¶
func (*RegisterClusterRequest) ProtoMessage()
func (*RegisterClusterRequest) ProtoReflect ¶
func (x *RegisterClusterRequest) ProtoReflect() protoreflect.Message
func (*RegisterClusterRequest) Reset ¶
func (x *RegisterClusterRequest) Reset()
func (*RegisterClusterRequest) String ¶
func (x *RegisterClusterRequest) String() string
type RegisterClusterResponse ¶
type RegisterClusterResponse struct {
// contains filtered or unexported fields
}
func (*RegisterClusterResponse) Descriptor
deprecated
func (*RegisterClusterResponse) Descriptor() ([]byte, []int)
Deprecated: Use RegisterClusterResponse.ProtoReflect.Descriptor instead.
func (*RegisterClusterResponse) ProtoMessage ¶
func (*RegisterClusterResponse) ProtoMessage()
func (*RegisterClusterResponse) ProtoReflect ¶
func (x *RegisterClusterResponse) ProtoReflect() protoreflect.Message
func (*RegisterClusterResponse) Reset ¶
func (x *RegisterClusterResponse) Reset()
func (*RegisterClusterResponse) String ¶
func (x *RegisterClusterResponse) String() string
type ReindexRequest ¶
type ReindexRequest struct { // Cluster that we should re-index set to. Cluster string `protobuf:"bytes,1,opt,name=cluster,proto3" json:"cluster,omitempty"` // contains filtered or unexported fields }
func (*ReindexRequest) Descriptor
deprecated
func (*ReindexRequest) Descriptor() ([]byte, []int)
Deprecated: Use ReindexRequest.ProtoReflect.Descriptor instead.
func (*ReindexRequest) GetCluster ¶
func (x *ReindexRequest) GetCluster() string
func (*ReindexRequest) ProtoMessage ¶
func (*ReindexRequest) ProtoMessage()
func (*ReindexRequest) ProtoReflect ¶
func (x *ReindexRequest) ProtoReflect() protoreflect.Message
func (*ReindexRequest) Reset ¶
func (x *ReindexRequest) Reset()
func (*ReindexRequest) String ¶
func (x *ReindexRequest) String() string
type ReindexResponse ¶
type ReindexResponse struct { // Name of the new index set. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // contains filtered or unexported fields }
func (*ReindexResponse) Descriptor
deprecated
func (*ReindexResponse) Descriptor() ([]byte, []int)
Deprecated: Use ReindexResponse.ProtoReflect.Descriptor instead.
func (*ReindexResponse) GetName ¶
func (x *ReindexResponse) GetName() string
func (*ReindexResponse) ProtoMessage ¶
func (*ReindexResponse) ProtoMessage()
func (*ReindexResponse) ProtoReflect ¶
func (x *ReindexResponse) ProtoReflect() protoreflect.Message
func (*ReindexResponse) Reset ¶
func (x *ReindexResponse) Reset()
func (*ReindexResponse) String ¶
func (x *ReindexResponse) String() string
type SetIndexSetStatusRequest ¶
type SetIndexSetStatusRequest struct { // Name of the index set to set the status of. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // Active means that search requests are being routed to this index set. There // is always exactly one active index set at a time. Setting an index set to // active will deactivate but not disable the currently active index set. Active bool `protobuf:"varint,2,opt,name=active,proto3" json:"active,omitempty"` // ForceActive is used to force the activation of an index set that lags more // than 10 events behind the currently active set. ForceActive bool `protobuf:"varint,3,opt,name=force_active,json=forceActive,proto3" json:"force_active,omitempty"` // Enabled means that documents should index to the index set. Disabling an // index set will only pause index seting, and it can later be // resumed. Disabling an index set does not deactivate it. Enabled bool `protobuf:"varint,4,opt,name=enabled,proto3" json:"enabled,omitempty"` // contains filtered or unexported fields }
func (*SetIndexSetStatusRequest) Descriptor
deprecated
func (*SetIndexSetStatusRequest) Descriptor() ([]byte, []int)
Deprecated: Use SetIndexSetStatusRequest.ProtoReflect.Descriptor instead.
func (*SetIndexSetStatusRequest) GetActive ¶
func (x *SetIndexSetStatusRequest) GetActive() bool
func (*SetIndexSetStatusRequest) GetEnabled ¶
func (x *SetIndexSetStatusRequest) GetEnabled() bool
func (*SetIndexSetStatusRequest) GetForceActive ¶
func (x *SetIndexSetStatusRequest) GetForceActive() bool
func (*SetIndexSetStatusRequest) GetName ¶
func (x *SetIndexSetStatusRequest) GetName() string
func (*SetIndexSetStatusRequest) ProtoMessage ¶
func (*SetIndexSetStatusRequest) ProtoMessage()
func (*SetIndexSetStatusRequest) ProtoReflect ¶
func (x *SetIndexSetStatusRequest) ProtoReflect() protoreflect.Message
func (*SetIndexSetStatusRequest) Reset ¶
func (x *SetIndexSetStatusRequest) Reset()
func (*SetIndexSetStatusRequest) String ¶
func (x *SetIndexSetStatusRequest) String() string
type SetIndexSetStatusResponse ¶
type SetIndexSetStatusResponse struct {
// contains filtered or unexported fields
}
func (*SetIndexSetStatusResponse) Descriptor
deprecated
func (*SetIndexSetStatusResponse) Descriptor() ([]byte, []int)
Deprecated: Use SetIndexSetStatusResponse.ProtoReflect.Descriptor instead.
func (*SetIndexSetStatusResponse) ProtoMessage ¶
func (*SetIndexSetStatusResponse) ProtoMessage()
func (*SetIndexSetStatusResponse) ProtoReflect ¶
func (x *SetIndexSetStatusResponse) ProtoReflect() protoreflect.Message
func (*SetIndexSetStatusResponse) Reset ¶
func (x *SetIndexSetStatusResponse) Reset()
func (*SetIndexSetStatusResponse) String ¶
func (x *SetIndexSetStatusResponse) String() string
type TwirpServer ¶
type TwirpServer interface { http.Handler // ServiceDescriptor returns gzipped bytes describing the .proto file that // this service was generated from. Once unzipped, the bytes can be // unmarshalled as a // google.golang.org/protobuf/types/descriptorpb.FileDescriptorProto. // // The returned integer is the index of this particular service within that // FileDescriptorProto's 'Service' slice of ServiceDescriptorProtos. This is a // low-level field, expected to be used for reflection. ServiceDescriptor() ([]byte, int) // ProtocGenTwirpVersion is the semantic version string of the version of // twirp used to generate this file. ProtocGenTwirpVersion() string // PathPrefix returns the HTTP URL path prefix for all methods handled by this // service. This can be used with an HTTP mux to route Twirp requests. // The path prefix is in the form: "/<prefix>/<package>.<Service>/" // that is, everything in a Twirp route except for the <Method> at the end. PathPrefix() string }
TwirpServer is the interface generated server structs will support: they're HTTP handlers with additional methods for accessing metadata about the service. Those accessors are a low-level API for building reflection tools. Most people can think of TwirpServers as just http.Handlers.
func NewManagementServer ¶
func NewManagementServer(svc Management, opts ...interface{}) TwirpServer
NewManagementServer builds a TwirpServer that can be used as an http.Handler to handle HTTP requests that are routed to the right method in the provided svc implementation. The opts are twirp.ServerOption modifiers, for example twirp.WithServerHooks(hooks).