mongosync

package
v0.0.0-...-94e71c2 Latest Latest
Warning

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

Go to latest
Published: Jun 22, 2019 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

View Source
const (
	OplogDatabaseName   = "local"
	OplogCollectionName = "oplog.rs"
	OplogOpUpdate       = "u"
	OplogOpDelete       = "d"
	OplogOpInsert       = "i"
	OplogOpCommand      = "c"
)

Variables

View Source
var Checkpoint = &checkpoint{checkpointMap: make(map[string]*primitive.Timestamp), mutex: &sync.Mutex{}}
View Source
var Config = &config{}
View Source
var DocManager = &docManager{mutex: &sync.Mutex{}, managers: make(map[string]managers.IDocManager)}
View Source
var SignalMonitor = &signalMonitor{}

Functions

func InitConfig

func InitConfig(path string) error

func NewClient

func NewClient(url string) *mongo.Client

func NewDocManager

func NewDocManager(shardId string) *docManager

func ParseNamespace

func ParseNamespace(ns string) (db, coll string)

func Run

func Run(config string)

Types

type MongoSync

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

func NewMongoSync

func NewMongoSync() *MongoSync

type Namespace

type Namespace struct {
	Ns   string
	Db   string
	Coll string
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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