oplog

package
v0.3.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 14, 2019 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type OplogApply

type OplogApply struct {
	// contains filtered or unexported fields
}

func NewOplogApply

func NewOplogApply(session *mgo.Session, r bsonfile.BSONReader) (*OplogApply, error)

func NewOplogApplyUntil

func NewOplogApplyUntil(session *mgo.Session, r bsonfile.BSONReader, stopAtTs bson.MongoTimestamp) (*OplogApply, error)

func (*OplogApply) Count

func (oa *OplogApply) Count() int64

func (*OplogApply) Run

func (oa *OplogApply) Run() error

type OplogTail

type OplogTail struct {
	// contains filtered or unexported fields
}

func Open

func Open(session *mgo.Session) (*OplogTail, error)

func OpenAt

func OpenAt(session *mgo.Session, t time.Time, c uint32) (*OplogTail, error)

func (*OplogTail) Cancel

func (ot *OplogTail) Cancel()

Cancel stopts the tailer immediately without waiting the tailer to reach the document having timestamp = IsMasterDoc().LastWrite.OpTime.Ts

func (*OplogTail) Close

func (ot *OplogTail) Close() error

func (*OplogTail) CloseAt

func (ot *OplogTail) CloseAt(ts bson.MongoTimestamp) error

func (*OplogTail) Count

func (ot *OplogTail) Count() uint64

func (*OplogTail) LastOplogTimestamp

func (ot *OplogTail) LastOplogTimestamp() bson.MongoTimestamp

func (*OplogTail) Read

func (ot *OplogTail) Read(buf []byte) (int, error)

Implement the Reader interface to be able to pipe it into an S3 stream or through an encrypter

func (*OplogTail) Size

func (ot *OplogTail) Size() uint64

func (*OplogTail) WaitUntilFirstDoc

func (ot *OplogTail) WaitUntilFirstDoc() error

func (*OplogTail) WaitUntilFirstDocWithTimeout

func (ot *OplogTail) WaitUntilFirstDocWithTimeout(timeout time.Duration) (bool, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL