kinesis-consumer/storage.go
kperry 8f0fb899b7 addressed PR comments, moved some things around to new storage package,
separated out lease and moved to storage, created storage.go.
2019-05-27 11:46:44 -05:00

11 lines
377 B
Go

package consumer
import "github.com/harlow/kinesis-consumer/storage"
// Storage is a simple interface for abstracting away the storage functions
type Storage interface {
CreateLease(lease storage.Lease) error
UpdateLease(originalLease, updatedLease storage.Lease) error
GetLease(leaseKey string) (*storage.Lease, error)
GetAllLeases() (map[string]storage.Lease, error)
}