MCPcopy Create free account
hub / github.com/FunctionStream/function-stream / DefaultStateStoreLoader

Function DefaultStateStoreLoader

server/server.go:203–209  ·  view source on GitHub ↗
(c *StateStoreConfig)

Source from the content-addressed store, hash-verified

201}
202
203func DefaultStateStoreLoader(c *StateStoreConfig) (api.StateStore, error) {
204 switch strings.ToLower(*c.Type) {
205 case common.StateStorePebble:
206 return statestore.NewTmpPebbleStateStore()
207 }
208 return nil, fmt.Errorf("unsupported state store type [%s] %w", *c.Type, ErrUnsupportedStateStore)
209}
210
211func WithConfig(config *Config) ServerOption {
212 return serverOptionFunc(func(o *serverOptions) (*serverOptions, error) {

Callers

nothing calls this directly

Calls 1

NewTmpPebbleStateStoreFunction · 0.92

Tested by

no test coverage detected