Documentation
¶
Index ¶
- Variables
- type Event
- type HTTPToolRecord
- type OpenAPIImportRecord
- type Record
- type Store
- func (s *Store) Bootstrap(ctx context.Context, backends []config.BackendConfig) error
- func (s *Store) Close() error
- func (s *Store) Create(ctx context.Context, record Record) (Record, error)
- func (s *Store) CreateHTTPTool(ctx context.Context, record HTTPToolRecord) (HTTPToolRecord, error)
- func (s *Store) CreateOpenAPIImport(ctx context.Context, record OpenAPIImportRecord, tools []HTTPToolRecord) (OpenAPIImportRecord, []HTTPToolRecord, error)
- func (s *Store) CreateToolGroup(ctx context.Context, record ToolGroupRecord) (ToolGroupRecord, error)
- func (s *Store) Delete(ctx context.Context, id string, expectedRevision int64) error
- func (s *Store) DeleteHTTPTool(ctx context.Context, groupID, name string, expected int64) error
- func (s *Store) DeleteOpenAPIImport(ctx context.Context, groupID, id string, expected int64) error
- func (s *Store) DeleteToolGroup(ctx context.Context, id string, expected int64) error
- func (s *Store) Events(ctx context.Context, limit int) ([]Event, error)
- func (s *Store) Get(ctx context.Context, id string) (Record, error)
- func (s *Store) GetHTTPTool(ctx context.Context, groupID, name string) (HTTPToolRecord, error)
- func (s *Store) GetOpenAPIImport(ctx context.Context, groupID, id string) (OpenAPIImportRecord, error)
- func (s *Store) GetToolGroup(ctx context.Context, id string) (ToolGroupRecord, error)
- func (s *Store) Initialized(ctx context.Context) (bool, error)
- func (s *Store) List(ctx context.Context) ([]Record, error)
- func (s *Store) ListHTTPTools(ctx context.Context, groupID string) ([]HTTPToolRecord, error)
- func (s *Store) ListOpenAPIImports(ctx context.Context, groupID string) ([]OpenAPIImportRecord, error)
- func (s *Store) ListToolGroups(ctx context.Context) ([]ToolGroupRecord, error)
- func (s *Store) MarkOpenAPIRefreshFailure(ctx context.Context, groupID, id string, expected int64, message string) error
- func (s *Store) MarkOpenAPIRefreshSuccess(ctx context.Context, groupID, id string, expected int64) error
- func (s *Store) RecordFailure(ctx context.Context, backendID, action, message string)
- func (s *Store) ReplaceOpenAPIImport(ctx context.Context, record OpenAPIImportRecord, expected int64, ...) (OpenAPIImportRecord, []HTTPToolRecord, error)
- func (s *Store) Update(ctx context.Context, record Record, expectedRevision int64) (Record, error)
- func (s *Store) UpdateHTTPTool(ctx context.Context, record HTTPToolRecord, expected int64) (HTTPToolRecord, error)
- func (s *Store) UpdateProbe(ctx context.Context, id string, ok bool, result json.RawMessage) error
- func (s *Store) UpdateToolGroup(ctx context.Context, record ToolGroupRecord, expected int64) (ToolGroupRecord, error)
- func (s *Store) UpdateToolGroupProbe(ctx context.Context, id string, ok bool, result json.RawMessage) error
- type ToolGroupRecord
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrNotFound = errors.New("backend not found") ErrConflict = errors.New("backend revision conflict") )
Functions ¶
This section is empty.
Types ¶
type Event ¶
type Event struct {
ID int64 `json:"id"`
BackendID string `json:"backend_id,omitempty"`
SourceKind string `json:"source_kind,omitempty"`
SourceID string `json:"source_id,omitempty"`
Actor string `json:"actor"`
Action string `json:"action"`
Success bool `json:"success"`
Message string `json:"message,omitempty"`
Revision int64 `json:"revision,omitempty"`
CreatedAt time.Time `json:"created_at"`
}
type HTTPToolRecord ¶
type OpenAPIImportRecord ¶
type Store ¶
type Store struct {
// contains filtered or unexported fields
}
func (*Store) CreateHTTPTool ¶
func (s *Store) CreateHTTPTool(ctx context.Context, record HTTPToolRecord) (HTTPToolRecord, error)
func (*Store) CreateOpenAPIImport ¶
func (s *Store) CreateOpenAPIImport(ctx context.Context, record OpenAPIImportRecord, tools []HTTPToolRecord) (OpenAPIImportRecord, []HTTPToolRecord, error)
func (*Store) CreateToolGroup ¶
func (s *Store) CreateToolGroup(ctx context.Context, record ToolGroupRecord) (ToolGroupRecord, error)
func (*Store) DeleteHTTPTool ¶
func (*Store) DeleteOpenAPIImport ¶
func (*Store) DeleteToolGroup ¶
func (*Store) GetHTTPTool ¶
func (*Store) GetOpenAPIImport ¶
func (*Store) GetToolGroup ¶
func (*Store) ListHTTPTools ¶
func (*Store) ListOpenAPIImports ¶
func (*Store) ListToolGroups ¶
func (s *Store) ListToolGroups(ctx context.Context) ([]ToolGroupRecord, error)
func (*Store) MarkOpenAPIRefreshFailure ¶
func (*Store) MarkOpenAPIRefreshSuccess ¶
func (*Store) RecordFailure ¶
func (*Store) ReplaceOpenAPIImport ¶
func (s *Store) ReplaceOpenAPIImport(ctx context.Context, record OpenAPIImportRecord, expected int64, tools []HTTPToolRecord, action string) (OpenAPIImportRecord, []HTTPToolRecord, error)
func (*Store) UpdateHTTPTool ¶
func (s *Store) UpdateHTTPTool(ctx context.Context, record HTTPToolRecord, expected int64) (HTTPToolRecord, error)
func (*Store) UpdateProbe ¶
func (*Store) UpdateToolGroup ¶
func (s *Store) UpdateToolGroup(ctx context.Context, record ToolGroupRecord, expected int64) (ToolGroupRecord, error)
func (*Store) UpdateToolGroupProbe ¶
type ToolGroupRecord ¶
Click to show internal directories.
Click to hide internal directories.