Skip to content

docs: fix 17 typos in comments and log messages - #67

Open
Avicennasis wants to merge 1 commit into
uber:masterfrom
Avicennasis:docs/fix-typos
Open

docs: fix 17 typos in comments and log messages#67
Avicennasis wants to merge 1 commit into
uber:masterfrom
Avicennasis:docs/fix-typos

Conversation

@Avicennasis

Copy link
Copy Markdown

Summary

Fixes 17 typos in comments and two log-message strings. No functional changes.

util/util.go

  • // PostgresToDriverType converts mysql type names ... -> converts Postgres type names ... - the function switches on int2/int4/float4/numeric/varchar/bool, which are Postgres type names.
  • // ClickHouseToDriverType converts mysql type names ... -> converts ClickHouse type names ... - the function switches on int8..int64/uint8../float32/fixedstring, which are ClickHouse type names.
  • //QueryRowSQL executes SQL query which return single row -> which returns single row (same for QueryTxRowSQL)
  • //MySQLError checks if givens error is ... -> if given error is ...
  • // SortedGTIDString ... where UUIDs comes in -> where UUIDs come in

pipe/s3.go

Four doc comments still refer to Terrablob, but everything in the file is the S3 pipe (s3Pipe, s3Client, s3Consumer) and Type() returns "s3":

  • // s3Consumer consumes messages from Terrablob ... -> from S3 ...
  • // Type returns Pipe type as Terrablob -> as S3
  • //NewProducer registers a new Terrablob producer -> a new S3 producer
  • //NewConsumer registers a new Terrablob consumer -> a new S3 consumer

lock/lock.go

  • // is already held then TryLock is noop. -> then TryLockShared is noop. on TryLockShared - the doc block was copy-pasted from TryLock and still names the wrong method.
  • Errorf("Lock did not exists on release") -> "Lock did not exist on release"
  • Errorf("Lock was not hold by me") -> "Lock was not held by me"

streamer/buffer.go

  • // Its time to commit the batch -> // It's time to commit the batch
  • //Guarantee that we can loose no more than ... -> we can lose no more than ...
  • // log.Debugf("commont format received ... -> "common format received ... (commented-out debug line; CommonFormatEvent is the type involved)

log/log.go

  • //def is a instance of default logger -> //def is an instance of default logger

Note for reviewers

Two of these edits are inside Go string literals rather than comments (the Errorf messages in lock/lock.go). They are the only occurrences of those strings in the repository - nothing asserts on them - but flagging so you can review deliberately. Everything else is comment-only.

Spelling and grammar fixes in doc comments, plus two log message strings
in lock/lock.go. Also corrects four stale 'Terrablob' references in
pipe/s3.go and two copy-pasted 'mysql' references in util/util.go doc
comments that describe the Postgres and ClickHouse converters.

No functional changes; the only non-comment edits are the wording of two
Errorf strings, which nothing asserts on.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants