Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
D
dex
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
go
dex
Commits
c0aa63ac
Commit
c0aa63ac
authored
Oct 28, 2016
by
Eric Chiang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
storage: update godocs
parent
d7912a3a
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
3 deletions
+14
-3
doc.go
storage/kubernetes/doc.go
+1
-1
storage.go
storage/storage.go
+13
-2
No files found.
storage/kubernetes/doc.go
View file @
c0aa63ac
// Package kubernetes provides a storage i
nterface
using Kubernetes third party APIs.
// Package kubernetes provides a storage i
mplementation
using Kubernetes third party APIs.
package
kubernetes
storage/storage.go
View file @
c0aa63ac
...
...
@@ -78,9 +78,20 @@ type Storage interface {
DeleteRefresh
(
id
string
)
error
DeletePassword
(
email
string
)
error
// Update functions are assumed to be a performed within a single object transaction.
// Update methods take a function for updating an object then performs that update within
// a transaction. "updater" functions may be called multiple times by a single update call.
//
// Because new fields may be added to resources, updaters should only modify existing
// fields on the old object rather then creating new structs. For example:
//
// updater := func(old storage.Client) (storage.Client, error) {
// old.Secret = newSecret
// return old, nil
// }
// if err := s.UpdateClient(clientID, updater); err != nil {
// // update failed, handle error
// }
//
// updaters may be called multiple times.
UpdateClient
(
id
string
,
updater
func
(
old
Client
)
(
Client
,
error
))
error
UpdateKeys
(
updater
func
(
old
Keys
)
(
Keys
,
error
))
error
UpdateAuthRequest
(
id
string
,
updater
func
(
a
AuthRequest
)
(
AuthRequest
,
error
))
error
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment