Modify sp and services to use the protobuf module

This commit is contained in:
mitchell 2019-07-11 21:02:46 -04:00
parent 66ec035ee0
commit 4fc74b0994
23 changed files with 59 additions and 1025 deletions

View file

@ -11,7 +11,7 @@ type Service interface {
DumpDB(ctx context.Context) (bs []byte, err error)
}
type CredentialRepo interface {
type CredentialsRepo interface {
GetAllMetadata(ctx context.Context, sourceHost string, errch chan<- error) (output <-chan Metadata)
Get(ctx context.Context, id string) (output Credential, err error)
Put(ctx context.Context, c Credential) (err error)
@ -19,9 +19,9 @@ type CredentialRepo interface {
DumpDB(ctx context.Context) (bs []byte, err error)
}
type CredentialClientInit func(ctx context.Context, target, ca, cert, key string) (c CredentialClient, err error)
type CredentialsClientInit func(ctx context.Context, target, ca, cert, key string) (c CredentialsClient, err error)
type CredentialClient interface {
type CredentialsClient interface {
GetAllMetadata(ctx context.Context, sourceHost string) (output <-chan Metadata, errch chan error)
Get(ctx context.Context, id string) (output Credential, err error)
Create(ctx context.Context, ci CredentialInput) (output Credential, err error)