Documentation
¶
Overview ¶
Copyright 2022 Evan Hazlett
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2022 Evan Hazlett ¶
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2022 Evan Hazlett ¶
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2022 Evan Hazlett ¶
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2022 Evan Hazlett ¶
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2022 Evan Hazlett ¶
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Index ¶
- Variables
- type ByWorkflowCreatedAt
- type Datastore
- func (d *Datastore) ChangePassword(ctx context.Context, account *api.Account, password []byte) error
- func (d *Datastore) ClearCacheObject(ctx context.Context, key string) error
- func (d *Datastore) CreateAccount(ctx context.Context, account *api.Account) error
- func (d *Datastore) CreateNamespace(ctx context.Context, namespace *api.Namespace) (string, error)
- func (d *Datastore) DeleteAccount(ctx context.Context, username string) error
- func (d *Datastore) DeleteNamespace(ctx context.Context, id string) error
- func (d *Datastore) DeleteWorkflow(ctx context.Context, id string) error
- func (d *Datastore) GetAccount(ctx context.Context, username string) (*api.Account, error)
- func (d *Datastore) GetAccountByID(ctx context.Context, id string) (*api.Account, error)
- func (d *Datastore) GetAccounts(ctx context.Context) ([]*api.Account, error)
- func (d *Datastore) GetAuthenticatorKey(ctx context.Context, a auth.Authenticator, key string) ([]byte, error)
- func (d *Datastore) GetAuthenticatorKeys(ctx context.Context, a auth.Authenticator, prefix string) ([][]byte, error)
- func (d *Datastore) GetCacheObject(ctx context.Context, key string) ([]byte, error)
- func (d *Datastore) GetNamespace(ctx context.Context, id string) (*api.Namespace, error)
- func (d *Datastore) GetNamespaces(ctx context.Context) ([]*api.Namespace, error)
- func (d *Datastore) GetWorkflow(ctx context.Context, id string) (*api.Workflow, error)
- func (d *Datastore) GetWorkflows(ctx context.Context) ([]*api.Workflow, error)
- func (d *Datastore) SetAuthenticatorKey(ctx context.Context, a auth.Authenticator, key string, value []byte, ...) error
- func (d *Datastore) SetCacheObject(ctx context.Context, key string, value []byte, ttl time.Duration) error
- func (d *Datastore) UpdateAccount(ctx context.Context, account *api.Account) error
- func (d *Datastore) UpdateNamespace(ctx context.Context, namespace *api.Namespace) error
- func (d *Datastore) UpdateWorkflow(ctx context.Context, workflow *api.Workflow) error
Constants ¶
This section is empty.
Variables ¶
var ( // ErrAccountExists is returned if an account already exists ErrAccountExists = errors.New("an account with that username already exists") // ErrAccountDoesNotExist is returned when an account cannot be found ErrAccountDoesNotExist = errors.New("account does not exist") )
var ( // ErrJobNotFound is returned when the specified job cannot be found ErrJobNotFound = errors.New("job not found") )
var ( // ErrNamespaceDoesNotExist is returned when an namespace cannot be found ErrNamespaceDoesNotExist = errors.New("namespace does not exist") )
Functions ¶
This section is empty.
Types ¶
type ByWorkflowCreatedAt ¶
func (ByWorkflowCreatedAt) Len ¶
func (s ByWorkflowCreatedAt) Len() int
func (ByWorkflowCreatedAt) Less ¶
func (s ByWorkflowCreatedAt) Less(i, j int) bool
func (ByWorkflowCreatedAt) Swap ¶
func (s ByWorkflowCreatedAt) Swap(i, j int)
type Datastore ¶
type Datastore struct {
// contains filtered or unexported fields
}
func (*Datastore) ChangePassword ¶
func (*Datastore) ClearCacheObject ¶
func (*Datastore) CreateAccount ¶
func (*Datastore) CreateNamespace ¶
func (*Datastore) DeleteAccount ¶
func (*Datastore) DeleteNamespace ¶
func (*Datastore) DeleteWorkflow ¶
func (*Datastore) GetAccount ¶
func (*Datastore) GetAccountByID ¶
func (*Datastore) GetAccounts ¶
func (*Datastore) GetAuthenticatorKey ¶
func (d *Datastore) GetAuthenticatorKey(ctx context.Context, a auth.Authenticator, key string) ([]byte, error)
GetAuthenticatorKey is a helper func for authenticators to get authenticator specific keys
func (*Datastore) GetAuthenticatorKeys ¶
func (*Datastore) GetCacheObject ¶
func (*Datastore) GetNamespace ¶
func (*Datastore) GetNamespaces ¶
func (*Datastore) GetWorkflow ¶
func (*Datastore) GetWorkflows ¶
func (*Datastore) SetAuthenticatorKey ¶
func (d *Datastore) SetAuthenticatorKey(ctx context.Context, a auth.Authenticator, key string, value []byte, ttl time.Duration) error
SetAuthenticatorKey is a helper func for authenticators to store authenticator specific data