Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type State ¶
type State struct { OIDC *oidc.Client AnonymousAccess *anonymous.Client APIKey *apikey.Client Authorizer authorization.Authorizer ServerConfig *config.WeaviateConfig Locks locks.ConnectorSchemaLock Logger *logrus.Logger GraphQL graphql.GraphQL Modules *modules.Provider SchemaManager *schema.Manager Scaler *scaler.Scaler Cluster *cluster.State RemoteIndexIncoming *sharding.RemoteIndexIncoming RemoteNodeIncoming *sharding.RemoteNodeIncoming RemoteReplicaIncoming *replica.RemoteReplicaIncoming Traverser *traverser.Traverser ClassificationRepo *classifications.DistributedRepo Metrics *monitoring.PrometheusMetrics BackupManager *backup.Handler DB *db.DB BatchManager *objects.BatchManager ClusterHttpClient *http.Client ReindexCtxCancel context.CancelFunc MemWatch *memwatch.Monitor ClusterService *rCluster.Service TenantActivity *tenantactivity.Handler // contains filtered or unexported fields }
State is the only source of application-wide state NOTE: This is not true yet, see gh-723 TODO: remove dependencies to anything that's not an ent or uc
func (*State) GetGraphQL ¶
GetGraphQL is the safe way to retrieve GraphQL from the state as it can be replaced at runtime. Instead of passing appState.GraphQL to your adapters, pass appState itself which you can abstract with a local interface such as:
type gqlProvider interface { GetGraphQL graphql.GraphQL }
func (*State) SetGraphQL ¶ added in v1.22.6
Click to show internal directories.
Click to hide internal directories.