Documentation ¶
Index ¶
Constants ¶
View Source
const ( PanicChangeMetaNotSet string = "change meta not set" PanicRegistrationMetaNotSet string = "change meta not set" PanicRegistrationChangeMetaNotSet string = "change meta not set" ChangeIdNotProvided string = "change id not provided" RegisterFilterHandlerNotProvided string = "unable to register; neither fitler or handler not provided" DefaultQueueSize int = 100 )
Variables ¶
View Source
var ( ErrChangeIdNotProvided = errors.New(ChangeIdNotProvided) ErrRegisterFilterHandlerNotProvided = errors.New(RegisterFilterHandlerNotProvided) QueueSize = DefaultQueueSize )
Functions ¶
func New ¶
func New() interface { Logic healthchecklogic.Logic internal.Initializer internal.Parameterizer }
New will generate a new instance of logic that implements the interfaces Logic and Owner, from the provided parameters we can set the logger and the employee meta (required)
Types ¶
type Logic ¶
type Logic interface { //changes ChangeUpsert(ctx context.Context, change data.ChangePartial) (*data.Change, error) ChangeRead(ctx context.Context, changeId string) (*data.Change, error) ChangesRead(ctx context.Context, search data.ChangeSearch) ([]*data.Change, error) ChangesDelete(ctx context.Context, changeIds ...string) error //registrations RegistrationUpsert(ctx context.Context, registrationId string) error RegistrationChangesRead(ctx context.Context, registrationId string) ([]*data.Change, error) RegistrationChangeAcknowledge(ctx context.Context, registrationId string, changeIds ...string) error RegistrationDelete(ctx context.Context, registrationId string) error //handlers HandlerCreate(ctx context.Context, handleFx HandlerFx) (handlerId string, err error) HandlerDelete(ctx context.Context, handlerId string) error }
Click to show internal directories.
Click to hide internal directories.