Documentation
¶
Index ¶
Constants ¶
View Source
const ( PendingStatus = "pending" DoneStatus = "done" )
View Source
const ( CreateAction = "create" UpdateAction = "update" DeleteAction = "delete" Default = "default" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Task ¶
type Task struct { ID string `json:"id" bson:"id"` Domain string `json:"domain" bson:"domain"` Project string `json:"project" bson:"project"` ResourceType string `json:"resource_type" bson:"resource_type"` Resource []byte `json:"resource" bson:"resource"` Opts map[string]string `json:"opts" bson:"opts"` Action string `json:"action" bson:"action"` Timestamp int64 `json:"timestamp" bson:"timestamp"` Status string `json:"status" bson:"status"` }
Task is db struct to store sync task
type Tombstone ¶
type Tombstone struct { ResourceID string `json:"resource_id" bson:"resource_id"` ResourceType string `json:"resource_type" bson:"resource_type"` Domain string `json:"domain" bson:"domain"` Project string `json:"project" bson:"project"` Timestamp int64 `json:"timestamp" bson:"timestamp"` }
Tombstone is db struct to store the deleted resource information
func NewTombstone ¶
NewTombstone return tombstone with resourceID,resourceType ,domain and project
Click to show internal directories.
Click to hide internal directories.