Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ZeroVersion = Version(time.Time{})
Functions ¶
Types ¶
type ConfigGenerator ¶
type ConfigGenerator func(ctx context.Context) (*ExportData, error)
type ExportData ¶
type ExportData struct { Topic string DataWithoutVersion VersionValuable DataSignWithoutVersion string // contains filtered or unexported fields }
func (*ExportData) CalculateVersion ¶
func (cs *ExportData) CalculateVersion() (string, error)
func (*ExportData) Version ¶
func (cs *ExportData) Version() string
type VersionControlManager ¶
type VersionControlManager struct {
// contains filtered or unexported fields
}
func NewVersionControllerManager ¶
func NewVersionControllerManager(txn itxn.TxnStorager, storager VersionControlStorager) *VersionControlManager
func (*VersionControlManager) ExportConfig ¶
func (vcm *VersionControlManager) ExportConfig(ctx context.Context, configTopic string, generaotr ConfigGenerator) (lrv *ExportData, err error)
type VersionControlStorager ¶
type VersionControlStorager interface { // UpsertConfigLastExportedVersion will got last export data // if config changed, create new version and return // if not, return last version UpsertConfigLastExportedVersion(ctx context.Context, css *ExportData) (string, error) }
type VersionValuable ¶
Click to show internal directories.
Click to hide internal directories.