Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DataNode ¶
type DataNode interface { Create(data []byte) (string, error) Read(sha512Hex string, begins uint32, ends uint32, readHandler func(data []byte) error) error Delete(sha512Hex string) error HardwareId() (string, error) Join(clusterId string, nodeId string, masterAddress string) bool Mode(master bool) bool Leave() bool Wipe() bool SyncCreate(sha512Hex string, usage uint16, sourceNodeAddr string) error SyncDelete(sha512Hex string, usage uint16) error SyncMove(sha512Hex string, sourceNodeAddr string) error SyncList(snapshotTime *time.Time) (*common.SyncContainer, error) SyncFull(sourceNodeAddr string) bool SyncUsage(usageMap map[string]uint16) error SnapshotCreate() bool SnapshotDelete(snapshotIndex uint64) bool SnapshotRestore(snapshotIndex uint64) bool Ping() int64 Size() (uint64, error) Used() (uint64, error) RequestHandshake() bool }
func NewDataNode ¶
Click to show internal directories.
Click to hide internal directories.