MCPcopy Create free account

hub / github.com/alibaba/MongoShake / functions

Functions933 in github.com/alibaba/MongoShake

↓ 308 callersMethodErrorf
(format string, args ...any)
pkg/log/logger.go:212
↓ 279 callersMethodPrintf
(format string, args ...any)
pkg/log/logger.go:179
↓ 234 callersMethodInfof
(format string, args ...any)
pkg/log/logger.go:198
↓ 160 callersMethodBatchMore
BatchMore ** * This function is used to gather oplogs together. * Honestly speaking, it's complicate so that reading unit tests may help you to make
collector/batcher.go:279
↓ 155 callersMethodSize
()
oplog/txn_buffer.go:75
↓ 126 callersFunctionmockOplogRecord
(oId, oX interface{}, o2Id int)
executor/db_writer_test.go:48
↓ 88 callersMethodWarnf
(format string, args ...any)
pkg/log/logger.go:205
↓ 66 callersMethodError
(format string, args ...any)
pkg/log/logger.go:249
↓ 66 callersFunctionmockOplogs
* * return oplogs array with length=input length. * ddlGiven array marks the ddl. * noopGiven array marks the noop. * sameTsGiven array marks the
collector/batcher_test.go:39
↓ 61 callersMethodCriticalf
(format string, args ...any)
pkg/log/logger.go:219
↓ 61 callersMethodDebugf
(format string, args ...any)
pkg/log/logger.go:191
↓ 54 callersMethodFatalf
(format string, args ...any)
pkg/log/logger.go:223
↓ 54 callersMethodPanicf
(format string, args ...any)
pkg/log/logger.go:230
↓ 53 callersFunctionGetKey
(log bson.D, wanted string)
oplog/oplog.go:130
↓ 51 callersMethodPrintln
(args ...any)
pkg/log/logger.go:187
↓ 43 callersFunctionFetchAllDocumentBsonM
(client *mongo.Client, testDb string, testCollection string, opts *options.FindOptions)
unit_test_common/common.go:25
↓ 43 callersFunctionmockTransLogs
(op, ns string, logObject bson.D)
executor/executor_test.go:201
↓ 40 callersMethodFilter
(log *oplog.PartialLog)
collector/filter/oplog_filter.go:16
↓ 38 callersFunctionmockSyncer
()
collector/batcher_test.go:18
↓ 37 callersFunctionmockLogs
(op, ns string, size int, cb bool)
executor/executor_test.go:16
↓ 29 callersFunctionNewBatcher
(syncer *OplogSyncer, filterList filter.OplogFilterChain, handler OplogHandler, workerGroup []*Worker)
collector/batcher.go:96
↓ 29 callersMethodselectSyncMode
if the oplog of checkpoint timestamp exist in all source db, then only do oplog replication instead of document replication
collector/coordinator/utils.go:144
↓ 28 callersFunctionNewDbWriter
NewDbWriter return a new writer, could be: 1) SingleWriter; 2) BulkWriter; (by default for MongoDB3.2+) 3) CommandWriter; (for gid enabled)
executor/db_writer.go:53
↓ 28 callersMethoddoUpdate
update operation
executor/db_writer.go:32
↓ 26 callersMethoddoInsert
insert operation
executor/db_writer.go:26
↓ 25 callersFunctionobjectIdFromInt
(num int64)
executor/db_writer_test.go:77
↓ 25 callersFunctionrunByte
(input []byte)
oplog/change_stream_event_test.go:394
↓ 24 callersMethodClose
()
collector/docsyncer/doc_syncer.go:383
↓ 24 callersMethodFilter
(log *oplog.PartialLog)
collector/filter/oplog_filter.go:273
↓ 24 callersMethodGet
Get return persistent checkpoint
collector/ckpt/ckpt_manager.go:60
↓ 24 callersMethodRead
()
tunnel/kafka/reader.go:48
↓ 23 callersMethodTransform
(db string)
collector/transform/transform.go:48
↓ 22 callersMethodString
String return log info
collector/ckpt/ckpt_operation.go:55
↓ 22 callersMethodUpdate
Update checkpoint update memory & persistence(db or file)
collector/ckpt/ckpt_manager.go:84
↓ 21 callersFunctionNewNamespaceFilter
(white, black []string)
collector/filter/oplog_filter.go:261
↓ 20 callersFunctionNewCheckpointManager
(name string, startPosition int64)
collector/ckpt/ckpt_manager.go:25
↓ 20 callersFunctionNewNamespaceTransform
(transRule []string)
collector/transform/transform.go:29
↓ 19 callersFunctionHash
(hashObject interface{})
oplog/hasher.go:159
↓ 17 callersMethodClose
()
common/community_client.go:173
↓ 17 callersMethodNext
update query timestamp
collector/reader/reader.go:14
↓ 16 callersMethodDistributeOplogByMod
(log *PartialLog, mod int)
oplog/hasher.go:21
↓ 16 callersFunctionmockDeleteOplogRecord
(oId interface{})
executor/db_writer_test.go:31
↓ 16 callersFunctionparseLastTimestamp
(oplogs []*OplogRecord)
executor/db_writer.go:370
↓ 15 callersMethodInject
Inject inject data
collector/persister.go:135
↓ 15 callersMethodSync
** * Replay oplog entry with batched Oplog * */
tunnel/tunnel.go:218
↓ 15 callersMethoddoUpdateOnInsert
update when insert duplicated
executor/db_writer.go:29
↓ 14 callersMethodFilter
(log *oplog.PartialLog)
collector/filter/oplog_filter.go:50
↓ 14 callersFunctionIgnoreError
IgnoreError return true if error can be ignored https://github.com/mongodb/mongo/blob/master/src/mongo/base/error_codes.yml
executor/db_writer.go:326
↓ 14 callersFunctionRemoveFiled
RemoveFiled remove specified field in bson.D and return the one after modify
oplog/oplog.go:216
↓ 14 callersFunctiontransformLogs
if no need to transform namespace, return original logs for no command log, transform namespace in DBRef by conf.Options.TransformDBRef for command lo
executor/executor.go:267
↓ 13 callersMethodFatal
(args ...any)
pkg/log/logger.go:257
↓ 13 callersFunctionRunCommand
(database, operation string, log *oplog.PartialLog, client *mongo.Client)
executor/db_writer.go:65
↓ 13 callersFunctionlog_info
(message)
scripts/comparison_3x.py:22
↓ 12 callersFunctionBlockMongoUrlPassword
BlockMongoUrlPassword block password in two kinds of mongo_urls: 1) "mongodb://username:password@address" 2) "username:password@address"
common/common.go:112
↓ 12 callersMethodClose
()
common/speed.go:92
↓ 12 callersFunctionGetAndCompareVersion
GetAndCompareVersion get current db version and compare to threshold. Return whether the result is bigger or equal to the input threshold.
common/db_opertion.go:68
↓ 12 callersFunctionNewMongoCommunityConn
(url string, connectMode string, timeout bool, readConcern, writeConcern string, sslRootFile string)
common/community_client.go:78
↓ 12 callersFunctionNewOpTypeFilter
NewOpTypeFilter trusts sanitize to provide normalized op type values.
collector/filter/oplog_filter.go:37
↓ 12 callersMethodsplit
split oplogs into safety segments
executor/collision_matrix.go:30
↓ 11 callersMethodClose
()
tunnel/kafka/sync_writer.go:67
↓ 11 callersMethodDone
()
tunnel/kafka/saram_client.go:35
↓ 11 callersMethodcalculateWorkerLowestCheckpoint
()
collector/checkpoint.go:148
↓ 11 callersFunctionlog_info
(message)
tools/data_generator.py:21
↓ 10 callersMethodClose
()
pkg/log/logger.go:287
↓ 10 callersFunctionExtraCommandName
(o bson.D)
oplog/cmd_oplog.go:37
↓ 10 callersFunctionNew
(logLevel, logDir, logFile string, logFlush bool, maxSizeMB, maxAge, verbose int)
pkg/log/logger.go:43
↓ 10 callersFunctionNormalizeApplyOps
NormalizeApplyOps extracts and normalizes applyOps into []bson.D so callers can share one BSON-container compatibility path while keeping their own ap
oplog/apply_ops.go:13
↓ 10 callersFunctionSetFiled
(input bson.D, key string, value interface{})
oplog/oplog.go:241
↓ 10 callersMethodWait
()
collector/docsyncer/doc_executor.go:105
↓ 10 callersFunctioncalculateTop3
(inputMap sync.Map)
executor/executor.go:446
↓ 10 callersFunctiongetAllDoc
(db, coll string)
oplog/change_stream_event_test.go:404
↓ 10 callersMethodgetBatchWithDelay
* * if delay > 0, this function wait till delay timeout. * However, if the mergeBatch contain may oplogs, the delay time will depend on the first *
collector/batcher.go:207
↓ 10 callersFunctionlog_info
(message)
scripts/comparison.py:21
↓ 10 callersFunctionmockCheckpointSyncer
(workerNum int)
collector/checkpoint_test.go:10
↓ 9 callersFunctionlog_error
(message)
scripts/comparison_3x.py:25
↓ 9 callersFunctionlog_error
(message)
scripts/comparison.py:24
↓ 9 callersFunctionmockLog
mock oplog with different namespace
collector/syncer_test.go:19
↓ 9 callersFunctionmockOplogsBinary
()
collector/persister_test.go:14
↓ 9 callersFunctionnewMongoClient
newMongoClient only used in unit test
oplog/change_stream_event_test.go:80
↓ 8 callersFunctionConvertBsonD2M
ConvertBsonD2M convert bson.D to bson.M
oplog/oplog.go:173
↓ 8 callersMethodGetInMemory
GetInMemory return in-memory checkpoint
collector/ckpt/ckpt_manager.go:79
↓ 8 callersFunctionInt64ToTimestamp
(t int64)
common/mix.go:38
↓ 8 callersMethodIsTxn
IsTxn is true if the oplog entry is part of any transaction, i.e. the lsid field exists.
oplog/txn_meta.go:132
↓ 8 callersMethodaddOperationMetric
(op string, count uint64)
executor/operation.go:155
↓ 8 callersMethodmergeToGroups
(logs []*OplogRecord)
executor/combiner.go:27
↓ 7 callersFunctionDiffUpdateOplogToNormal
DiffUpdateOplogToNormal convert diff update oplog(v2) to normal one(v1) * Oplog from mongod(5.0) in sharding&replica》 Example 1: { "ts": {"T": 165
oplog/oplog.go:351
↓ 7 callersFunctionExtractMongoTimestamp
(ts interface{})
common/mix.go:51
↓ 7 callersMethodGet
Get read checkpoint from remote storage. and encapsulation with CheckpointContext struct bool means whether exists on remote
collector/ckpt/ckpt_operation.go:49
↓ 7 callersFunctionNewTxnMeta
NewTxnMeta extracts transaction metadata from an oplog entry. A non-transaction will return a zero-value TxnMeta struct, not an error. Currently the
oplog/txn_meta.go:50
↓ 7 callersMethodRun
()
collector/coordinator/extra_job.go:26
↓ 7 callersMethodStr
()
common/session.go:22
↓ 7 callersMethodaddNsMapMetric
(ns, op string, count int)
executor/operation.go:191
↓ 7 callersFunctioncrash
(msg string, errCode int)
cmd/collector/collector.go:229
↓ 7 callersMethoddoDelete
delete operation
executor/db_writer.go:35
↓ 7 callersMethodget
internal get next oplog. Used in Next() and NextOplog(). The channel and current function may both return timeout which is acceptable.
collector/reader/oplog_reader.go:125
↓ 7 callersFunctionhasOriginalSpec
hasOriginalSpec checks if a commitIndexBuild/createIndexes oplog contains originalSpec in any of its indexes. Time-series collection indexes have orig
executor/db_writer.go:381
↓ 6 callersMethodCreate
create specific Tunnel with tunnel name and pass connection or usefully meta
tunnel/tunnel.go:159
↓ 6 callersMethodDistributeOplogByMod
(log *PartialLog, mod int)
oplog/hasher.go:100
↓ 6 callersMethodDump
Dump will dump oplog according to the given keys, "all" == true means ignore keys
oplog/oplog.go:110
↓ 6 callersMethodFilter
(log *oplog.PartialLog)
collector/filter/oplog_filter.go:159
next →1–100 of 933, ranked by callers