From e9028ce571d3e16a084f7c2f3de0b2efe466a809 Mon Sep 17 00:00:00 2001 From: Ti Chi Robot Date: Fri, 17 Dec 2021 18:46:39 +0800 Subject: [PATCH 1/2] pkg,cdc: do not use log package (#3902) (#3941) --- .golangci.yml | 13 +++++++++++++ cdc/processor/pipeline/mounter.go | 2 +- cdc/puller/frontier/list.go | 3 ++- cdc/sink/codec/canal.go | 2 +- cdc/sink/common/flow_control.go | 2 +- integration/tests/case_date_time.go | 2 +- pkg/context/context.go | 2 +- pkg/context/context_test.go | 2 +- pkg/etcd/etcdkey.go | 2 +- pkg/orchestrator/util/key_utils.go | 3 ++- 10 files changed, 24 insertions(+), 9 deletions(-) diff --git a/.golangci.yml b/.golangci.yml index b19a99a8dca..a6c7a6830d5 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -2,3 +2,16 @@ linters: enable: - unconvert - unparam + - depguard + +linters-settings: + depguard: + list-type: blacklist + include-go-root: false + packages: + - log + - github.com/juju/errors + packages-with-error-message: + # specify an error message to output when a blacklisted package is used + - log: "logging is allowed only by pingcap/log" + - github.com/juju/errors: "error handling is allowed only by pingcap/errors" diff --git a/cdc/processor/pipeline/mounter.go b/cdc/processor/pipeline/mounter.go index 1bfc94b43c4..2e156b9cdbd 100644 --- a/cdc/processor/pipeline/mounter.go +++ b/cdc/processor/pipeline/mounter.go @@ -15,12 +15,12 @@ package pipeline import ( "context" - "log" "sync" "time" "github.com/edwingeng/deque" "github.com/pingcap/failpoint" + "github.com/pingcap/log" "github.com/pingcap/ticdc/cdc/model" "github.com/pingcap/ticdc/pkg/notify" "github.com/pingcap/ticdc/pkg/pipeline" diff --git a/cdc/puller/frontier/list.go b/cdc/puller/frontier/list.go index 2a14aeafff8..249127d6bfb 100644 --- a/cdc/puller/frontier/list.go +++ b/cdc/puller/frontier/list.go @@ -16,11 +16,12 @@ package frontier import ( "bytes" "fmt" - "log" "math" "strings" _ "unsafe" // required by go:linkname + + "github.com/pingcap/log" ) const ( diff --git a/cdc/sink/codec/canal.go b/cdc/sink/codec/canal.go index df9a9ed4022..76aee5f562c 100644 --- a/cdc/sink/codec/canal.go +++ b/cdc/sink/codec/canal.go @@ -15,12 +15,12 @@ package codec import ( "fmt" - "log" "strconv" "strings" "github.com/golang/protobuf/proto" "github.com/pingcap/errors" + "github.com/pingcap/log" mm "github.com/pingcap/parser/model" "github.com/pingcap/parser/mysql" parser_types "github.com/pingcap/parser/types" diff --git a/cdc/sink/common/flow_control.go b/cdc/sink/common/flow_control.go index 47ad19fc6b7..a008d58b25a 100644 --- a/cdc/sink/common/flow_control.go +++ b/cdc/sink/common/flow_control.go @@ -14,12 +14,12 @@ package common import ( - "log" "sync" "sync/atomic" "github.com/edwingeng/deque" "github.com/pingcap/errors" + "github.com/pingcap/log" cerrors "github.com/pingcap/ticdc/pkg/errors" "go.uber.org/zap" ) diff --git a/integration/tests/case_date_time.go b/integration/tests/case_date_time.go index 8d5f622a398..ac060b94036 100644 --- a/integration/tests/case_date_time.go +++ b/integration/tests/case_date_time.go @@ -15,9 +15,9 @@ package tests import ( "errors" - "log" "time" + "github.com/pingcap/log" "github.com/pingcap/ticdc/integration/framework" "github.com/pingcap/ticdc/integration/framework/avro" "github.com/pingcap/ticdc/integration/framework/canal" diff --git a/pkg/context/context.go b/pkg/context/context.go index e8e2ed81925..843d91ce7a9 100644 --- a/pkg/context/context.go +++ b/pkg/context/context.go @@ -15,9 +15,9 @@ package context import ( "context" - "log" "time" + "github.com/pingcap/log" "github.com/pingcap/ticdc/cdc/kv" "github.com/pingcap/ticdc/cdc/model" "github.com/pingcap/ticdc/pkg/config" diff --git a/pkg/context/context_test.go b/pkg/context/context_test.go index 78186e1673d..b0caee01c3f 100644 --- a/pkg/context/context_test.go +++ b/pkg/context/context_test.go @@ -136,7 +136,7 @@ func (s *contextSuite) TestThrowPanic(c *check.C) { defer testleak.AfterTest(c)() defer func() { panicMsg := recover() - c.Assert(panicMsg, check.Equals, "an error has escaped, please report a bug{error 26 0 mock error}") + c.Assert(panicMsg, check.Equals, "an error has escaped, please report a bug") }() stdCtx := context.Background() ctx := NewContext(stdCtx, &GlobalVars{}) diff --git a/pkg/etcd/etcdkey.go b/pkg/etcd/etcdkey.go index 51d4c91cf0a..ca7ac9cfe15 100644 --- a/pkg/etcd/etcdkey.go +++ b/pkg/etcd/etcdkey.go @@ -14,9 +14,9 @@ package etcd import ( - "log" "strings" + "github.com/pingcap/log" cerror "github.com/pingcap/ticdc/pkg/errors" ) diff --git a/pkg/orchestrator/util/key_utils.go b/pkg/orchestrator/util/key_utils.go index e9b68ca491c..008c8ae9705 100644 --- a/pkg/orchestrator/util/key_utils.go +++ b/pkg/orchestrator/util/key_utils.go @@ -14,8 +14,9 @@ package util import ( - "log" "strings" + + "github.com/pingcap/log" ) // EtcdKey represents a complete key in Etcd. From 784e7d011f8524689897969017c4b0db91bea245 Mon Sep 17 00:00:00 2001 From: amyangfei Date: Sat, 18 Dec 2021 17:44:36 +0800 Subject: [PATCH 2/2] *: rename repo from pingcap/ticdc to pingcap/tiflow (#3954) --- Dockerfile | 4 +- Dockerfile.development | 4 +- Makefile | 8 +- README.md | 8 +- cdc/async_sink.go | 10 +-- cdc/async_sink_test.go | 14 ++-- cdc/capture.go | 18 ++-- cdc/capture/capture.go | 20 ++--- cdc/capture_test.go | 18 ++-- cdc/changefeed.go | 18 ++-- cdc/changefeed_test.go | 10 +-- cdc/entry/codec.go | 4 +- cdc/entry/codec_test.go | 2 +- cdc/entry/mounter.go | 6 +- cdc/entry/mounter_test.go | 6 +- cdc/entry/schema_storage.go | 8 +- cdc/entry/schema_storage_test.go | 6 +- cdc/http_api_handler.go | 6 +- cdc/http_handler.go | 10 +-- cdc/http_status.go | 10 +-- cdc/http_status_test.go | 8 +- cdc/kv/client.go | 16 ++-- cdc/kv/client_bench_test.go | 6 +- cdc/kv/client_mock_test.go | 2 +- cdc/kv/client_test.go | 82 +++++++++---------- cdc/kv/etcd.go | 10 +-- cdc/kv/etcd_test.go | 10 +-- cdc/kv/grpc_pool_impl.go | 4 +- cdc/kv/grpc_pool_impl_test.go | 4 +- cdc/kv/matcher_test.go | 2 +- cdc/kv/region_worker.go | 12 +-- cdc/kv/region_worker_test.go | 4 +- cdc/kv/resolvedts_heap_test.go | 2 +- cdc/kv/store_op.go | 8 +- cdc/kv/testing.go | 8 +- cdc/kv/token_region.go | 2 +- cdc/kv/token_region_test.go | 2 +- cdc/metrics.go | 20 ++--- cdc/model/capture.go | 2 +- cdc/model/capture_test.go | 2 +- cdc/model/changefeed.go | 6 +- cdc/model/changefeed_test.go | 6 +- cdc/model/kv.go | 2 +- cdc/model/kv_test.go | 4 +- cdc/model/mounter_test.go | 2 +- cdc/model/owner.go | 2 +- cdc/model/owner_test.go | 2 +- cdc/model/reactor_state.go | 8 +- cdc/model/reactor_state_test.go | 8 +- cdc/model/schema_storage_test.go | 2 +- cdc/model/sink.go | 4 +- cdc/model/sink_test.go | 2 +- cdc/model/string.go | 2 +- cdc/model/string_test.go | 2 +- cdc/owner.go | 24 +++--- cdc/owner/async_sink.go | 10 +-- cdc/owner/async_sink_test.go | 14 ++-- cdc/owner/barrier.go | 2 +- cdc/owner/barrier_test.go | 4 +- cdc/owner/changefeed.go | 10 +-- cdc/owner/changefeed_test.go | 20 ++--- cdc/owner/ddl_puller.go | 14 ++-- cdc/owner/ddl_puller_test.go | 8 +- cdc/owner/feed_state_manager.go | 4 +- cdc/owner/feed_state_manager_test.go | 10 +-- cdc/owner/owner.go | 12 +-- cdc/owner/owner_test.go | 16 ++-- cdc/owner/scheduler.go | 4 +- cdc/owner/scheduler_test.go | 6 +- cdc/owner/schema.go | 12 +-- cdc/owner/schema_test.go | 8 +- cdc/owner_operator.go | 12 +-- cdc/owner_test.go | 22 ++--- cdc/processor.go | 28 +++---- cdc/processor/manager.go | 10 +-- cdc/processor/manager_test.go | 14 ++-- cdc/processor/pipeline/cyclic_mark.go | 8 +- cdc/processor/pipeline/cyclic_mark_test.go | 12 +-- cdc/processor/pipeline/mounter.go | 6 +- cdc/processor/pipeline/mounter_test.go | 10 +-- cdc/processor/pipeline/puller.go | 12 +-- cdc/processor/pipeline/sink.go | 8 +- cdc/processor/pipeline/sink_test.go | 12 +-- cdc/processor/pipeline/sorter.go | 12 +-- cdc/processor/pipeline/sorter_test.go | 12 +-- cdc/processor/pipeline/table.go | 16 ++-- cdc/processor/processor.go | 28 +++---- cdc/processor/processor_test.go | 12 +-- cdc/processor_test.go | 18 ++-- cdc/puller/entry_sorter.go | 6 +- cdc/puller/entry_sorter_test.go | 4 +- cdc/puller/frontier/frontier.go | 2 +- cdc/puller/frontier/frontier_bench_test.go | 2 +- cdc/puller/frontier/frontier_test.go | 4 +- cdc/puller/frontier/heap_test.go | 2 +- cdc/puller/frontier/list_test.go | 2 +- cdc/puller/mock_puller.go | 4 +- cdc/puller/mock_puller_test.go | 6 +- cdc/puller/puller.go | 14 ++-- cdc/puller/puller_test.go | 16 ++-- cdc/puller/sorter.go | 2 +- cdc/puller/sorter/backend.go | 2 +- cdc/puller/sorter/backend_pool.go | 8 +- cdc/puller/sorter/backend_pool_test.go | 20 ++--- cdc/puller/sorter/file_backend.go | 4 +- cdc/puller/sorter/file_backend_test.go | 6 +- cdc/puller/sorter/heap.go | 2 +- cdc/puller/sorter/heap_sorter.go | 10 +-- cdc/puller/sorter/memory_backend.go | 2 +- cdc/puller/sorter/memory_backend_test.go | 4 +- cdc/puller/sorter/merger.go | 8 +- cdc/puller/sorter/merger_test.go | 28 +++---- cdc/puller/sorter/serde.go | 2 +- cdc/puller/sorter/sorter_test.go | 40 ++++----- cdc/puller/sorter/unified_sorter.go | 8 +- cdc/server.go | 16 ++-- cdc/server_test.go | 12 +-- cdc/sink/black_hole.go | 2 +- cdc/sink/causality.go | 2 +- cdc/sink/causality_test.go | 4 +- cdc/sink/cdclog/file.go | 8 +- cdc/sink/cdclog/s3.go | 8 +- cdc/sink/cdclog/utils.go | 6 +- cdc/sink/codec/avro.go | 4 +- cdc/sink/codec/avro_test.go | 10 +-- cdc/sink/codec/canal.go | 6 +- cdc/sink/codec/canal_flat.go | 6 +- cdc/sink/codec/canal_flat_test.go | 4 +- cdc/sink/codec/canal_test.go | 6 +- cdc/sink/codec/interface.go | 2 +- cdc/sink/codec/interface_test.go | 4 +- cdc/sink/codec/json.go | 4 +- cdc/sink/codec/json_test.go | 4 +- cdc/sink/codec/maxwell.go | 4 +- cdc/sink/codec/maxwell_test.go | 4 +- cdc/sink/codec/schema_registry.go | 8 +- cdc/sink/codec/schema_registry_test.go | 6 +- cdc/sink/common/common.go | 4 +- cdc/sink/common/common_test.go | 4 +- cdc/sink/common/flow_control.go | 2 +- cdc/sink/common/flow_control_test.go | 2 +- cdc/sink/dispatcher/default.go | 2 +- cdc/sink/dispatcher/default_test.go | 4 +- cdc/sink/dispatcher/dispatcher.go | 6 +- cdc/sink/dispatcher/index_value.go | 4 +- cdc/sink/dispatcher/index_value_test.go | 4 +- cdc/sink/dispatcher/switcher_test.go | 6 +- cdc/sink/dispatcher/table.go | 4 +- cdc/sink/dispatcher/table_test.go | 4 +- cdc/sink/dispatcher/ts.go | 2 +- cdc/sink/dispatcher/ts_test.go | 4 +- cdc/sink/manager.go | 4 +- cdc/sink/manager_test.go | 6 +- cdc/sink/mq.go | 24 +++--- cdc/sink/mq_test.go | 22 ++--- cdc/sink/mysql.go | 26 +++--- cdc/sink/mysql_test.go | 18 ++-- cdc/sink/producer/kafka/kafka.go | 14 ++-- cdc/sink/producer/kafka/kafka_test.go | 28 +++---- cdc/sink/producer/mq_producer.go | 2 +- cdc/sink/producer/pulsar/producer.go | 4 +- cdc/sink/simple_mysql_tester.go | 10 +-- cdc/sink/sink.go | 10 +-- cdc/sink/statistics.go | 2 +- cdc/sink/syncpointStore.go | 4 +- cdc/sink/txns_heap.go | 2 +- cdc/sink/txns_heap_test.go | 4 +- cdc/task.go | 4 +- cdc/task_test.go | 12 +-- cmd/cdc/main.go | 2 +- cmd/client.go | 10 +-- cmd/client_changefeed.go | 18 ++-- cmd/client_changefeed_test.go | 2 +- cmd/client_processor.go | 2 +- cmd/client_unsafe.go | 2 +- cmd/cmd_test.go | 4 +- cmd/kafka-consumer/main.go | 18 ++-- cmd/server.go | 14 ++-- cmd/server_test.go | 4 +- cmd/test.go | 2 +- cmd/util.go | 22 ++--- cmd/util_test.go | 2 +- cmd/version.go | 2 +- demo/java/README.md | 4 +- ...5-ticdc-high-availability-new-design-cn.md | 6 +- go.mod | 2 +- .../framework/avro/kafka_docker_env.go | 2 +- .../framework/avro/kafka_docker_env_test.go | 2 +- .../framework/avro/kafka_single_table.go | 2 +- .../framework/avro/kafka_single_table_test.go | 2 +- .../framework/canal/kafka_docker_env.go | 2 +- .../framework/canal/kafka_docker_env_test.go | 2 +- .../framework/canal/kafka_single_table.go | 2 +- .../canal/kafka_single_table_test.go | 2 +- integration/framework/docker_compose_op.go | 4 +- integration/framework/docker_env.go | 4 +- integration/framework/mysql/docker_env.go | 2 +- .../framework/mysql/docker_env_test.go | 2 +- integration/framework/mysql/single_table.go | 2 +- .../framework/mysql/single_table_test.go | 2 +- integration/framework/sql_helper.go | 2 +- integration/integration.go | 12 +-- integration/tests/case_alter.go | 2 +- integration/tests/case_composite_pkey.go | 2 +- integration/tests/case_date_time.go | 8 +- integration/tests/case_delete.go | 2 +- integration/tests/case_many_types.go | 8 +- integration/tests/case_simple.go | 2 +- integration/tests/case_unsigned.go | 2 +- kafka_consumer/Dockerfile | 4 +- pkg/config/config.go | 6 +- pkg/config/config_test.go | 2 +- pkg/config/sorter.go | 2 +- pkg/context/context.go | 10 +-- pkg/context/context_test.go | 6 +- pkg/cyclic/filter.go | 4 +- pkg/cyclic/filter_test.go | 6 +- pkg/cyclic/mark/mark.go | 6 +- pkg/cyclic/mark/mark_test.go | 2 +- pkg/cyclic/replication.go | 8 +- pkg/cyclic/replication_test.go | 8 +- pkg/errors/helper_test.go | 2 +- pkg/etcd/client.go | 4 +- pkg/etcd/client_test.go | 2 +- pkg/etcd/etcd_test.go | 2 +- pkg/etcd/etcdkey.go | 2 +- pkg/etcd/etcdkey_test.go | 2 +- pkg/filelock/filelock.go | 2 +- pkg/filelock/filelock_test.go | 2 +- pkg/filter/filter.go | 6 +- pkg/filter/filter_test.go | 4 +- pkg/flags/urls.go | 2 +- pkg/flags/urls_test.go | 2 +- pkg/httputil/httputil.go | 4 +- pkg/httputil/httputil_test.go | 4 +- pkg/logutil/log.go | 4 +- pkg/logutil/log_test.go | 2 +- pkg/notify/notify.go | 2 +- pkg/notify/notify_test.go | 4 +- pkg/orchestrator/batch.go | 4 +- pkg/orchestrator/batch_test.go | 2 +- pkg/orchestrator/etcd_worker.go | 6 +- pkg/orchestrator/etcd_worker_bank_test.go | 6 +- pkg/orchestrator/etcd_worker_test.go | 8 +- pkg/orchestrator/interfaces.go | 2 +- pkg/orchestrator/reactor_state_tester.go | 4 +- pkg/orchestrator/util/key_utils_test.go | 2 +- pkg/pdtime/acquirer.go | 2 +- pkg/pdtime/acquirer_test.go | 2 +- pkg/pipeline/context.go | 2 +- pkg/pipeline/message.go | 2 +- pkg/pipeline/pipeline.go | 4 +- pkg/pipeline/pipeline_test.go | 10 +-- pkg/pipeline/runner.go | 2 +- pkg/pipeline/test.go | 2 +- pkg/quotes/quotes_test.go | 2 +- pkg/regionspan/region_range_lock_test.go | 2 +- pkg/regionspan/region_test.go | 2 +- pkg/regionspan/span.go | 2 +- pkg/regionspan/span_test.go | 2 +- pkg/retry/retry_test.go | 2 +- pkg/retry/retry_with_opt.go | 2 +- pkg/scheduler/interface.go | 2 +- pkg/scheduler/table_number.go | 2 +- pkg/scheduler/table_number_test.go | 4 +- pkg/scheduler/workload.go | 2 +- pkg/scheduler/workload_test.go | 4 +- pkg/security/credential.go | 2 +- pkg/txnutil/gc/gc_manager.go | 8 +- pkg/txnutil/gc/gc_manager_test.go | 8 +- pkg/txnutil/gc/gc_service.go | 4 +- pkg/txnutil/gc/gc_service_test.go | 2 +- pkg/types/urls.go | 2 +- pkg/types/urls_test.go | 2 +- pkg/util/bitflag_test.go | 2 +- pkg/util/ctx_test.go | 2 +- pkg/util/fileutil.go | 4 +- pkg/util/fileutil_test.go | 8 +- pkg/util/gc_service.go | 4 +- pkg/util/gc_service_test.go | 2 +- pkg/util/overlap_merge_test.go | 2 +- pkg/util/test_helper_test.go | 2 +- pkg/util/testleak/leaktest.go | 8 +- pkg/util/tz.go | 2 +- pkg/util/tz_test.go | 2 +- pkg/version/check.go | 6 +- pkg/version/check_test.go | 2 +- pkg/version/version.go | 2 +- pkg/workerpool/async_pool_impl.go | 4 +- pkg/workerpool/async_pool_test.go | 2 +- pkg/workerpool/pool_impl.go | 4 +- pkg/workerpool/pool_test.go | 12 +-- scripts/jenkins_ci/cdc_ghpr_build.groovy | 2 +- scripts/jenkins_ci/cdc_ghpr_check.groovy | 2 +- .../cdc_ghpr_integration_test.groovy | 2 +- .../cdc_ghpr_kafka_integration_test.groovy | 6 +- scripts/jenkins_ci/cdc_ghpr_leak_test.groovy | 2 +- scripts/jenkins_ci/cdc_ghpr_test.groovy | 2 +- .../jenkins_ci/integration_test_common.groovy | 18 ++-- .../cdc_state_checker/cdc_monitor.go | 8 +- testing_utils/cdc_state_checker/main.go | 2 +- testing_utils/cdc_state_checker/reactor.go | 4 +- testing_utils/cdc_state_checker/state.go | 8 +- .../many_sorters_test/many_sorters.go | 12 +-- .../sorter_stress_test/sorter_stress.go | 10 +-- .../_utils/run_cdc_cli_tso_query | 2 +- tests/integration_tests/availability/owner.sh | 6 +- tests/integration_tests/bank/case.go | 2 +- .../capture_session_done_during_task/run.sh | 2 +- .../run.sh | 2 +- tests/integration_tests/cdc/cdc.go | 4 +- .../changefeed_auto_stop/run.sh | 2 +- .../integration_tests/changefeed_error/run.sh | 8 +- .../changefeed_fast_fail/run.sh | 2 +- tests/integration_tests/dailytest/db.go | 2 +- tests/integration_tests/ddl_async/run.sh | 2 +- tests/integration_tests/ddl_puller_lag/run.sh | 2 +- .../force_replicate_table/run.sh | 2 +- tests/integration_tests/gc_safepoint/run.sh | 2 +- .../kafka_sink_error_resume/run.sh | 2 +- .../kill_owner_with_ddl/run.sh | 2 +- .../kv_client_stream_reconnect/run.sh | 2 +- tests/integration_tests/many_pk_or_uk/main.go | 2 +- tests/integration_tests/move_table/main.go | 6 +- tests/integration_tests/multi_source/main.go | 2 +- .../owner_remove_table_error/run.sh | 2 +- .../processor_err_chan/run.sh | 2 +- .../integration_tests/processor_panic/main.go | 4 +- .../integration_tests/processor_panic/run.sh | 2 +- .../processor_resolved_ts_fallback/run.sh | 2 +- .../processor_stop_delay/run.sh | 2 +- tests/integration_tests/resolve_lock/main.go | 2 +- tests/integration_tests/sink_hang/run.sh | 2 +- tests/integration_tests/sink_retry/run.sh | 2 +- tools/check/check-errdoc.sh | 2 +- 335 files changed, 1055 insertions(+), 1055 deletions(-) diff --git a/Dockerfile b/Dockerfile index b3caae84699..b8812b9ce8f 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,12 +1,12 @@ FROM golang:1.14-alpine as builder RUN apk add --no-cache git make bash -WORKDIR /go/src/github.com/pingcap/ticdc +WORKDIR /go/src/github.com/pingcap/tiflow COPY . . ENV CDC_ENABLE_VENDOR=0 RUN make FROM alpine:3.12 RUN apk add --no-cache tzdata bash curl socat -COPY --from=builder /go/src/github.com/pingcap/ticdc/bin/cdc /cdc +COPY --from=builder /go/src/github.com/pingcap/tiflow/bin/cdc /cdc EXPOSE 8300 CMD [ "/cdc" ] diff --git a/Dockerfile.development b/Dockerfile.development index 56c1cb0859f..1d64d79dd9c 100644 --- a/Dockerfile.development +++ b/Dockerfile.development @@ -1,6 +1,6 @@ FROM golang:1.14-alpine as builder RUN apk add --no-cache git make bash -WORKDIR /go/src/github.com/pingcap/ticdc +WORKDIR /go/src/github.com/pingcap/tiflow COPY . . ENV CDC_ENABLE_VENDOR=1 RUN go mod vendor @@ -10,6 +10,6 @@ RUN make failpoint-disable FROM alpine:3.12 RUN apk add --no-cache tzdata bash curl socat -COPY --from=builder /go/src/github.com/pingcap/ticdc/bin/cdc /cdc +COPY --from=builder /go/src/github.com/pingcap/tiflow/bin/cdc /cdc EXPOSE 8300 CMD [ "/cdc" ] diff --git a/Makefile b/Makefile index 6bf92859f7f..a50a0a74f3b 100644 --- a/Makefile +++ b/Makefile @@ -2,7 +2,7 @@ .PHONY: build test check clean fmt cdc kafka_consumer coverage \ integration_test_build integration_test integration_test_mysql integration_test_kafka -PROJECT=ticdc +PROJECT=tiflow FAIL_ON_STDOUT := awk '{ print } END { if (NR > 0) { exit 1 } }' @@ -34,7 +34,7 @@ PACKAGES := $$($(PACKAGE_LIST)) PACKAGE_DIRECTORIES := $(PACKAGE_LIST) | sed 's|github.com/pingcap/$(PROJECT)/||' FILES := $$(find . -name '*.go' -type f | grep -vE 'vendor|kv_gen|proto') TEST_FILES := $$(find . -name '*_test.go' -type f | grep -vE 'vendor|kv_gen|integration|testing_utils') -CDC_PKG := github.com/pingcap/ticdc +CDC_PKG := github.com/pingcap/tiflow FAILPOINT_DIR := $$(for p in $(PACKAGES); do echo $${p\#"github.com/pingcap/$(PROJECT)/"}|grep -v "github.com/pingcap/$(PROJECT)"; done) FAILPOINT := bin/failpoint-ctl @@ -125,8 +125,8 @@ integration_test_build: check_failpoint_ctl ./scripts/fix_lib_zstd.sh $(FAILPOINT_ENABLE) $(GOTEST) -ldflags '$(LDFLAGS)' -c -cover -covermode=atomic \ - -coverpkg=github.com/pingcap/ticdc/... \ - -o bin/cdc.test github.com/pingcap/ticdc/cmd/cdc \ + -coverpkg=github.com/pingcap/tiflow/... \ + -o bin/cdc.test github.com/pingcap/tiflow/cmd/cdc \ || { $(FAILPOINT_DISABLE); exit 1; } $(GOBUILD) -ldflags '$(LDFLAGS)' -o bin/cdc ./cmd/cdc/main.go \ || { $(FAILPOINT_DISABLE); exit 1; } diff --git a/README.md b/README.md index 4c6aa983c92..39c697e1e2e 100644 --- a/README.md +++ b/README.md @@ -1,10 +1,10 @@ # TiCDC [![Build Status](https://internal.pingcap.net/idc-jenkins/job/build_cdc_master/badge/icon)](https://internal.pingcap.net/idc-jenkins/job/build_cdc_master/) -[![codecov](https://codecov.io/gh/pingcap/ticdc/branch/master/graph/badge.svg)](https://codecov.io/gh/pingcap/ticdc) -[![Coverage Status](https://coveralls.io/repos/github/pingcap/ticdc/badge.svg)](https://coveralls.io/github/pingcap/ticdc) -[![LICENSE](https://img.shields.io/github/license/pingcap/ticdc.svg)](https://github.com/pingcap/ticdc/blob/master/LICENSE) -[![Go Report Card](https://goreportcard.com/badge/github.com/pingcap/ticdc)](https://goreportcard.com/report/github.com/pingcap/ticdc) +[![codecov](https://codecov.io/gh/pingcap/tiflow/branch/master/graph/badge.svg)](https://codecov.io/gh/pingcap/tiflow) +[![Coverage Status](https://coveralls.io/repos/github/pingcap/tiflow/badge.svg)](https://coveralls.io/github/pingcap/tiflow) +[![LICENSE](https://img.shields.io/github/license/pingcap/tiflow.svg)](https://github.com/pingcap/tiflow/blob/master/LICENSE) +[![Go Report Card](https://goreportcard.com/badge/github.com/pingcap/tiflow)](https://goreportcard.com/report/github.com/pingcap/tiflow) **TiCDC** is [TiDB](https://docs.pingcap.com/tidb/stable)'s change data capture framework. It supports replicating change data to various downstreams, including MySQL protocol-compatible databases, message queues via the open CDC protocol and other systems such as local file storage. diff --git a/cdc/async_sink.go b/cdc/async_sink.go index 7f43b289ffd..868abcd678e 100644 --- a/cdc/async_sink.go +++ b/cdc/async_sink.go @@ -24,11 +24,11 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/sink" - cdcContext "github.com/pingcap/ticdc/pkg/context" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/filter" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/sink" + cdcContext "github.com/pingcap/tiflow/pkg/context" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/filter" "go.uber.org/zap" ) diff --git a/cdc/async_sink_test.go b/cdc/async_sink_test.go index 630e4c58876..fe6dc9ffd27 100644 --- a/cdc/async_sink_test.go +++ b/cdc/async_sink_test.go @@ -21,13 +21,13 @@ import ( "github.com/pingcap/check" "github.com/pingcap/errors" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/sink" - "github.com/pingcap/ticdc/pkg/config" - cdcContext "github.com/pingcap/ticdc/pkg/context" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/retry" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/sink" + "github.com/pingcap/tiflow/pkg/config" + cdcContext "github.com/pingcap/tiflow/pkg/context" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/retry" + "github.com/pingcap/tiflow/pkg/util/testleak" ) var _ = check.Suite(&asyncSinkSuite{}) diff --git a/cdc/capture.go b/cdc/capture.go index eaf419b3b55..db16d3abe4d 100644 --- a/cdc/capture.go +++ b/cdc/capture.go @@ -22,16 +22,16 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/processor" - "github.com/pingcap/ticdc/pkg/config" - cdcContext "github.com/pingcap/ticdc/pkg/context" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/orchestrator" - "github.com/pingcap/ticdc/pkg/util" - "github.com/pingcap/ticdc/pkg/version" tidbkv "github.com/pingcap/tidb/kv" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/processor" + "github.com/pingcap/tiflow/pkg/config" + cdcContext "github.com/pingcap/tiflow/pkg/context" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/orchestrator" + "github.com/pingcap/tiflow/pkg/util" + "github.com/pingcap/tiflow/pkg/version" pd "github.com/tikv/pd/client" "go.etcd.io/etcd/clientv3" "go.etcd.io/etcd/clientv3/concurrency" diff --git a/cdc/capture/capture.go b/cdc/capture/capture.go index fb4dc8618d5..0f928e56f86 100644 --- a/cdc/capture/capture.go +++ b/cdc/capture/capture.go @@ -24,17 +24,17 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/owner" - "github.com/pingcap/ticdc/cdc/processor" - "github.com/pingcap/ticdc/pkg/config" - cdcContext "github.com/pingcap/ticdc/pkg/context" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/orchestrator" - "github.com/pingcap/ticdc/pkg/pdtime" - "github.com/pingcap/ticdc/pkg/version" tidbkv "github.com/pingcap/tidb/kv" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/owner" + "github.com/pingcap/tiflow/cdc/processor" + "github.com/pingcap/tiflow/pkg/config" + cdcContext "github.com/pingcap/tiflow/pkg/context" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/orchestrator" + "github.com/pingcap/tiflow/pkg/pdtime" + "github.com/pingcap/tiflow/pkg/version" pd "github.com/tikv/pd/client" "go.etcd.io/etcd/clientv3/concurrency" "go.etcd.io/etcd/mvcc" diff --git a/cdc/capture_test.go b/cdc/capture_test.go index deb94dacbd1..8f353dde519 100644 --- a/cdc/capture_test.go +++ b/cdc/capture_test.go @@ -22,13 +22,13 @@ import ( "github.com/pingcap/check" "github.com/pingcap/errors" "github.com/pingcap/failpoint" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/etcd" - "github.com/pingcap/ticdc/pkg/util" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/etcd" + "github.com/pingcap/tiflow/pkg/util" + "github.com/pingcap/tiflow/pkg/util/testleak" pd "github.com/tikv/pd/client" "go.etcd.io/etcd/clientv3" "go.etcd.io/etcd/clientv3/concurrency" @@ -113,10 +113,10 @@ func (s *captureSuite) TestCaptureSessionDoneDuringHandleTask(c *check.C) { c.Assert(err, check.IsNil) runProcessorCount := 0 - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/captureHandleTaskDelay", "sleep(500)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/captureHandleTaskDelay", "sleep(500)") c.Assert(err, check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/captureHandleTaskDelay") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/captureHandleTaskDelay") }() runProcessorBackup := runProcessorImpl runProcessorImpl = func( diff --git a/cdc/changefeed.go b/cdc/changefeed.go index c8fa26da060..7c768bf59ba 100644 --- a/cdc/changefeed.go +++ b/cdc/changefeed.go @@ -24,16 +24,16 @@ import ( "github.com/pingcap/failpoint" "github.com/pingcap/log" timodel "github.com/pingcap/parser/model" - "github.com/pingcap/ticdc/cdc/entry" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/sink" - cdcContext "github.com/pingcap/ticdc/pkg/context" - "github.com/pingcap/ticdc/pkg/cyclic/mark" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/filter" - "github.com/pingcap/ticdc/pkg/scheduler" "github.com/pingcap/tidb/sessionctx/binloginfo" + "github.com/pingcap/tiflow/cdc/entry" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/sink" + cdcContext "github.com/pingcap/tiflow/pkg/context" + "github.com/pingcap/tiflow/pkg/cyclic/mark" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/filter" + "github.com/pingcap/tiflow/pkg/scheduler" "go.etcd.io/etcd/clientv3" "go.etcd.io/etcd/mvcc/mvccpb" "go.uber.org/zap" diff --git a/cdc/changefeed_test.go b/cdc/changefeed_test.go index 24b801fbc95..4233eea8cb8 100644 --- a/cdc/changefeed_test.go +++ b/cdc/changefeed_test.go @@ -20,11 +20,11 @@ import ( "github.com/pingcap/check" timodel "github.com/pingcap/parser/model" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/etcd" - "github.com/pingcap/ticdc/pkg/util" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/etcd" + "github.com/pingcap/tiflow/pkg/util" + "github.com/pingcap/tiflow/pkg/util/testleak" "go.etcd.io/etcd/clientv3" "go.etcd.io/etcd/clientv3/concurrency" "go.etcd.io/etcd/embed" diff --git a/cdc/entry/codec.go b/cdc/entry/codec.go index 828ce501df3..fbcb0228072 100644 --- a/cdc/entry/codec.go +++ b/cdc/entry/codec.go @@ -18,11 +18,11 @@ import ( "time" "github.com/pingcap/parser/mysql" - "github.com/pingcap/ticdc/cdc/model" - cerror "github.com/pingcap/ticdc/pkg/errors" "github.com/pingcap/tidb/types" "github.com/pingcap/tidb/util/codec" "github.com/pingcap/tidb/util/rowcodec" + "github.com/pingcap/tiflow/cdc/model" + cerror "github.com/pingcap/tiflow/pkg/errors" ) var ( diff --git a/cdc/entry/codec_test.go b/cdc/entry/codec_test.go index 184efc68654..0ddb0be1435 100644 --- a/cdc/entry/codec_test.go +++ b/cdc/entry/codec_test.go @@ -17,9 +17,9 @@ import ( "testing" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" "github.com/pingcap/tidb/tablecodec" "github.com/pingcap/tidb/util/codec" + "github.com/pingcap/tiflow/pkg/util/testleak" ) func Test(t *testing.T) { check.TestingT(t) } diff --git a/cdc/entry/mounter.go b/cdc/entry/mounter.go index eb14be764b1..40db086c8fb 100644 --- a/cdc/entry/mounter.go +++ b/cdc/entry/mounter.go @@ -26,11 +26,11 @@ import ( "github.com/pingcap/log" timodel "github.com/pingcap/parser/model" "github.com/pingcap/parser/mysql" - "github.com/pingcap/ticdc/cdc/model" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/util" "github.com/pingcap/tidb/table" "github.com/pingcap/tidb/types" + "github.com/pingcap/tiflow/cdc/model" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/util" "go.uber.org/zap" "golang.org/x/sync/errgroup" ) diff --git a/cdc/entry/mounter_test.go b/cdc/entry/mounter_test.go index 374cfbcd1e4..3dff352c472 100644 --- a/cdc/entry/mounter_test.go +++ b/cdc/entry/mounter_test.go @@ -20,14 +20,14 @@ import ( "github.com/pingcap/check" "github.com/pingcap/parser/mysql" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/regionspan" - "github.com/pingcap/ticdc/pkg/util/testleak" ticonfig "github.com/pingcap/tidb/config" tidbkv "github.com/pingcap/tidb/kv" "github.com/pingcap/tidb/session" "github.com/pingcap/tidb/store/mockstore" "github.com/pingcap/tidb/util/testkit" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/regionspan" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type mountTxnsSuite struct{} diff --git a/cdc/entry/schema_storage.go b/cdc/entry/schema_storage.go index 28a49d60a03..5e043b0d324 100644 --- a/cdc/entry/schema_storage.go +++ b/cdc/entry/schema_storage.go @@ -23,11 +23,11 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" timodel "github.com/pingcap/parser/model" - "github.com/pingcap/ticdc/cdc/model" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/filter" - "github.com/pingcap/ticdc/pkg/retry" timeta "github.com/pingcap/tidb/meta" + "github.com/pingcap/tiflow/cdc/model" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/filter" + "github.com/pingcap/tiflow/pkg/retry" "go.uber.org/zap" "go.uber.org/zap/zapcore" ) diff --git a/cdc/entry/schema_storage_test.go b/cdc/entry/schema_storage_test.go index 608f6fef096..17d8b34bd60 100644 --- a/cdc/entry/schema_storage_test.go +++ b/cdc/entry/schema_storage_test.go @@ -23,9 +23,6 @@ import ( "github.com/pingcap/errors" timodel "github.com/pingcap/parser/model" "github.com/pingcap/parser/mysql" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/util/testleak" ticonfig "github.com/pingcap/tidb/config" "github.com/pingcap/tidb/domain" tidbkv "github.com/pingcap/tidb/kv" @@ -35,6 +32,9 @@ import ( "github.com/pingcap/tidb/store/mockstore" "github.com/pingcap/tidb/types" "github.com/pingcap/tidb/util/testkit" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type schemaSuite struct{} diff --git a/cdc/http_api_handler.go b/cdc/http_api_handler.go index 6dcf4de6807..2bbd90bdc76 100644 --- a/cdc/http_api_handler.go +++ b/cdc/http_api_handler.go @@ -21,10 +21,10 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/httputil" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/cdc/model" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/httputil" "go.uber.org/zap" ) diff --git a/cdc/http_handler.go b/cdc/http_handler.go index ae623be564e..bb1d5825f09 100644 --- a/cdc/http_handler.go +++ b/cdc/http_handler.go @@ -23,12 +23,12 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/owner" - "github.com/pingcap/ticdc/pkg/config" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/logutil" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/owner" + "github.com/pingcap/tiflow/pkg/config" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/logutil" "go.etcd.io/etcd/clientv3/concurrency" "go.uber.org/zap" ) diff --git a/cdc/http_status.go b/cdc/http_status.go index 628b8616cab..14265b14212 100644 --- a/cdc/http_status.go +++ b/cdc/http_status.go @@ -23,15 +23,15 @@ import ( "net/http/pprof" "os" - "github.com/pingcap/ticdc/pkg/util" + "github.com/pingcap/tiflow/pkg/util" "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/pkg/config" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/version" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/pkg/config" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/version" "github.com/prometheus/client_golang/prometheus" "github.com/prometheus/client_golang/prometheus/promhttp" "go.etcd.io/etcd/clientv3" diff --git a/cdc/http_status_test.go b/cdc/http_status_test.go index 144feb08b89..6dfcfc0d3eb 100644 --- a/cdc/http_status_test.go +++ b/cdc/http_status_test.go @@ -23,9 +23,9 @@ import ( "github.com/pingcap/check" "github.com/pingcap/failpoint" - "github.com/pingcap/ticdc/pkg/config" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/config" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/util/testleak" "go.etcd.io/etcd/clientv3/concurrency" ) @@ -137,7 +137,7 @@ func testRequestNonOwnerFailed(c *check.C, uri string) { } func testHandleFailpoint(c *check.C) { - fp := "github.com/pingcap/ticdc/cdc/TestHandleFailpoint" + fp := "github.com/pingcap/tiflow/cdc/TestHandleFailpoint" uri := fmt.Sprintf("http://%s/debug/fail/%s", advertiseAddr4Test, fp) body := bytes.NewReader([]byte("return(true)")) req, err := http.NewRequest("PUT", uri, body) diff --git a/cdc/kv/client.go b/cdc/kv/client.go index cd71ab732c5..56152f0a77d 100644 --- a/cdc/kv/client.go +++ b/cdc/kv/client.go @@ -29,16 +29,16 @@ import ( "github.com/pingcap/kvproto/pkg/kvrpcpb" "github.com/pingcap/kvproto/pkg/metapb" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/regionspan" - "github.com/pingcap/ticdc/pkg/retry" - "github.com/pingcap/ticdc/pkg/txnutil" - "github.com/pingcap/ticdc/pkg/util" - "github.com/pingcap/ticdc/pkg/version" tidbkv "github.com/pingcap/tidb/kv" "github.com/pingcap/tidb/store/tikv" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/regionspan" + "github.com/pingcap/tiflow/pkg/retry" + "github.com/pingcap/tiflow/pkg/txnutil" + "github.com/pingcap/tiflow/pkg/util" + "github.com/pingcap/tiflow/pkg/version" "github.com/prometheus/client_golang/prometheus" pd "github.com/tikv/pd/client" "go.uber.org/zap" diff --git a/cdc/kv/client_bench_test.go b/cdc/kv/client_bench_test.go index ba4f6bc0230..b418ea973b1 100644 --- a/cdc/kv/client_bench_test.go +++ b/cdc/kv/client_bench_test.go @@ -24,12 +24,12 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/kvproto/pkg/cdcpb" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/regionspan" - "github.com/pingcap/ticdc/pkg/retry" "github.com/pingcap/tidb/store/mockstore/mocktikv" "github.com/pingcap/tidb/store/tikv" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/regionspan" + "github.com/pingcap/tiflow/pkg/retry" "go.uber.org/zap/zapcore" "google.golang.org/grpc" ) diff --git a/cdc/kv/client_mock_test.go b/cdc/kv/client_mock_test.go index d98961c2de7..e077006b746 100644 --- a/cdc/kv/client_mock_test.go +++ b/cdc/kv/client_mock_test.go @@ -21,7 +21,7 @@ import ( "github.com/pingcap/kvproto/pkg/cdcpb" "github.com/pingcap/kvproto/pkg/metapb" - "github.com/pingcap/ticdc/pkg/version" + "github.com/pingcap/tiflow/pkg/version" pd "github.com/tikv/pd/client" ) diff --git a/cdc/kv/client_test.go b/cdc/kv/client_test.go index 11854493921..7eab04dd28e 100644 --- a/cdc/kv/client_test.go +++ b/cdc/kv/client_test.go @@ -30,19 +30,19 @@ import ( "github.com/pingcap/kvproto/pkg/errorpb" "github.com/pingcap/kvproto/pkg/metapb" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/regionspan" - "github.com/pingcap/ticdc/pkg/retry" - "github.com/pingcap/ticdc/pkg/security" - "github.com/pingcap/ticdc/pkg/txnutil" - "github.com/pingcap/ticdc/pkg/util" - "github.com/pingcap/ticdc/pkg/util/testleak" tidbkv "github.com/pingcap/tidb/kv" "github.com/pingcap/tidb/store/mockstore/mocktikv" "github.com/pingcap/tidb/store/tikv" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/regionspan" + "github.com/pingcap/tiflow/pkg/retry" + "github.com/pingcap/tiflow/pkg/security" + "github.com/pingcap/tiflow/pkg/txnutil" + "github.com/pingcap/tiflow/pkg/util" + "github.com/pingcap/tiflow/pkg/util/testleak" pd "github.com/tikv/pd/client" "go.uber.org/zap" "google.golang.org/grpc" @@ -1302,10 +1302,10 @@ func (s *etcdSuite) testStreamRecvWithError(c *check.C, failpointStr string) { cluster.AddStore(1, addr1) cluster.Bootstrap(regionID, []uint64{1}, []uint64{4}, 4) - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/kv/kvClientStreamRecvError", failpointStr) + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/kv/kvClientStreamRecvError", failpointStr) c.Assert(err, check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/kv/kvClientStreamRecvError") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/kv/kvClientStreamRecvError") }() baseAllocatedID := currentRequestID() lockresolver, isPullInit, grpcPool, cdcClient := createCDCKVClient(ctx, pdClient, kvStorage) @@ -1486,10 +1486,10 @@ func (s *etcdSuite) TestStreamRecvWithErrorAndResolvedGoBack(c *check.C) { }, retry.WithBackoffBaseDelay(200), retry.WithBackoffMaxDelay(60*1000), retry.WithMaxTries(10)) c.Assert(err, check.IsNil) - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/kv/kvClientStreamRecvError", "1*return(\"\")") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/kv/kvClientStreamRecvError", "1*return(\"\")") c.Assert(err, check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/kv/kvClientStreamRecvError") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/kv/kvClientStreamRecvError") }() ch1 <- resolved @@ -1640,10 +1640,10 @@ func (s *etcdSuite) TestIncompatibleTiKV(c *check.C) { cluster.AddStore(1, addr1) cluster.Bootstrap(regionID, []uint64{1}, []uint64{4}, 4) - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/kv/kvClientDelayWhenIncompatible", "return(true)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/kv/kvClientDelayWhenIncompatible", "return(true)") c.Assert(err, check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/kv/kvClientDelayWhenIncompatible") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/kv/kvClientDelayWhenIncompatible") }() lockresolver, isPullInit, grpcPool, cdcClient := createCDCKVClient(ctx, pdClient, kvStorage) defer grpcPool.Close() @@ -1897,10 +1897,10 @@ func (s *etcdSuite) TestResolveLock(c *check.C) { cluster.AddStore(1, addr1) cluster.Bootstrap(regionID, []uint64{1}, []uint64{4}, 4) - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/kv/kvClientResolveLockInterval", "return(3)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/kv/kvClientResolveLockInterval", "return(3)") c.Assert(err, check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/kv/kvClientResolveLockInterval") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/kv/kvClientResolveLockInterval") }() baseAllocatedID := currentRequestID() lockresolver, isPullInit, grpcPool, cdcClient := createCDCKVClient(ctx, pdClient, kvStorage) @@ -1995,10 +1995,10 @@ func (s *etcdSuite) testEventCommitTsFallback(c *check.C, events []*cdcpb.Change logPanic = log.Panic }() - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/kv/kvClientErrUnreachable", "return(true)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/kv/kvClientErrUnreachable", "return(true)") c.Assert(err, check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/kv/kvClientErrUnreachable") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/kv/kvClientErrUnreachable") }() baseAllocatedID := currentRequestID() lockresolver, isPullInit, grpcPool, cdcClient := createCDCKVClient(ctx, pdClient, kvStorage) @@ -2142,10 +2142,10 @@ func (s *etcdSuite) testEventAfterFeedStop(c *check.C) { // add 2s delay to simulate event feed processor has been marked stopped, but // before event feed processor is reconstruct, some duplicated events are // sent to event feed processor. - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/kv/kvClientSingleFeedProcessDelay", "1*sleep(2000)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/kv/kvClientSingleFeedProcessDelay", "1*sleep(2000)") c.Assert(err, check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/kv/kvClientSingleFeedProcessDelay") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/kv/kvClientSingleFeedProcessDelay") }() baseAllocatedID := currentRequestID() lockresolver, isPullInit, grpcPool, cdcClient := createCDCKVClient(ctx, pdClient, kvStorage) @@ -2638,13 +2638,13 @@ func (s *etcdSuite) TestFailRegionReentrant(c *check.C) { cluster.AddStore(1, addr1) cluster.Bootstrap(regionID, []uint64{1}, []uint64{4}, 4) - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/kv/kvClientRegionReentrantError", "1*return(\"ok\")->1*return(\"error\")") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/kv/kvClientRegionReentrantError", "1*return(\"ok\")->1*return(\"error\")") c.Assert(err, check.IsNil) - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/kv/kvClientRegionReentrantErrorDelay", "sleep(500)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/kv/kvClientRegionReentrantErrorDelay", "sleep(500)") c.Assert(err, check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/kv/kvClientRegionReentrantError") - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/kv/kvClientRegionReentrantErrorDelay") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/kv/kvClientRegionReentrantError") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/kv/kvClientRegionReentrantErrorDelay") }() baseAllocatedID := currentRequestID() lockresolver, isPullInit, grpcPool, cdcClient := createCDCKVClient(ctx, pdClient, kvStorage) @@ -2719,13 +2719,13 @@ func (s *etcdSuite) TestClientV1UnlockRangeReentrant(c *check.C) { cluster.Bootstrap(regionID3, []uint64{1}, []uint64{4}, 4) cluster.SplitRaw(regionID3, regionID4, []byte("b"), []uint64{5}, 5) - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/kv/kvClientStreamRecvError", "1*return(\"injected stream recv error\")") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/kv/kvClientStreamRecvError", "1*return(\"injected stream recv error\")") c.Assert(err, check.IsNil) - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/kv/kvClientPendingRegionDelay", "1*sleep(0)->1*sleep(2000)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/kv/kvClientPendingRegionDelay", "1*sleep(0)->1*sleep(2000)") c.Assert(err, check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/kv/kvClientStreamRecvError") - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/kv/kvClientPendingRegionDelay") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/kv/kvClientStreamRecvError") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/kv/kvClientPendingRegionDelay") }() lockresolver, isPullInit, grpcPool, cdcClient := createCDCKVClient(ctx, pdClient, kvStorage) defer grpcPool.Close() @@ -2781,16 +2781,16 @@ func (s *etcdSuite) testClientErrNoPendingRegion(c *check.C) { cluster.Bootstrap(regionID3, []uint64{1}, []uint64{4}, 4) cluster.SplitRaw(regionID3, regionID4, []byte("b"), []uint64{5}, 5) - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/kv/kvClientStreamRecvError", "1*return(\"injected stream recv error\")") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/kv/kvClientStreamRecvError", "1*return(\"injected stream recv error\")") c.Assert(err, check.IsNil) - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/kv/kvClientPendingRegionDelay", "1*sleep(0)->2*sleep(1000)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/kv/kvClientPendingRegionDelay", "1*sleep(0)->2*sleep(1000)") c.Assert(err, check.IsNil) - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/kv/kvClientStreamCloseDelay", "sleep(2000)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/kv/kvClientStreamCloseDelay", "sleep(2000)") c.Assert(err, check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/kv/kvClientStreamRecvError") - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/kv/kvClientPendingRegionDelay") - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/kv/kvClientStreamCloseDelay") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/kv/kvClientStreamRecvError") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/kv/kvClientPendingRegionDelay") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/kv/kvClientStreamCloseDelay") }() lockresolver, isPullInit, grpcPool, cdcClient := createCDCKVClient(ctx, pdClient, kvStorage) defer grpcPool.Close() @@ -2858,12 +2858,12 @@ func (s *etcdSuite) testKVClientForceReconnect(c *check.C) { cluster.AddStore(1, addr1) cluster.Bootstrap(regionID3, []uint64{1}, []uint64{4}, 4) - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/kv/kvClientResolveLockInterval", "return(1)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/kv/kvClientResolveLockInterval", "return(1)") c.Assert(err, check.IsNil) originalReconnectInterval := reconnectInterval reconnectInterval = 3 * time.Second defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/kv/kvClientResolveLockInterval") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/kv/kvClientResolveLockInterval") reconnectInterval = originalReconnectInterval }() lockresolver, isPullInit, grpcPool, cdcClient := createCDCKVClient(ctx, pdClient, kvStorage) @@ -3009,10 +3009,10 @@ func (s *etcdSuite) TestConcurrentProcessRangeRequest(c *check.C) { cluster.AddStore(storeID, addr1) cluster.Bootstrap(regionID, []uint64{storeID}, []uint64{peerID}, peerID) - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/kv/kvClientMockRangeLock", "1*return(20)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/kv/kvClientMockRangeLock", "1*return(20)") c.Assert(err, check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/kv/kvClientMockRangeLock") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/kv/kvClientMockRangeLock") }() lockresolver, isPullInit, grpcPool, cdcClient := createCDCKVClient(ctx, pdClient, kvStorage) defer grpcPool.Close() @@ -3125,10 +3125,10 @@ func (s *etcdSuite) TestEvTimeUpdate(c *check.C) { originalReconnectInterval := reconnectInterval reconnectInterval = 1500 * time.Millisecond - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/kv/kvClientCheckUnInitRegionInterval", "return(2)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/kv/kvClientCheckUnInitRegionInterval", "return(2)") c.Assert(err, check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/kv/kvClientCheckUnInitRegionInterval") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/kv/kvClientCheckUnInitRegionInterval") reconnectInterval = originalReconnectInterval }() diff --git a/cdc/kv/etcd.go b/cdc/kv/etcd.go index bda6a10ca76..86dd0843680 100644 --- a/cdc/kv/etcd.go +++ b/cdc/kv/etcd.go @@ -22,11 +22,11 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/etcd" - "github.com/pingcap/ticdc/pkg/retry" - "github.com/pingcap/ticdc/pkg/util" + "github.com/pingcap/tiflow/cdc/model" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/etcd" + "github.com/pingcap/tiflow/pkg/retry" + "github.com/pingcap/tiflow/pkg/util" "github.com/prometheus/client_golang/prometheus" "go.etcd.io/etcd/clientv3" "go.etcd.io/etcd/clientv3/concurrency" diff --git a/cdc/kv/etcd_test.go b/cdc/kv/etcd_test.go index e577c044a12..96ab729f196 100644 --- a/cdc/kv/etcd_test.go +++ b/cdc/kv/etcd_test.go @@ -21,11 +21,11 @@ import ( "time" "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/model" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/etcd" - "github.com/pingcap/ticdc/pkg/util" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/etcd" + "github.com/pingcap/tiflow/pkg/util" + "github.com/pingcap/tiflow/pkg/util/testleak" "go.etcd.io/etcd/clientv3" "go.etcd.io/etcd/clientv3/concurrency" "go.etcd.io/etcd/embed" diff --git a/cdc/kv/grpc_pool_impl.go b/cdc/kv/grpc_pool_impl.go index c232254b8a8..7ed90c4d07b 100644 --- a/cdc/kv/grpc_pool_impl.go +++ b/cdc/kv/grpc_pool_impl.go @@ -19,8 +19,8 @@ import ( "time" "github.com/pingcap/log" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/security" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/security" "go.uber.org/zap" "google.golang.org/grpc" gbackoff "google.golang.org/grpc/backoff" diff --git a/cdc/kv/grpc_pool_impl_test.go b/cdc/kv/grpc_pool_impl_test.go index 08d676e6712..67767a58808 100644 --- a/cdc/kv/grpc_pool_impl_test.go +++ b/cdc/kv/grpc_pool_impl_test.go @@ -17,8 +17,8 @@ import ( "context" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/security" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/security" + "github.com/pingcap/tiflow/pkg/util/testleak" ) // Use etcdSuite for some special reasons, the embed etcd uses zap as the only candidate diff --git a/cdc/kv/matcher_test.go b/cdc/kv/matcher_test.go index b911a74e77f..fd9f745e7aa 100644 --- a/cdc/kv/matcher_test.go +++ b/cdc/kv/matcher_test.go @@ -16,7 +16,7 @@ package kv import ( "github.com/pingcap/check" "github.com/pingcap/kvproto/pkg/cdcpb" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type matcherSuite struct{} diff --git a/cdc/kv/region_worker.go b/cdc/kv/region_worker.go index ecf368e8cd2..75cf0f7ec09 100644 --- a/cdc/kv/region_worker.go +++ b/cdc/kv/region_worker.go @@ -25,13 +25,13 @@ import ( "github.com/pingcap/failpoint" "github.com/pingcap/kvproto/pkg/cdcpb" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/regionspan" - "github.com/pingcap/ticdc/pkg/util" - "github.com/pingcap/ticdc/pkg/workerpool" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/regionspan" + "github.com/pingcap/tiflow/pkg/util" + "github.com/pingcap/tiflow/pkg/workerpool" "github.com/prometheus/client_golang/prometheus" "go.uber.org/zap" "golang.org/x/sync/errgroup" diff --git a/cdc/kv/region_worker_test.go b/cdc/kv/region_worker_test.go index 68b983d5668..13eac0d4ca7 100644 --- a/cdc/kv/region_worker_test.go +++ b/cdc/kv/region_worker_test.go @@ -19,8 +19,8 @@ import ( "sync" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type regionWorkerSuite struct{} diff --git a/cdc/kv/resolvedts_heap_test.go b/cdc/kv/resolvedts_heap_test.go index 2a79e609c94..4fe92e9b5f1 100644 --- a/cdc/kv/resolvedts_heap_test.go +++ b/cdc/kv/resolvedts_heap_test.go @@ -17,7 +17,7 @@ import ( "time" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type rtsHeapSuite struct{} diff --git a/cdc/kv/store_op.go b/cdc/kv/store_op.go index 1b36535a6d8..b95af531f90 100644 --- a/cdc/kv/store_op.go +++ b/cdc/kv/store_op.go @@ -20,15 +20,15 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/flags" - "github.com/pingcap/ticdc/pkg/security" tidbconfig "github.com/pingcap/tidb/config" tidbkv "github.com/pingcap/tidb/kv" "github.com/pingcap/tidb/meta" "github.com/pingcap/tidb/store" "github.com/pingcap/tidb/store/tikv" + "github.com/pingcap/tiflow/cdc/model" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/flags" + "github.com/pingcap/tiflow/pkg/security" "go.uber.org/zap" ) diff --git a/cdc/kv/testing.go b/cdc/kv/testing.go index 593290d5f5a..c1b25a2f21b 100644 --- a/cdc/kv/testing.go +++ b/cdc/kv/testing.go @@ -23,13 +23,13 @@ import ( "github.com/pingcap/kvproto/pkg/metapb" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/regionspan" - "github.com/pingcap/ticdc/pkg/security" - "github.com/pingcap/ticdc/pkg/txnutil" "github.com/pingcap/tidb/kv" "github.com/pingcap/tidb/store" "github.com/pingcap/tidb/store/tikv" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/regionspan" + "github.com/pingcap/tiflow/pkg/security" + "github.com/pingcap/tiflow/pkg/txnutil" "github.com/stretchr/testify/require" pd "github.com/tikv/pd/client" "go.uber.org/zap" diff --git a/cdc/kv/token_region.go b/cdc/kv/token_region.go index 4275b11bf81..61b3c9d10e1 100644 --- a/cdc/kv/token_region.go +++ b/cdc/kv/token_region.go @@ -19,7 +19,7 @@ import ( "time" "github.com/pingcap/errors" - "github.com/pingcap/ticdc/pkg/util" + "github.com/pingcap/tiflow/pkg/util" "github.com/prometheus/client_golang/prometheus" ) diff --git a/cdc/kv/token_region_test.go b/cdc/kv/token_region_test.go index cbbc76e2fce..5031283ea4a 100644 --- a/cdc/kv/token_region_test.go +++ b/cdc/kv/token_region_test.go @@ -21,8 +21,8 @@ import ( "github.com/pingcap/check" "github.com/pingcap/errors" - "github.com/pingcap/ticdc/pkg/util/testleak" "github.com/pingcap/tidb/store/tikv" + "github.com/pingcap/tiflow/pkg/util/testleak" "golang.org/x/sync/errgroup" ) diff --git a/cdc/metrics.go b/cdc/metrics.go index ec83b5eab35..c67da9df66f 100644 --- a/cdc/metrics.go +++ b/cdc/metrics.go @@ -14,16 +14,16 @@ package cdc import ( - "github.com/pingcap/ticdc/cdc/entry" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/cdc/owner" - "github.com/pingcap/ticdc/cdc/processor" - tablepipeline "github.com/pingcap/ticdc/cdc/processor/pipeline" - "github.com/pingcap/ticdc/cdc/puller" - "github.com/pingcap/ticdc/cdc/puller/sorter" - "github.com/pingcap/ticdc/cdc/sink" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/orchestrator" + "github.com/pingcap/tiflow/cdc/entry" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/cdc/owner" + "github.com/pingcap/tiflow/cdc/processor" + tablepipeline "github.com/pingcap/tiflow/cdc/processor/pipeline" + "github.com/pingcap/tiflow/cdc/puller" + "github.com/pingcap/tiflow/cdc/puller/sorter" + "github.com/pingcap/tiflow/cdc/sink" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/orchestrator" "github.com/prometheus/client_golang/prometheus" ) diff --git a/cdc/model/capture.go b/cdc/model/capture.go index f6594786211..aa2aa76331b 100644 --- a/cdc/model/capture.go +++ b/cdc/model/capture.go @@ -17,7 +17,7 @@ import ( "encoding/json" "github.com/pingcap/errors" - cerror "github.com/pingcap/ticdc/pkg/errors" + cerror "github.com/pingcap/tiflow/pkg/errors" ) // CaptureInfo store in etcd. diff --git a/cdc/model/capture_test.go b/cdc/model/capture_test.go index 688f0bf7726..f5358c301bb 100644 --- a/cdc/model/capture_test.go +++ b/cdc/model/capture_test.go @@ -15,7 +15,7 @@ package model import ( "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type captureSuite struct{} diff --git a/cdc/model/changefeed.go b/cdc/model/changefeed.go index 76a5eef2e19..ebc129382f2 100644 --- a/cdc/model/changefeed.go +++ b/cdc/model/changefeed.go @@ -22,10 +22,10 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/cyclic/mark" - cerror "github.com/pingcap/ticdc/pkg/errors" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/cyclic/mark" + cerror "github.com/pingcap/tiflow/pkg/errors" "go.uber.org/zap" ) diff --git a/cdc/model/changefeed_test.go b/cdc/model/changefeed_test.go index ce5ce4c05a2..6bd1a8f999c 100644 --- a/cdc/model/changefeed_test.go +++ b/cdc/model/changefeed_test.go @@ -19,11 +19,11 @@ import ( "github.com/pingcap/check" "github.com/pingcap/parser/model" - "github.com/pingcap/ticdc/pkg/config" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/util/testleak" filter "github.com/pingcap/tidb-tools/pkg/table-filter" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/pkg/config" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type configSuite struct{} diff --git a/cdc/model/kv.go b/cdc/model/kv.go index 1e249248970..4af1c9569b3 100644 --- a/cdc/model/kv.go +++ b/cdc/model/kv.go @@ -18,7 +18,7 @@ package model import ( "fmt" - "github.com/pingcap/ticdc/pkg/regionspan" + "github.com/pingcap/tiflow/pkg/regionspan" ) // OpType for the kv, delete or put diff --git a/cdc/model/kv_test.go b/cdc/model/kv_test.go index 643428fd538..63af3804af5 100644 --- a/cdc/model/kv_test.go +++ b/cdc/model/kv_test.go @@ -15,8 +15,8 @@ package model import ( "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/regionspan" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/regionspan" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type kvSuite struct{} diff --git a/cdc/model/mounter_test.go b/cdc/model/mounter_test.go index 61452d246f4..fbbd1db383f 100644 --- a/cdc/model/mounter_test.go +++ b/cdc/model/mounter_test.go @@ -18,7 +18,7 @@ import ( "sync" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type mounterSuite struct{} diff --git a/cdc/model/owner.go b/cdc/model/owner.go index 0a988d33ae1..61dd65d5fa2 100644 --- a/cdc/model/owner.go +++ b/cdc/model/owner.go @@ -20,7 +20,7 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - cerror "github.com/pingcap/ticdc/pkg/errors" + cerror "github.com/pingcap/tiflow/pkg/errors" "go.uber.org/zap" ) diff --git a/cdc/model/owner_test.go b/cdc/model/owner_test.go index ea811233cc1..d960963cdfe 100644 --- a/cdc/model/owner_test.go +++ b/cdc/model/owner_test.go @@ -18,7 +18,7 @@ import ( "testing" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) func TestSuite(t *testing.T) { check.TestingT(t) } diff --git a/cdc/model/reactor_state.go b/cdc/model/reactor_state.go index 195e552d98d..532a577941b 100644 --- a/cdc/model/reactor_state.go +++ b/cdc/model/reactor_state.go @@ -19,10 +19,10 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - cerrors "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/etcd" - "github.com/pingcap/ticdc/pkg/orchestrator" - "github.com/pingcap/ticdc/pkg/orchestrator/util" + cerrors "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/etcd" + "github.com/pingcap/tiflow/pkg/orchestrator" + "github.com/pingcap/tiflow/pkg/orchestrator/util" "go.uber.org/zap" ) diff --git a/cdc/model/reactor_state_test.go b/cdc/model/reactor_state_test.go index df76386c49a..a1ab46509e8 100644 --- a/cdc/model/reactor_state_test.go +++ b/cdc/model/reactor_state_test.go @@ -20,10 +20,10 @@ import ( "github.com/google/go-cmp/cmp" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/orchestrator" - "github.com/pingcap/ticdc/pkg/orchestrator/util" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/orchestrator" + "github.com/pingcap/tiflow/pkg/orchestrator/util" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type stateSuite struct{} diff --git a/cdc/model/schema_storage_test.go b/cdc/model/schema_storage_test.go index 6f0e4b3dfd8..a1f59ed007f 100644 --- a/cdc/model/schema_storage_test.go +++ b/cdc/model/schema_storage_test.go @@ -18,7 +18,7 @@ import ( timodel "github.com/pingcap/parser/model" "github.com/pingcap/parser/mysql" parser_types "github.com/pingcap/parser/types" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type schemaStorageSuite struct{} diff --git a/cdc/model/sink.go b/cdc/model/sink.go index 26519c37866..df0a20d3b63 100644 --- a/cdc/model/sink.go +++ b/cdc/model/sink.go @@ -20,8 +20,8 @@ import ( "github.com/pingcap/log" "github.com/pingcap/parser/model" - "github.com/pingcap/ticdc/pkg/quotes" - "github.com/pingcap/ticdc/pkg/util" + "github.com/pingcap/tiflow/pkg/quotes" + "github.com/pingcap/tiflow/pkg/util" "go.uber.org/zap" ) diff --git a/cdc/model/sink_test.go b/cdc/model/sink_test.go index 1e7294038c6..799b6c7e990 100644 --- a/cdc/model/sink_test.go +++ b/cdc/model/sink_test.go @@ -18,7 +18,7 @@ import ( timodel "github.com/pingcap/parser/model" "github.com/pingcap/parser/mysql" "github.com/pingcap/parser/types" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type columnFlagTypeSuite struct{} diff --git a/cdc/model/string.go b/cdc/model/string.go index eda57d46756..0b2ed1908ff 100644 --- a/cdc/model/string.go +++ b/cdc/model/string.go @@ -16,7 +16,7 @@ package model import ( "strings" - cerror "github.com/pingcap/ticdc/pkg/errors" + cerror "github.com/pingcap/tiflow/pkg/errors" ) // HolderString returns a string of place holders separated by comma diff --git a/cdc/model/string_test.go b/cdc/model/string_test.go index a6dcbb67beb..a9ad15e185c 100644 --- a/cdc/model/string_test.go +++ b/cdc/model/string_test.go @@ -15,7 +15,7 @@ package model import ( "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type stringSuite struct{} diff --git a/cdc/owner.go b/cdc/owner.go index 15441c69129..443fc0e803f 100644 --- a/cdc/owner.go +++ b/cdc/owner.go @@ -25,19 +25,19 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/entry" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/sink" - "github.com/pingcap/ticdc/pkg/config" - cdcContext "github.com/pingcap/ticdc/pkg/context" - "github.com/pingcap/ticdc/pkg/cyclic/mark" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/filter" - "github.com/pingcap/ticdc/pkg/notify" - "github.com/pingcap/ticdc/pkg/scheduler" - "github.com/pingcap/ticdc/pkg/util" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/cdc/entry" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/sink" + "github.com/pingcap/tiflow/pkg/config" + cdcContext "github.com/pingcap/tiflow/pkg/context" + "github.com/pingcap/tiflow/pkg/cyclic/mark" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/filter" + "github.com/pingcap/tiflow/pkg/notify" + "github.com/pingcap/tiflow/pkg/scheduler" + "github.com/pingcap/tiflow/pkg/util" pd "github.com/tikv/pd/client" "go.etcd.io/etcd/clientv3" "go.etcd.io/etcd/clientv3/concurrency" diff --git a/cdc/owner/async_sink.go b/cdc/owner/async_sink.go index e26b0f047ed..8abbc73df3c 100644 --- a/cdc/owner/async_sink.go +++ b/cdc/owner/async_sink.go @@ -22,11 +22,11 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/sink" - cdcContext "github.com/pingcap/ticdc/pkg/context" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/filter" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/sink" + cdcContext "github.com/pingcap/tiflow/pkg/context" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/filter" "go.uber.org/zap" ) diff --git a/cdc/owner/async_sink_test.go b/cdc/owner/async_sink_test.go index 3c7fc11a11e..981c1905e6b 100644 --- a/cdc/owner/async_sink_test.go +++ b/cdc/owner/async_sink_test.go @@ -21,13 +21,13 @@ import ( "github.com/pingcap/check" "github.com/pingcap/errors" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/sink" - "github.com/pingcap/ticdc/pkg/config" - cdcContext "github.com/pingcap/ticdc/pkg/context" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/retry" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/sink" + "github.com/pingcap/tiflow/pkg/config" + cdcContext "github.com/pingcap/tiflow/pkg/context" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/retry" + "github.com/pingcap/tiflow/pkg/util/testleak" ) var _ = check.Suite(&asyncSinkSuite{}) diff --git a/cdc/owner/barrier.go b/cdc/owner/barrier.go index 6eed7aba493..abe951090d8 100644 --- a/cdc/owner/barrier.go +++ b/cdc/owner/barrier.go @@ -17,7 +17,7 @@ import ( "math" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" + "github.com/pingcap/tiflow/cdc/model" ) type barrierType int diff --git a/cdc/owner/barrier_test.go b/cdc/owner/barrier_test.go index d8a6b851cf0..5b09cd030ba 100644 --- a/cdc/owner/barrier_test.go +++ b/cdc/owner/barrier_test.go @@ -19,8 +19,8 @@ import ( "testing" "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/util/testleak" ) func Test(t *testing.T) { check.TestingT(t) } diff --git a/cdc/owner/changefeed.go b/cdc/owner/changefeed.go index da62f303dbb..6f9071ed54c 100644 --- a/cdc/owner/changefeed.go +++ b/cdc/owner/changefeed.go @@ -17,18 +17,18 @@ import ( "context" "sync" - "github.com/pingcap/ticdc/pkg/txnutil/gc" + "github.com/pingcap/tiflow/pkg/txnutil/gc" "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" timodel "github.com/pingcap/parser/model" - "github.com/pingcap/ticdc/cdc/model" - cdcContext "github.com/pingcap/ticdc/pkg/context" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/util" "github.com/pingcap/tidb/sessionctx/binloginfo" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/cdc/model" + cdcContext "github.com/pingcap/tiflow/pkg/context" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/util" "github.com/prometheus/client_golang/prometheus" "go.uber.org/zap" ) diff --git a/cdc/owner/changefeed_test.go b/cdc/owner/changefeed_test.go index 681b943647a..4f4d09ca8e5 100644 --- a/cdc/owner/changefeed_test.go +++ b/cdc/owner/changefeed_test.go @@ -21,17 +21,17 @@ import ( "github.com/pingcap/check" "github.com/pingcap/errors" timodel "github.com/pingcap/parser/model" - "github.com/pingcap/ticdc/cdc/entry" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - cdcContext "github.com/pingcap/ticdc/pkg/context" - "github.com/pingcap/ticdc/pkg/orchestrator" - - "github.com/pingcap/ticdc/pkg/pdtime" - "github.com/pingcap/ticdc/pkg/txnutil/gc" - "github.com/pingcap/ticdc/pkg/util/testleak" - "github.com/pingcap/ticdc/pkg/version" + "github.com/pingcap/tiflow/cdc/entry" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + cdcContext "github.com/pingcap/tiflow/pkg/context" + "github.com/pingcap/tiflow/pkg/orchestrator" + "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/pkg/pdtime" + "github.com/pingcap/tiflow/pkg/txnutil/gc" + "github.com/pingcap/tiflow/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/version" ) type mockDDLPuller struct { diff --git a/cdc/owner/ddl_puller.go b/cdc/owner/ddl_puller.go index 49ff27e8243..d011c63a605 100644 --- a/cdc/owner/ddl_puller.go +++ b/cdc/owner/ddl_puller.go @@ -20,13 +20,13 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" timodel "github.com/pingcap/parser/model" - "github.com/pingcap/ticdc/cdc/entry" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/puller" - cdcContext "github.com/pingcap/ticdc/pkg/context" - "github.com/pingcap/ticdc/pkg/filter" - "github.com/pingcap/ticdc/pkg/regionspan" - "github.com/pingcap/ticdc/pkg/util" + "github.com/pingcap/tiflow/cdc/entry" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/puller" + cdcContext "github.com/pingcap/tiflow/pkg/context" + "github.com/pingcap/tiflow/pkg/filter" + "github.com/pingcap/tiflow/pkg/regionspan" + "github.com/pingcap/tiflow/pkg/util" "go.uber.org/zap" "golang.org/x/sync/errgroup" ) diff --git a/cdc/owner/ddl_puller_test.go b/cdc/owner/ddl_puller_test.go index ccd8000178b..4be256a4c79 100644 --- a/cdc/owner/ddl_puller_test.go +++ b/cdc/owner/ddl_puller_test.go @@ -22,11 +22,11 @@ import ( "github.com/pingcap/check" "github.com/pingcap/errors" timodel "github.com/pingcap/parser/model" - "github.com/pingcap/ticdc/cdc/model" - cdcContext "github.com/pingcap/ticdc/pkg/context" - "github.com/pingcap/ticdc/pkg/retry" - "github.com/pingcap/ticdc/pkg/util/testleak" "github.com/pingcap/tidb/util/codec" + "github.com/pingcap/tiflow/cdc/model" + cdcContext "github.com/pingcap/tiflow/pkg/context" + "github.com/pingcap/tiflow/pkg/retry" + "github.com/pingcap/tiflow/pkg/util/testleak" ) var _ = check.Suite(&ddlPullerSuite{}) diff --git a/cdc/owner/feed_state_manager.go b/cdc/owner/feed_state_manager.go index 3d362c6b294..fa4585a43bb 100644 --- a/cdc/owner/feed_state_manager.go +++ b/cdc/owner/feed_state_manager.go @@ -18,8 +18,8 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - cerrors "github.com/pingcap/ticdc/pkg/errors" + "github.com/pingcap/tiflow/cdc/model" + cerrors "github.com/pingcap/tiflow/pkg/errors" "go.uber.org/zap" ) diff --git a/cdc/owner/feed_state_manager_test.go b/cdc/owner/feed_state_manager_test.go index b4fc46dad3e..ae9a8c7671a 100644 --- a/cdc/owner/feed_state_manager_test.go +++ b/cdc/owner/feed_state_manager_test.go @@ -15,11 +15,11 @@ package owner import ( "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - cdcContext "github.com/pingcap/ticdc/pkg/context" - "github.com/pingcap/ticdc/pkg/orchestrator" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + cdcContext "github.com/pingcap/tiflow/pkg/context" + "github.com/pingcap/tiflow/pkg/orchestrator" + "github.com/pingcap/tiflow/pkg/util/testleak" ) var _ = check.Suite(&feedStateManagerSuite{}) diff --git a/cdc/owner/owner.go b/cdc/owner/owner.go index 3be77b8ccbc..940042c895c 100644 --- a/cdc/owner/owner.go +++ b/cdc/owner/owner.go @@ -25,12 +25,12 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - cdcContext "github.com/pingcap/ticdc/pkg/context" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/orchestrator" - "github.com/pingcap/ticdc/pkg/txnutil/gc" - "github.com/pingcap/ticdc/pkg/version" + "github.com/pingcap/tiflow/cdc/model" + cdcContext "github.com/pingcap/tiflow/pkg/context" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/orchestrator" + "github.com/pingcap/tiflow/pkg/txnutil/gc" + "github.com/pingcap/tiflow/pkg/version" pd "github.com/tikv/pd/client" "go.uber.org/zap" ) diff --git a/cdc/owner/owner_test.go b/cdc/owner/owner_test.go index 298309171f8..421ffe9ac50 100644 --- a/cdc/owner/owner_test.go +++ b/cdc/owner/owner_test.go @@ -21,15 +21,15 @@ import ( "time" "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - cdcContext "github.com/pingcap/ticdc/pkg/context" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/etcd" - "github.com/pingcap/ticdc/pkg/orchestrator" - "github.com/pingcap/ticdc/pkg/txnutil/gc" - "github.com/pingcap/ticdc/pkg/util/testleak" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + cdcContext "github.com/pingcap/tiflow/pkg/context" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/etcd" + "github.com/pingcap/tiflow/pkg/orchestrator" + "github.com/pingcap/tiflow/pkg/txnutil/gc" + "github.com/pingcap/tiflow/pkg/util/testleak" ) var _ = check.Suite(&ownerSuite{}) diff --git a/cdc/owner/scheduler.go b/cdc/owner/scheduler.go index d71725dc465..00f0771d815 100644 --- a/cdc/owner/scheduler.go +++ b/cdc/owner/scheduler.go @@ -19,8 +19,8 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - cerror "github.com/pingcap/ticdc/pkg/errors" + "github.com/pingcap/tiflow/cdc/model" + cerror "github.com/pingcap/tiflow/pkg/errors" "go.uber.org/zap" ) diff --git a/cdc/owner/scheduler_test.go b/cdc/owner/scheduler_test.go index 712a89a31e6..669ab85a8f5 100644 --- a/cdc/owner/scheduler_test.go +++ b/cdc/owner/scheduler_test.go @@ -18,9 +18,9 @@ import ( "math/rand" "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/orchestrator" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/orchestrator" + "github.com/pingcap/tiflow/pkg/util/testleak" ) var _ = check.Suite(&schedulerSuite{}) diff --git a/cdc/owner/schema.go b/cdc/owner/schema.go index f518cdada16..9cd467191b1 100644 --- a/cdc/owner/schema.go +++ b/cdc/owner/schema.go @@ -17,14 +17,14 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" timodel "github.com/pingcap/parser/model" - "github.com/pingcap/ticdc/cdc/entry" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/cyclic/mark" - "github.com/pingcap/ticdc/pkg/filter" tidbkv "github.com/pingcap/tidb/kv" timeta "github.com/pingcap/tidb/meta" + "github.com/pingcap/tiflow/cdc/entry" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/cyclic/mark" + "github.com/pingcap/tiflow/pkg/filter" "go.uber.org/zap" ) diff --git a/cdc/owner/schema_test.go b/cdc/owner/schema_test.go index 8fb7ab978cb..4494f0493bc 100644 --- a/cdc/owner/schema_test.go +++ b/cdc/owner/schema_test.go @@ -19,10 +19,10 @@ import ( "github.com/pingcap/check" timodel "github.com/pingcap/parser/model" "github.com/pingcap/parser/mysql" - "github.com/pingcap/ticdc/cdc/entry" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/entry" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/util/testleak" ) var _ = check.Suite(&schemaSuite{}) diff --git a/cdc/owner_operator.go b/cdc/owner_operator.go index 8652e6d6705..42bb1879faa 100644 --- a/cdc/owner_operator.go +++ b/cdc/owner_operator.go @@ -21,12 +21,12 @@ import ( "github.com/pingcap/errors" timodel "github.com/pingcap/parser/model" - "github.com/pingcap/ticdc/cdc/entry" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/puller" - "github.com/pingcap/ticdc/pkg/regionspan" - "github.com/pingcap/ticdc/pkg/util" + "github.com/pingcap/tiflow/cdc/entry" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/puller" + "github.com/pingcap/tiflow/pkg/regionspan" + "github.com/pingcap/tiflow/pkg/util" pd "github.com/tikv/pd/client" "golang.org/x/sync/errgroup" ) diff --git a/cdc/owner_test.go b/cdc/owner_test.go index bd9129229be..bdd96bd8e7e 100644 --- a/cdc/owner_test.go +++ b/cdc/owner_test.go @@ -28,20 +28,20 @@ import ( timodel "github.com/pingcap/parser/model" "github.com/pingcap/parser/mysql" "github.com/pingcap/parser/types" - "github.com/pingcap/ticdc/cdc/entry" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - cdcContext "github.com/pingcap/ticdc/pkg/context" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/etcd" - "github.com/pingcap/ticdc/pkg/filter" - "github.com/pingcap/ticdc/pkg/security" - "github.com/pingcap/ticdc/pkg/util" - "github.com/pingcap/ticdc/pkg/util/testleak" "github.com/pingcap/tidb/meta" "github.com/pingcap/tidb/store/mockstore" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/cdc/entry" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + cdcContext "github.com/pingcap/tiflow/pkg/context" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/etcd" + "github.com/pingcap/tiflow/pkg/filter" + "github.com/pingcap/tiflow/pkg/security" + "github.com/pingcap/tiflow/pkg/util" + "github.com/pingcap/tiflow/pkg/util/testleak" pd "github.com/tikv/pd/client" "go.etcd.io/etcd/clientv3" "go.etcd.io/etcd/clientv3/concurrency" diff --git a/cdc/processor.go b/cdc/processor.go index 8b638aa23a0..c100aaca4e5 100644 --- a/cdc/processor.go +++ b/cdc/processor.go @@ -27,22 +27,22 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/entry" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/puller" - psorter "github.com/pingcap/ticdc/cdc/puller/sorter" - "github.com/pingcap/ticdc/cdc/sink" - "github.com/pingcap/ticdc/cdc/sink/common" - serverConfig "github.com/pingcap/ticdc/pkg/config" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/filter" - "github.com/pingcap/ticdc/pkg/notify" - "github.com/pingcap/ticdc/pkg/regionspan" - "github.com/pingcap/ticdc/pkg/retry" - "github.com/pingcap/ticdc/pkg/util" tidbkv "github.com/pingcap/tidb/kv" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/cdc/entry" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/puller" + psorter "github.com/pingcap/tiflow/cdc/puller/sorter" + "github.com/pingcap/tiflow/cdc/sink" + "github.com/pingcap/tiflow/cdc/sink/common" + serverConfig "github.com/pingcap/tiflow/pkg/config" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/filter" + "github.com/pingcap/tiflow/pkg/notify" + "github.com/pingcap/tiflow/pkg/regionspan" + "github.com/pingcap/tiflow/pkg/retry" + "github.com/pingcap/tiflow/pkg/util" pd "github.com/tikv/pd/client" "go.etcd.io/etcd/clientv3" "go.etcd.io/etcd/clientv3/concurrency" diff --git a/cdc/processor/manager.go b/cdc/processor/manager.go index 8ab7291784c..b2c31566c0d 100644 --- a/cdc/processor/manager.go +++ b/cdc/processor/manager.go @@ -22,11 +22,11 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - tablepipeline "github.com/pingcap/ticdc/cdc/processor/pipeline" - cdcContext "github.com/pingcap/ticdc/pkg/context" - cerrors "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/orchestrator" + "github.com/pingcap/tiflow/cdc/model" + tablepipeline "github.com/pingcap/tiflow/cdc/processor/pipeline" + cdcContext "github.com/pingcap/tiflow/pkg/context" + cerrors "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/orchestrator" "go.uber.org/zap" ) diff --git a/cdc/processor/manager_test.go b/cdc/processor/manager_test.go index 78bbc7df086..e3a8d0e921e 100644 --- a/cdc/processor/manager_test.go +++ b/cdc/processor/manager_test.go @@ -21,13 +21,13 @@ import ( "github.com/pingcap/check" "github.com/pingcap/errors" - "github.com/pingcap/ticdc/cdc/model" - tablepipeline "github.com/pingcap/ticdc/cdc/processor/pipeline" - "github.com/pingcap/ticdc/pkg/config" - cdcContext "github.com/pingcap/ticdc/pkg/context" - cerrors "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/orchestrator" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + tablepipeline "github.com/pingcap/tiflow/cdc/processor/pipeline" + "github.com/pingcap/tiflow/pkg/config" + cdcContext "github.com/pingcap/tiflow/pkg/context" + cerrors "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/orchestrator" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type managerSuite struct { diff --git a/cdc/processor/pipeline/cyclic_mark.go b/cdc/processor/pipeline/cyclic_mark.go index da0ac0562d8..2350f6bd3b2 100644 --- a/cdc/processor/pipeline/cyclic_mark.go +++ b/cdc/processor/pipeline/cyclic_mark.go @@ -16,10 +16,10 @@ package pipeline import ( "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/entry" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/cyclic/mark" - "github.com/pingcap/ticdc/pkg/pipeline" + "github.com/pingcap/tiflow/cdc/entry" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/cyclic/mark" + "github.com/pingcap/tiflow/pkg/pipeline" "go.uber.org/zap" ) diff --git a/cdc/processor/pipeline/cyclic_mark_test.go b/cdc/processor/pipeline/cyclic_mark_test.go index 38c03c42616..0b83fb5cefc 100644 --- a/cdc/processor/pipeline/cyclic_mark_test.go +++ b/cdc/processor/pipeline/cyclic_mark_test.go @@ -20,13 +20,13 @@ import ( "github.com/google/go-cmp/cmp" "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - cdcContext "github.com/pingcap/ticdc/pkg/context" - "github.com/pingcap/ticdc/pkg/cyclic/mark" - "github.com/pingcap/ticdc/pkg/pipeline" - "github.com/pingcap/ticdc/pkg/util/testleak" "github.com/pingcap/tidb/tablecodec" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + cdcContext "github.com/pingcap/tiflow/pkg/context" + "github.com/pingcap/tiflow/pkg/cyclic/mark" + "github.com/pingcap/tiflow/pkg/pipeline" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type markSuite struct{} diff --git a/cdc/processor/pipeline/mounter.go b/cdc/processor/pipeline/mounter.go index 2e156b9cdbd..c8034ae89ae 100644 --- a/cdc/processor/pipeline/mounter.go +++ b/cdc/processor/pipeline/mounter.go @@ -21,9 +21,9 @@ import ( "github.com/edwingeng/deque" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/notify" - "github.com/pingcap/ticdc/pkg/pipeline" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/notify" + "github.com/pingcap/tiflow/pkg/pipeline" "go.uber.org/zap" "golang.org/x/sync/errgroup" "golang.org/x/time/rate" diff --git a/cdc/processor/pipeline/mounter_test.go b/cdc/processor/pipeline/mounter_test.go index dbb19ccee56..c2d2609ed15 100644 --- a/cdc/processor/pipeline/mounter_test.go +++ b/cdc/processor/pipeline/mounter_test.go @@ -22,11 +22,11 @@ import ( "github.com/pingcap/check" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - cdcContext "github.com/pingcap/ticdc/pkg/context" - "github.com/pingcap/ticdc/pkg/pipeline" - "github.com/pingcap/ticdc/pkg/retry" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + cdcContext "github.com/pingcap/tiflow/pkg/context" + "github.com/pingcap/tiflow/pkg/pipeline" + "github.com/pingcap/tiflow/pkg/retry" + "github.com/pingcap/tiflow/pkg/util/testleak" "go.uber.org/zap" ) diff --git a/cdc/processor/pipeline/puller.go b/cdc/processor/pipeline/puller.go index 9b4712dc7d0..bd2022d00d8 100644 --- a/cdc/processor/pipeline/puller.go +++ b/cdc/processor/pipeline/puller.go @@ -17,13 +17,13 @@ import ( "context" "github.com/pingcap/errors" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/puller" - cdcContext "github.com/pingcap/ticdc/pkg/context" - "github.com/pingcap/ticdc/pkg/pipeline" - "github.com/pingcap/ticdc/pkg/regionspan" - "github.com/pingcap/ticdc/pkg/util" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/puller" + cdcContext "github.com/pingcap/tiflow/pkg/context" + "github.com/pingcap/tiflow/pkg/pipeline" + "github.com/pingcap/tiflow/pkg/regionspan" + "github.com/pingcap/tiflow/pkg/util" "golang.org/x/sync/errgroup" ) diff --git a/cdc/processor/pipeline/sink.go b/cdc/processor/pipeline/sink.go index 651a250a340..b436df2a050 100644 --- a/cdc/processor/pipeline/sink.go +++ b/cdc/processor/pipeline/sink.go @@ -20,10 +20,10 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/sink" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/pipeline" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/sink" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/pipeline" "go.uber.org/zap" ) diff --git a/cdc/processor/pipeline/sink_test.go b/cdc/processor/pipeline/sink_test.go index e4b6a628593..0dccd87e5e0 100644 --- a/cdc/processor/pipeline/sink_test.go +++ b/cdc/processor/pipeline/sink_test.go @@ -20,13 +20,13 @@ import ( "time" "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - cdcContext "github.com/pingcap/ticdc/pkg/context" - cerrors "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/pipeline" - "github.com/pingcap/ticdc/pkg/util/testleak" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + cdcContext "github.com/pingcap/tiflow/pkg/context" + cerrors "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/pipeline" + "github.com/pingcap/tiflow/pkg/util/testleak" ) func TestSuite(t *testing.T) { diff --git a/cdc/processor/pipeline/sorter.go b/cdc/processor/pipeline/sorter.go index f9af23c7ab1..e1d7461c0e4 100644 --- a/cdc/processor/pipeline/sorter.go +++ b/cdc/processor/pipeline/sorter.go @@ -20,12 +20,12 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/entry" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/puller" - psorter "github.com/pingcap/ticdc/cdc/puller/sorter" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/pipeline" + "github.com/pingcap/tiflow/cdc/entry" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/puller" + psorter "github.com/pingcap/tiflow/cdc/puller/sorter" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/pipeline" "go.uber.org/zap" "golang.org/x/sync/errgroup" ) diff --git a/cdc/processor/pipeline/sorter_test.go b/cdc/processor/pipeline/sorter_test.go index da700295689..a8f3f51f068 100644 --- a/cdc/processor/pipeline/sorter_test.go +++ b/cdc/processor/pipeline/sorter_test.go @@ -15,12 +15,12 @@ package pipeline import ( "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/puller/sorter" - "github.com/pingcap/ticdc/pkg/config" - cdcContext "github.com/pingcap/ticdc/pkg/context" - "github.com/pingcap/ticdc/pkg/pipeline" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/puller/sorter" + "github.com/pingcap/tiflow/pkg/config" + cdcContext "github.com/pingcap/tiflow/pkg/context" + "github.com/pingcap/tiflow/pkg/pipeline" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type sorterSuite struct{} diff --git a/cdc/processor/pipeline/table.go b/cdc/processor/pipeline/table.go index 4defb705795..09f8823a3b6 100644 --- a/cdc/processor/pipeline/table.go +++ b/cdc/processor/pipeline/table.go @@ -18,14 +18,14 @@ import ( "time" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/entry" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/sink" - "github.com/pingcap/ticdc/cdc/sink/common" - serverConfig "github.com/pingcap/ticdc/pkg/config" - cdcContext "github.com/pingcap/ticdc/pkg/context" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/pipeline" + "github.com/pingcap/tiflow/cdc/entry" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/sink" + "github.com/pingcap/tiflow/cdc/sink/common" + serverConfig "github.com/pingcap/tiflow/pkg/config" + cdcContext "github.com/pingcap/tiflow/pkg/context" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/pipeline" "go.uber.org/zap" ) diff --git a/cdc/processor/processor.go b/cdc/processor/processor.go index 15268a01ac6..ebfb1e6a42d 100644 --- a/cdc/processor/processor.go +++ b/cdc/processor/processor.go @@ -25,21 +25,21 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/entry" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/cdc/model" - tablepipeline "github.com/pingcap/ticdc/cdc/processor/pipeline" - "github.com/pingcap/ticdc/cdc/puller" - "github.com/pingcap/ticdc/cdc/sink" - cdcContext "github.com/pingcap/ticdc/pkg/context" - "github.com/pingcap/ticdc/pkg/cyclic/mark" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/filter" - "github.com/pingcap/ticdc/pkg/orchestrator" - "github.com/pingcap/ticdc/pkg/regionspan" - "github.com/pingcap/ticdc/pkg/retry" - "github.com/pingcap/ticdc/pkg/util" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/cdc/entry" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/cdc/model" + tablepipeline "github.com/pingcap/tiflow/cdc/processor/pipeline" + "github.com/pingcap/tiflow/cdc/puller" + "github.com/pingcap/tiflow/cdc/sink" + cdcContext "github.com/pingcap/tiflow/pkg/context" + "github.com/pingcap/tiflow/pkg/cyclic/mark" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/filter" + "github.com/pingcap/tiflow/pkg/orchestrator" + "github.com/pingcap/tiflow/pkg/regionspan" + "github.com/pingcap/tiflow/pkg/retry" + "github.com/pingcap/tiflow/pkg/util" "github.com/prometheus/client_golang/prometheus" "go.uber.org/zap" ) diff --git a/cdc/processor/processor_test.go b/cdc/processor/processor_test.go index d1fa9558835..d5f894836cd 100644 --- a/cdc/processor/processor_test.go +++ b/cdc/processor/processor_test.go @@ -21,12 +21,12 @@ import ( "github.com/pingcap/check" "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - tablepipeline "github.com/pingcap/ticdc/cdc/processor/pipeline" - cdcContext "github.com/pingcap/ticdc/pkg/context" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/orchestrator" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + tablepipeline "github.com/pingcap/tiflow/cdc/processor/pipeline" + cdcContext "github.com/pingcap/tiflow/pkg/context" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/orchestrator" + "github.com/pingcap/tiflow/pkg/util/testleak" ) func Test(t *testing.T) { check.TestingT(t) } diff --git a/cdc/processor_test.go b/cdc/processor_test.go index 93e75c036ed..5e591e89d36 100644 --- a/cdc/processor_test.go +++ b/cdc/processor_test.go @@ -17,9 +17,9 @@ import ( "bytes" "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type processorSuite struct{} @@ -54,15 +54,15 @@ import ( "sync" "time" - "github.com/pingcap/ticdc/cdc/entry" + "github.com/pingcap/tiflow/cdc/entry" "github.com/pingcap/check" pd "github.com/pingcap/pd/client" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/roles/storage" - "github.com/pingcap/ticdc/cdc/sink" - "github.com/pingcap/ticdc/pkg/etcd" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/roles/storage" + "github.com/pingcap/tiflow/cdc/sink" + "github.com/pingcap/tiflow/pkg/etcd" ) type processorSuite struct{} diff --git a/cdc/puller/entry_sorter.go b/cdc/puller/entry_sorter.go index 8a9caa8b539..a11a8eaf0a6 100644 --- a/cdc/puller/entry_sorter.go +++ b/cdc/puller/entry_sorter.go @@ -22,9 +22,9 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/notify" - "github.com/pingcap/ticdc/pkg/util" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/notify" + "github.com/pingcap/tiflow/pkg/util" "go.uber.org/zap" "golang.org/x/sync/errgroup" ) diff --git a/cdc/puller/entry_sorter_test.go b/cdc/puller/entry_sorter_test.go index 91a64bfb300..5c074af791f 100644 --- a/cdc/puller/entry_sorter_test.go +++ b/cdc/puller/entry_sorter_test.go @@ -21,8 +21,8 @@ import ( "github.com/pingcap/check" "github.com/pingcap/errors" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type mockEntrySorterSuite struct{} diff --git a/cdc/puller/frontier/frontier.go b/cdc/puller/frontier/frontier.go index ed1b10f94d3..6d6d493808e 100644 --- a/cdc/puller/frontier/frontier.go +++ b/cdc/puller/frontier/frontier.go @@ -19,7 +19,7 @@ import ( "math" "strings" - "github.com/pingcap/ticdc/pkg/regionspan" + "github.com/pingcap/tiflow/pkg/regionspan" ) // Frontier checks resolved event of spans and moves the global resolved ts ahead diff --git a/cdc/puller/frontier/frontier_bench_test.go b/cdc/puller/frontier/frontier_bench_test.go index b966740ceef..158122129b1 100644 --- a/cdc/puller/frontier/frontier_bench_test.go +++ b/cdc/puller/frontier/frontier_bench_test.go @@ -17,7 +17,7 @@ import ( "fmt" "testing" - "github.com/pingcap/ticdc/pkg/regionspan" + "github.com/pingcap/tiflow/pkg/regionspan" ) func toCMPBytes(i int) []byte { diff --git a/cdc/puller/frontier/frontier_test.go b/cdc/puller/frontier/frontier_test.go index 0533fc133ef..3bcde1d8abd 100644 --- a/cdc/puller/frontier/frontier_test.go +++ b/cdc/puller/frontier/frontier_test.go @@ -20,8 +20,8 @@ import ( "testing" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/regionspan" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/regionspan" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type spanFrontierSuite struct{} diff --git a/cdc/puller/frontier/heap_test.go b/cdc/puller/frontier/heap_test.go index 5bc9686106e..ccfc9befc17 100644 --- a/cdc/puller/frontier/heap_test.go +++ b/cdc/puller/frontier/heap_test.go @@ -19,7 +19,7 @@ import ( "time" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type tsHeapSuite struct{} diff --git a/cdc/puller/frontier/list_test.go b/cdc/puller/frontier/list_test.go index 7acf366f77e..92c27a87dbc 100644 --- a/cdc/puller/frontier/list_test.go +++ b/cdc/puller/frontier/list_test.go @@ -18,7 +18,7 @@ import ( "math/rand" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type spanListSuite struct{} diff --git a/cdc/puller/mock_puller.go b/cdc/puller/mock_puller.go index 496bb2b82e2..749b891407e 100644 --- a/cdc/puller/mock_puller.go +++ b/cdc/puller/mock_puller.go @@ -22,14 +22,14 @@ import ( "github.com/pingcap/kvproto/pkg/kvrpcpb" "github.com/pingcap/log" timodel "github.com/pingcap/parser/model" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/regionspan" "github.com/pingcap/tidb/domain" tidbkv "github.com/pingcap/tidb/kv" "github.com/pingcap/tidb/session" "github.com/pingcap/tidb/store/mockstore" "github.com/pingcap/tidb/store/mockstore/mocktikv" "github.com/pingcap/tidb/util/testkit" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/regionspan" "go.uber.org/zap" ) diff --git a/cdc/puller/mock_puller_test.go b/cdc/puller/mock_puller_test.go index b7b4be4aa52..02a3c60eb51 100644 --- a/cdc/puller/mock_puller_test.go +++ b/cdc/puller/mock_puller_test.go @@ -22,9 +22,9 @@ import ( "github.com/pingcap/check" "github.com/pingcap/errors" - "github.com/pingcap/ticdc/cdc/entry" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/util" + "github.com/pingcap/tiflow/cdc/entry" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/util" "github.com/pingcap/tidb/store/tikv/oracle" ) diff --git a/cdc/puller/puller.go b/cdc/puller/puller.go index dd497a31a6f..8de1de753bc 100644 --- a/cdc/puller/puller.go +++ b/cdc/puller/puller.go @@ -20,15 +20,15 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/puller/frontier" - "github.com/pingcap/ticdc/pkg/regionspan" - "github.com/pingcap/ticdc/pkg/txnutil" - "github.com/pingcap/ticdc/pkg/util" tidbkv "github.com/pingcap/tidb/kv" "github.com/pingcap/tidb/store/tikv" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/puller/frontier" + "github.com/pingcap/tiflow/pkg/regionspan" + "github.com/pingcap/tiflow/pkg/txnutil" + "github.com/pingcap/tiflow/pkg/util" pd "github.com/tikv/pd/client" "go.uber.org/zap" "golang.org/x/sync/errgroup" @@ -159,7 +159,7 @@ func (p *pullerImpl) Run(ctx context.Context) error { lastResolvedTs := p.checkpointTs g.Go(func() error { output := func(raw *model.RawKVEntry) error { - // even after https://github.com/pingcap/ticdc/pull/2038, kv client + // even after https://github.com/pingcap/tiflow/pull/2038, kv client // could still miss region change notification, which leads to resolved // ts update missing in puller, however resolved ts fallback here can // be ignored since no late data is received and the guarantee of diff --git a/cdc/puller/puller_test.go b/cdc/puller/puller_test.go index c27691fedc3..69c55185692 100644 --- a/cdc/puller/puller_test.go +++ b/cdc/puller/puller_test.go @@ -21,17 +21,17 @@ import ( "github.com/pingcap/check" "github.com/pingcap/errors" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/cdc/model" - cerrors "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/regionspan" - "github.com/pingcap/ticdc/pkg/retry" - "github.com/pingcap/ticdc/pkg/security" - "github.com/pingcap/ticdc/pkg/txnutil" - "github.com/pingcap/ticdc/pkg/util/testleak" tidbkv "github.com/pingcap/tidb/kv" "github.com/pingcap/tidb/store/mockstore" "github.com/pingcap/tidb/store/tikv" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/cdc/model" + cerrors "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/regionspan" + "github.com/pingcap/tiflow/pkg/retry" + "github.com/pingcap/tiflow/pkg/security" + "github.com/pingcap/tiflow/pkg/txnutil" + "github.com/pingcap/tiflow/pkg/util/testleak" pd "github.com/tikv/pd/client" ) diff --git a/cdc/puller/sorter.go b/cdc/puller/sorter.go index 3864cd65e43..53136e01836 100644 --- a/cdc/puller/sorter.go +++ b/cdc/puller/sorter.go @@ -16,7 +16,7 @@ package puller import ( "context" - "github.com/pingcap/ticdc/cdc/model" + "github.com/pingcap/tiflow/cdc/model" ) // EventSorter accepts unsorted PolymorphicEvents, sort them in background and returns diff --git a/cdc/puller/sorter/backend.go b/cdc/puller/sorter/backend.go index 4554ffc7e69..50ef7cc8ac7 100644 --- a/cdc/puller/sorter/backend.go +++ b/cdc/puller/sorter/backend.go @@ -13,7 +13,7 @@ package sorter -import "github.com/pingcap/ticdc/cdc/model" +import "github.com/pingcap/tiflow/cdc/model" type backEnd interface { reader() (backEndReader, error) diff --git a/cdc/puller/sorter/backend_pool.go b/cdc/puller/sorter/backend_pool.go index dcdfd522d93..7a3e3fc0122 100644 --- a/cdc/puller/sorter/backend_pool.go +++ b/cdc/puller/sorter/backend_pool.go @@ -27,11 +27,11 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/pkg/config" - cerrors "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/filelock" - "github.com/pingcap/ticdc/pkg/util" "github.com/pingcap/tidb/util/memory" + "github.com/pingcap/tiflow/pkg/config" + cerrors "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/filelock" + "github.com/pingcap/tiflow/pkg/util" "go.uber.org/zap" ) diff --git a/cdc/puller/sorter/backend_pool_test.go b/cdc/puller/sorter/backend_pool_test.go index 81bef2a4c90..8feae7b8918 100644 --- a/cdc/puller/sorter/backend_pool_test.go +++ b/cdc/puller/sorter/backend_pool_test.go @@ -23,10 +23,10 @@ import ( "github.com/pingcap/check" "github.com/pingcap/failpoint" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/filelock" - "github.com/pingcap/ticdc/pkg/util/testleak" "github.com/pingcap/tidb/util/memory" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/filelock" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type backendPoolSuite struct{} @@ -51,7 +51,7 @@ func (s *backendPoolSuite) TestBasicFunction(c *check.C) { conf.Sorter.MaxMemoryConsumption = 16 * 1024 * 1024 * 1024 // 16G config.StoreGlobalServerConfig(conf) - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/memoryPressureInjectPoint", "return(100)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/memoryPressureInjectPoint", "return(100)") c.Assert(err, check.IsNil) ctx, cancel := context.WithTimeout(context.Background(), time.Second*20) @@ -68,9 +68,9 @@ func (s *backendPoolSuite) TestBasicFunction(c *check.C) { fileName := backEnd.(*fileBackEnd).fileName c.Assert(fileName, check.Not(check.Equals), "") - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/memoryPressureInjectPoint", "return(0)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/memoryPressureInjectPoint", "return(0)") c.Assert(err, check.IsNil) - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/memoryUsageInjectPoint", "return(34359738368)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/memoryUsageInjectPoint", "return(34359738368)") c.Assert(err, check.IsNil) backEnd1, err := backEndPool.alloc(ctx) @@ -80,9 +80,9 @@ func (s *backendPoolSuite) TestBasicFunction(c *check.C) { c.Assert(fileName1, check.Not(check.Equals), "") c.Assert(fileName1, check.Not(check.Equals), fileName) - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/memoryPressureInjectPoint", "return(0)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/memoryPressureInjectPoint", "return(0)") c.Assert(err, check.IsNil) - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/memoryUsageInjectPoint", "return(0)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/memoryUsageInjectPoint", "return(0)") c.Assert(err, check.IsNil) backEnd2, err := backEndPool.alloc(ctx) @@ -161,9 +161,9 @@ func (s *backendPoolSuite) TestCleanUpSelf(c *check.C) { conf.Sorter.MaxMemoryConsumption = 16 * 1024 * 1024 * 1024 // 16G config.StoreGlobalServerConfig(conf) - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/memoryPressureInjectPoint", "return(100)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/memoryPressureInjectPoint", "return(100)") c.Assert(err, check.IsNil) - defer failpoint.Disable("github.com/pingcap/ticdc/cdc/puller/sorter/memoryPressureInjectPoint") //nolint:errcheck + defer failpoint.Disable("github.com/pingcap/tiflow/cdc/puller/sorter/memoryPressureInjectPoint") //nolint:errcheck backEndPool, err := newBackEndPool(sorterDir, "") c.Assert(err, check.IsNil) diff --git a/cdc/puller/sorter/file_backend.go b/cdc/puller/sorter/file_backend.go index 14b50679b17..11d3e4ed742 100644 --- a/cdc/puller/sorter/file_backend.go +++ b/cdc/puller/sorter/file_backend.go @@ -23,8 +23,8 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - cerrors "github.com/pingcap/ticdc/pkg/errors" + "github.com/pingcap/tiflow/cdc/model" + cerrors "github.com/pingcap/tiflow/pkg/errors" "go.uber.org/zap" ) diff --git a/cdc/puller/sorter/file_backend_test.go b/cdc/puller/sorter/file_backend_test.go index c1035058446..48b2b6f303b 100644 --- a/cdc/puller/sorter/file_backend_test.go +++ b/cdc/puller/sorter/file_backend_test.go @@ -18,9 +18,9 @@ import ( "os" "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/model" - cerrors "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + cerrors "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type fileBackendSuite struct{} diff --git a/cdc/puller/sorter/heap.go b/cdc/puller/sorter/heap.go index 8b166322d34..358db5cb314 100644 --- a/cdc/puller/sorter/heap.go +++ b/cdc/puller/sorter/heap.go @@ -13,7 +13,7 @@ package sorter -import "github.com/pingcap/ticdc/cdc/model" +import "github.com/pingcap/tiflow/cdc/model" type sortItem struct { entry *model.PolymorphicEvent diff --git a/cdc/puller/sorter/heap_sorter.go b/cdc/puller/sorter/heap_sorter.go index 2ccbd653808..190bfaeba2c 100644 --- a/cdc/puller/sorter/heap_sorter.go +++ b/cdc/puller/sorter/heap_sorter.go @@ -23,11 +23,11 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - cerrors "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/util" - "github.com/pingcap/ticdc/pkg/workerpool" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + cerrors "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/util" + "github.com/pingcap/tiflow/pkg/workerpool" "go.uber.org/zap" ) diff --git a/cdc/puller/sorter/memory_backend.go b/cdc/puller/sorter/memory_backend.go index 9a0e81d1f80..8e8e76555fd 100644 --- a/cdc/puller/sorter/memory_backend.go +++ b/cdc/puller/sorter/memory_backend.go @@ -18,7 +18,7 @@ import ( "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" + "github.com/pingcap/tiflow/cdc/model" "go.uber.org/zap" ) diff --git a/cdc/puller/sorter/memory_backend_test.go b/cdc/puller/sorter/memory_backend_test.go index 86b93b3ebcf..4055739eea9 100644 --- a/cdc/puller/sorter/memory_backend_test.go +++ b/cdc/puller/sorter/memory_backend_test.go @@ -19,8 +19,8 @@ import ( "time" "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type memoryBackendSuite struct{} diff --git a/cdc/puller/sorter/merger.go b/cdc/puller/sorter/merger.go index 4e547003003..3f8104b5c32 100644 --- a/cdc/puller/sorter/merger.go +++ b/cdc/puller/sorter/merger.go @@ -25,11 +25,11 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - cerrors "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/notify" - "github.com/pingcap/ticdc/pkg/util" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/cdc/model" + cerrors "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/notify" + "github.com/pingcap/tiflow/pkg/util" "go.uber.org/zap" "golang.org/x/sync/errgroup" ) diff --git a/cdc/puller/sorter/merger_test.go b/cdc/puller/sorter/merger_test.go index afc23a47dbd..e362ec6306d 100644 --- a/cdc/puller/sorter/merger_test.go +++ b/cdc/puller/sorter/merger_test.go @@ -21,8 +21,8 @@ import ( "github.com/pingcap/check" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/util/testleak" "go.uber.org/zap" "go.uber.org/zap/zapcore" "golang.org/x/sync/errgroup" @@ -93,7 +93,7 @@ func (b *mockFlushTaskBuilder) build() *flushTask { // It tests the most basic scenario. func (s *sorterSuite) TestMergerSingleHeap(c *check.C) { defer testleak.AfterTest(c)() - err := failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/sorterDebug", "return(true)") + err := failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/sorterDebug", "return(true)") if err != nil { log.Panic("Could not enable failpoint", zap.Error(err)) } @@ -164,7 +164,7 @@ func (s *sorterSuite) TestMergerSingleHeap(c *check.C) { // TestMergerSingleHeapRetire simulates a situation where the resolved event is not the last event in a flushTask func (s *sorterSuite) TestMergerSingleHeapRetire(c *check.C) { defer testleak.AfterTest(c)() - err := failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/sorterDebug", "return(true)") + err := failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/sorterDebug", "return(true)") if err != nil { log.Panic("Could not enable failpoint", zap.Error(err)) } @@ -237,14 +237,14 @@ func (s *sorterSuite) TestMergerSingleHeapRetire(c *check.C) { // Expects intermediate resolved events to be generated, so that the sink would not get stuck in a real life situation. func (s *sorterSuite) TestMergerSortDelay(c *check.C) { defer testleak.AfterTest(c)() - err := failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/sorterDebug", "return(true)") + err := failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/sorterDebug", "return(true)") c.Assert(err, check.IsNil) // enable the failpoint to simulate delays - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/sorterMergeDelay", "sleep(5)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/sorterMergeDelay", "sleep(5)") c.Assert(err, check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/puller/sorter/sorterMergeDelay") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/puller/sorter/sorterMergeDelay") }() log.SetLevel(zapcore.DebugLevel) @@ -317,14 +317,14 @@ func (s *sorterSuite) TestMergerSortDelay(c *check.C) { // Expects proper clean-up of the data. func (s *sorterSuite) TestMergerCancel(c *check.C) { defer testleak.AfterTest(c)() - err := failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/sorterDebug", "return(true)") + err := failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/sorterDebug", "return(true)") c.Assert(err, check.IsNil) // enable the failpoint to simulate delays - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/sorterMergeDelay", "sleep(10)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/sorterMergeDelay", "sleep(10)") c.Assert(err, check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/puller/sorter/sorterMergeDelay") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/puller/sorter/sorterMergeDelay") }() log.SetLevel(zapcore.DebugLevel) @@ -380,7 +380,7 @@ func (s *sorterSuite) TestMergerCancel(c *check.C) { // Expects proper clean-up of the data. func (s *sorterSuite) TestMergerCancelWithUnfinishedFlushTasks(c *check.C) { defer testleak.AfterTest(c)() - err := failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/sorterDebug", "return(true)") + err := failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/sorterDebug", "return(true)") c.Assert(err, check.IsNil) log.SetLevel(zapcore.DebugLevel) @@ -436,7 +436,7 @@ func (s *sorterSuite) TestMergerCancelWithUnfinishedFlushTasks(c *check.C) { // There is expected to be NO fatal error. func (s *sorterSuite) TestMergerCloseChannel(c *check.C) { defer testleak.AfterTest(c)() - err := failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/sorterDebug", "return(true)") + err := failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/sorterDebug", "return(true)") c.Assert(err, check.IsNil) log.SetLevel(zapcore.DebugLevel) @@ -482,9 +482,9 @@ func (s *sorterSuite) TestMergerCloseChannel(c *check.C) { // a significant period of time. func (s *sorterSuite) TestMergerOutputBlocked(c *check.C) { defer testleak.AfterTest(c)() - err := failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/sorterDebug", "return(true)") + err := failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/sorterDebug", "return(true)") c.Assert(err, check.IsNil) - defer failpoint.Disable("github.com/pingcap/ticdc/cdc/puller/sorter/sorterDebug") //nolint:errcheck + defer failpoint.Disable("github.com/pingcap/tiflow/cdc/puller/sorter/sorterDebug") //nolint:errcheck ctx, cancel := context.WithTimeout(context.TODO(), time.Second*25) defer cancel() diff --git a/cdc/puller/sorter/serde.go b/cdc/puller/sorter/serde.go index 976b86b9c14..48d0f348dd5 100644 --- a/cdc/puller/sorter/serde.go +++ b/cdc/puller/sorter/serde.go @@ -15,7 +15,7 @@ package sorter import ( "github.com/pingcap/errors" - "github.com/pingcap/ticdc/cdc/model" + "github.com/pingcap/tiflow/cdc/model" ) type msgPackGenSerde struct{} diff --git a/cdc/puller/sorter/sorter_test.go b/cdc/puller/sorter/sorter_test.go index 4d2906a7f1b..590461bef5c 100644 --- a/cdc/puller/sorter/sorter_test.go +++ b/cdc/puller/sorter/sorter_test.go @@ -26,10 +26,10 @@ import ( "github.com/pingcap/check" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/puller" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/puller" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/util/testleak" "go.uber.org/zap" "go.uber.org/zap/zapcore" "golang.org/x/sync/errgroup" @@ -128,14 +128,14 @@ func (s *sorterSuite) TestSorterCancel(c *check.C) { } func testSorter(ctx context.Context, c *check.C, sorter puller.EventSorter, count int) error { - err := failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/sorterDebug", "return(true)") + err := failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/sorterDebug", "return(true)") if err != nil { log.Panic("Could not enable failpoint", zap.Error(err)) } - c.Assert(failpoint.Enable("github.com/pingcap/ticdc/pkg/util/InjectCheckDataDirSatisfied", ""), check.IsNil) + c.Assert(failpoint.Enable("github.com/pingcap/tiflow/pkg/util/InjectCheckDataDirSatisfied", ""), check.IsNil) defer func() { - c.Assert(failpoint.Disable("github.com/pingcap/ticdc/pkg/util/InjectCheckDataDirSatisfied"), check.IsNil) + c.Assert(failpoint.Disable("github.com/pingcap/tiflow/pkg/util/InjectCheckDataDirSatisfied"), check.IsNil) }() ctx, cancel := context.WithCancel(ctx) @@ -310,17 +310,17 @@ func (s *sorterSuite) TestSorterCancelRestart(c *check.C) { c.Assert(err, check.IsNil) // enable the failpoint to simulate delays - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/asyncFlushStartDelay", "sleep(100)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/asyncFlushStartDelay", "sleep(100)") c.Assert(err, check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/puller/sorter/asyncFlushStartDelay") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/puller/sorter/asyncFlushStartDelay") }() // enable the failpoint to simulate delays - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/asyncFlushInProcessDelay", "1%sleep(1)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/asyncFlushInProcessDelay", "1%sleep(1)") c.Assert(err, check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/puller/sorter/asyncFlushInProcessDelay") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/puller/sorter/asyncFlushInProcessDelay") }() for i := 0; i < 5; i++ { @@ -362,10 +362,10 @@ func (s *sorterSuite) TestSorterIOError(c *check.C) { defer cancel() // enable the failpoint to simulate backEnd allocation error (usually would happen when creating a file) - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/InjectErrorBackEndAlloc", "return(true)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/InjectErrorBackEndAlloc", "return(true)") c.Assert(err, check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/puller/sorter/InjectErrorBackEndAlloc") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/puller/sorter/InjectErrorBackEndAlloc") }() finishedCh := make(chan struct{}) @@ -383,12 +383,12 @@ func (s *sorterSuite) TestSorterIOError(c *check.C) { } UnifiedSorterCleanUp() - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/puller/sorter/InjectErrorBackEndAlloc") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/puller/sorter/InjectErrorBackEndAlloc") // enable the failpoint to simulate backEnd write error (usually would happen when writing to a file) - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/InjectErrorBackEndWrite", "return(true)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/InjectErrorBackEndWrite", "return(true)") c.Assert(err, check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/puller/sorter/InjectErrorBackEndWrite") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/puller/sorter/InjectErrorBackEndWrite") }() // recreate the sorter @@ -439,16 +439,16 @@ func (s *sorterSuite) TestSorterErrorReportCorrect(c *check.C) { defer cancel() // enable the failpoint to simulate backEnd allocation error (usually would happen when creating a file) - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/InjectHeapSorterExitDelay", "sleep(2000)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/InjectHeapSorterExitDelay", "sleep(2000)") c.Assert(err, check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/puller/sorter/InjectHeapSorterExitDelay") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/puller/sorter/InjectHeapSorterExitDelay") }() - err = failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/InjectErrorBackEndAlloc", "return(true)") + err = failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/InjectErrorBackEndAlloc", "return(true)") c.Assert(err, check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/puller/sorter/InjectErrorBackEndAlloc") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/puller/sorter/InjectErrorBackEndAlloc") }() finishedCh := make(chan struct{}) diff --git a/cdc/puller/sorter/unified_sorter.go b/cdc/puller/sorter/unified_sorter.go index cd44f3e584b..1a7af7dd430 100644 --- a/cdc/puller/sorter/unified_sorter.go +++ b/cdc/puller/sorter/unified_sorter.go @@ -21,10 +21,10 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/util" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/util" "golang.org/x/sync/errgroup" ) diff --git a/cdc/server.go b/cdc/server.go index 2a9d2a92c88..c605ddb53f5 100644 --- a/cdc/server.go +++ b/cdc/server.go @@ -25,15 +25,15 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/capture" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/cdc/puller/sorter" - "github.com/pingcap/ticdc/pkg/config" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/httputil" - "github.com/pingcap/ticdc/pkg/util" - "github.com/pingcap/ticdc/pkg/version" tidbkv "github.com/pingcap/tidb/kv" + "github.com/pingcap/tiflow/cdc/capture" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/cdc/puller/sorter" + "github.com/pingcap/tiflow/pkg/config" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/httputil" + "github.com/pingcap/tiflow/pkg/util" + "github.com/pingcap/tiflow/pkg/version" "github.com/prometheus/client_golang/prometheus" pd "github.com/tikv/pd/client" "go.etcd.io/etcd/clientv3" diff --git a/cdc/server_test.go b/cdc/server_test.go index 1020168c8d5..5552b802012 100644 --- a/cdc/server_test.go +++ b/cdc/server_test.go @@ -20,12 +20,12 @@ import ( "time" "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/etcd" - "github.com/pingcap/ticdc/pkg/util" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/etcd" + "github.com/pingcap/tiflow/pkg/util" + "github.com/pingcap/tiflow/pkg/util/testleak" "go.etcd.io/etcd/clientv3" "go.etcd.io/etcd/embed" "golang.org/x/sync/errgroup" diff --git a/cdc/sink/black_hole.go b/cdc/sink/black_hole.go index 3eca14a0119..42e623422f7 100644 --- a/cdc/sink/black_hole.go +++ b/cdc/sink/black_hole.go @@ -18,7 +18,7 @@ import ( "sync/atomic" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" + "github.com/pingcap/tiflow/cdc/model" "go.uber.org/zap" ) diff --git a/cdc/sink/causality.go b/cdc/sink/causality.go index 0a9377c36e2..0d7c0389735 100644 --- a/cdc/sink/causality.go +++ b/cdc/sink/causality.go @@ -19,7 +19,7 @@ import ( "github.com/pingcap/log" "go.uber.org/zap" - "github.com/pingcap/ticdc/cdc/model" + "github.com/pingcap/tiflow/cdc/model" ) // causality provides a simple mechanism to improve the concurrency of SQLs execution under the premise of ensuring correctness. diff --git a/cdc/sink/causality_test.go b/cdc/sink/causality_test.go index 674124a070e..caf456a88c5 100644 --- a/cdc/sink/causality_test.go +++ b/cdc/sink/causality_test.go @@ -19,8 +19,8 @@ import ( "github.com/pingcap/check" "github.com/pingcap/parser/mysql" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type testCausalitySuite struct{} diff --git a/cdc/sink/cdclog/file.go b/cdc/sink/cdclog/file.go index 1e66bb47a9b..0a76d1a5fc2 100644 --- a/cdc/sink/cdclog/file.go +++ b/cdc/sink/cdclog/file.go @@ -22,10 +22,10 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" parsemodel "github.com/pingcap/parser/model" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/sink/codec" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/quotes" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/sink/codec" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/quotes" "github.com/uber-go/atomic" "go.uber.org/zap" ) diff --git a/cdc/sink/cdclog/s3.go b/cdc/sink/cdclog/s3.go index 3aa9ceab4e1..a47682629dd 100644 --- a/cdc/sink/cdclog/s3.go +++ b/cdc/sink/cdclog/s3.go @@ -24,10 +24,10 @@ import ( "github.com/pingcap/kvproto/pkg/backup" "github.com/pingcap/log" parsemodel "github.com/pingcap/parser/model" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/sink/codec" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/quotes" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/sink/codec" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/quotes" "github.com/uber-go/atomic" "go.uber.org/zap" ) diff --git a/cdc/sink/cdclog/utils.go b/cdc/sink/cdclog/utils.go index 52661293ad5..f901765e7ee 100644 --- a/cdc/sink/cdclog/utils.go +++ b/cdc/sink/cdclog/utils.go @@ -22,9 +22,9 @@ import ( "github.com/pingcap/br/pkg/storage" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/sink/codec" - "github.com/pingcap/ticdc/pkg/quotes" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/sink/codec" + "github.com/pingcap/tiflow/pkg/quotes" "github.com/uber-go/atomic" "go.uber.org/zap" "golang.org/x/sync/errgroup" diff --git a/cdc/sink/codec/avro.go b/cdc/sink/codec/avro.go index 7a7b2b3feef..bb06324c88c 100644 --- a/cdc/sink/codec/avro.go +++ b/cdc/sink/codec/avro.go @@ -27,9 +27,9 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" "github.com/pingcap/parser/mysql" - "github.com/pingcap/ticdc/cdc/model" - cerror "github.com/pingcap/ticdc/pkg/errors" "github.com/pingcap/tidb/types" + "github.com/pingcap/tiflow/cdc/model" + cerror "github.com/pingcap/tiflow/pkg/errors" "go.uber.org/zap" ) diff --git a/cdc/sink/codec/avro_test.go b/cdc/sink/codec/avro_test.go index 779be79c451..087b4874fd9 100644 --- a/cdc/sink/codec/avro_test.go +++ b/cdc/sink/codec/avro_test.go @@ -23,12 +23,12 @@ import ( "github.com/pingcap/log" model2 "github.com/pingcap/parser/model" "github.com/pingcap/parser/mysql" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/puller" - "github.com/pingcap/ticdc/pkg/regionspan" - "github.com/pingcap/ticdc/pkg/security" - "github.com/pingcap/ticdc/pkg/util/testleak" "github.com/pingcap/tidb/types" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/puller" + "github.com/pingcap/tiflow/pkg/regionspan" + "github.com/pingcap/tiflow/pkg/security" + "github.com/pingcap/tiflow/pkg/util/testleak" "go.uber.org/zap" ) diff --git a/cdc/sink/codec/canal.go b/cdc/sink/codec/canal.go index 76aee5f562c..1e058da4b95 100644 --- a/cdc/sink/codec/canal.go +++ b/cdc/sink/codec/canal.go @@ -24,9 +24,9 @@ import ( mm "github.com/pingcap/parser/model" "github.com/pingcap/parser/mysql" parser_types "github.com/pingcap/parser/types" - "github.com/pingcap/ticdc/cdc/model" - cerror "github.com/pingcap/ticdc/pkg/errors" - canal "github.com/pingcap/ticdc/proto/canal" + "github.com/pingcap/tiflow/cdc/model" + cerror "github.com/pingcap/tiflow/pkg/errors" + canal "github.com/pingcap/tiflow/proto/canal" "go.uber.org/zap" "golang.org/x/text/encoding" "golang.org/x/text/encoding/charmap" diff --git a/cdc/sink/codec/canal_flat.go b/cdc/sink/codec/canal_flat.go index 68115283769..151ecece2fb 100644 --- a/cdc/sink/codec/canal_flat.go +++ b/cdc/sink/codec/canal_flat.go @@ -18,9 +18,9 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - cerrors "github.com/pingcap/ticdc/pkg/errors" - canal "github.com/pingcap/ticdc/proto/canal" + "github.com/pingcap/tiflow/cdc/model" + cerrors "github.com/pingcap/tiflow/pkg/errors" + canal "github.com/pingcap/tiflow/proto/canal" "go.uber.org/zap" ) diff --git a/cdc/sink/codec/canal_flat_test.go b/cdc/sink/codec/canal_flat_test.go index b1b36aab67f..d3121b542b9 100644 --- a/cdc/sink/codec/canal_flat_test.go +++ b/cdc/sink/codec/canal_flat_test.go @@ -19,8 +19,8 @@ import ( "github.com/pingcap/check" mm "github.com/pingcap/parser/model" "github.com/pingcap/parser/mysql" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/util/testleak" "golang.org/x/text/encoding/charmap" ) diff --git a/cdc/sink/codec/canal_test.go b/cdc/sink/codec/canal_test.go index 1820224ab42..55c624a81f3 100644 --- a/cdc/sink/codec/canal_test.go +++ b/cdc/sink/codec/canal_test.go @@ -20,9 +20,9 @@ import ( "github.com/pingcap/parser/mysql" "golang.org/x/text/encoding/charmap" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/util/testleak" - canal "github.com/pingcap/ticdc/proto/canal" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/util/testleak" + canal "github.com/pingcap/tiflow/proto/canal" ) type canalBatchSuite struct { diff --git a/cdc/sink/codec/interface.go b/cdc/sink/codec/interface.go index 58df343ee4f..d843f4f4494 100644 --- a/cdc/sink/codec/interface.go +++ b/cdc/sink/codec/interface.go @@ -19,8 +19,8 @@ import ( "time" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/cdc/model" "go.uber.org/zap" ) diff --git a/cdc/sink/codec/interface_test.go b/cdc/sink/codec/interface_test.go index 153139e07e6..0afbe63065f 100644 --- a/cdc/sink/codec/interface_test.go +++ b/cdc/sink/codec/interface_test.go @@ -18,8 +18,8 @@ import ( timodel "github.com/pingcap/parser/model" "github.com/pingcap/parser/mysql" "github.com/pingcap/parser/types" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type codecInterfaceSuite struct{} diff --git a/cdc/sink/codec/json.go b/cdc/sink/codec/json.go index e785f8d636c..f95cace1af5 100644 --- a/cdc/sink/codec/json.go +++ b/cdc/sink/codec/json.go @@ -26,10 +26,10 @@ import ( "github.com/pingcap/log" timodel "github.com/pingcap/parser/model" "github.com/pingcap/parser/mysql" - cerror "github.com/pingcap/ticdc/pkg/errors" + cerror "github.com/pingcap/tiflow/pkg/errors" "go.uber.org/zap" - "github.com/pingcap/ticdc/cdc/model" + "github.com/pingcap/tiflow/cdc/model" ) const ( diff --git a/cdc/sink/codec/json_test.go b/cdc/sink/codec/json_test.go index 59a6093dabc..cdd3c128d56 100644 --- a/cdc/sink/codec/json_test.go +++ b/cdc/sink/codec/json_test.go @@ -20,8 +20,8 @@ import ( "github.com/pingcap/check" "github.com/pingcap/parser/mysql" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/util/testleak" ) func Test(t *testing.T) { check.TestingT(t) } diff --git a/cdc/sink/codec/maxwell.go b/cdc/sink/codec/maxwell.go index 5aab129c315..93ed89defc9 100644 --- a/cdc/sink/codec/maxwell.go +++ b/cdc/sink/codec/maxwell.go @@ -21,8 +21,8 @@ import ( "github.com/pingcap/errors" model2 "github.com/pingcap/parser/model" "github.com/pingcap/parser/mysql" - "github.com/pingcap/ticdc/cdc/model" - cerror "github.com/pingcap/ticdc/pkg/errors" + "github.com/pingcap/tiflow/cdc/model" + cerror "github.com/pingcap/tiflow/pkg/errors" "github.com/tikv/pd/pkg/tsoutil" ) diff --git a/cdc/sink/codec/maxwell_test.go b/cdc/sink/codec/maxwell_test.go index f624efc453d..5e6fea4a58e 100644 --- a/cdc/sink/codec/maxwell_test.go +++ b/cdc/sink/codec/maxwell_test.go @@ -15,8 +15,8 @@ package codec import ( "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type maxwellbatchSuite struct { diff --git a/cdc/sink/codec/schema_registry.go b/cdc/sink/codec/schema_registry.go index a7106b548b8..bed095edf48 100644 --- a/cdc/sink/codec/schema_registry.go +++ b/cdc/sink/codec/schema_registry.go @@ -29,10 +29,10 @@ import ( "github.com/linkedin/goavro/v2" "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/httputil" - "github.com/pingcap/ticdc/pkg/security" + "github.com/pingcap/tiflow/cdc/model" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/httputil" + "github.com/pingcap/tiflow/pkg/security" "go.uber.org/zap" ) diff --git a/cdc/sink/codec/schema_registry_test.go b/cdc/sink/codec/schema_registry_test.go index 1fe2395cc40..3b25e3fe67b 100644 --- a/cdc/sink/codec/schema_registry_test.go +++ b/cdc/sink/codec/schema_registry_test.go @@ -25,9 +25,9 @@ import ( "github.com/jarcoal/httpmock" "github.com/linkedin/goavro/v2" "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/security" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/security" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type AvroSchemaRegistrySuite struct{} diff --git a/cdc/sink/common/common.go b/cdc/sink/common/common.go index 844e2f0bedd..cf018a7c8b5 100644 --- a/cdc/sink/common/common.go +++ b/cdc/sink/common/common.go @@ -19,8 +19,8 @@ import ( "sync/atomic" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/filter" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/filter" "go.uber.org/zap" ) diff --git a/cdc/sink/common/common_test.go b/cdc/sink/common/common_test.go index 28a87086337..4cadba85e56 100644 --- a/cdc/sink/common/common_test.go +++ b/cdc/sink/common/common_test.go @@ -19,8 +19,8 @@ import ( "github.com/google/go-cmp/cmp" "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type SinkCommonSuite struct{} diff --git a/cdc/sink/common/flow_control.go b/cdc/sink/common/flow_control.go index a008d58b25a..9a13cc38389 100644 --- a/cdc/sink/common/flow_control.go +++ b/cdc/sink/common/flow_control.go @@ -20,7 +20,7 @@ import ( "github.com/edwingeng/deque" "github.com/pingcap/errors" "github.com/pingcap/log" - cerrors "github.com/pingcap/ticdc/pkg/errors" + cerrors "github.com/pingcap/tiflow/pkg/errors" "go.uber.org/zap" ) diff --git a/cdc/sink/common/flow_control_test.go b/cdc/sink/common/flow_control_test.go index 1b002f45000..d7c9dbefe26 100644 --- a/cdc/sink/common/flow_control_test.go +++ b/cdc/sink/common/flow_control_test.go @@ -22,7 +22,7 @@ import ( "time" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" "golang.org/x/sync/errgroup" ) diff --git a/cdc/sink/dispatcher/default.go b/cdc/sink/dispatcher/default.go index 741f0cad3f2..31d75eb0abd 100644 --- a/cdc/sink/dispatcher/default.go +++ b/cdc/sink/dispatcher/default.go @@ -14,7 +14,7 @@ package dispatcher import ( - "github.com/pingcap/ticdc/cdc/model" + "github.com/pingcap/tiflow/cdc/model" ) type defaultDispatcher struct { diff --git a/cdc/sink/dispatcher/default_test.go b/cdc/sink/dispatcher/default_test.go index eb2d13540e7..93fe3952af1 100644 --- a/cdc/sink/dispatcher/default_test.go +++ b/cdc/sink/dispatcher/default_test.go @@ -15,8 +15,8 @@ package dispatcher import ( "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type DefaultDispatcherSuite struct{} diff --git a/cdc/sink/dispatcher/dispatcher.go b/cdc/sink/dispatcher/dispatcher.go index 7d6f86873c3..6b4818295d1 100644 --- a/cdc/sink/dispatcher/dispatcher.go +++ b/cdc/sink/dispatcher/dispatcher.go @@ -17,10 +17,10 @@ import ( "strings" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - cerror "github.com/pingcap/ticdc/pkg/errors" filter "github.com/pingcap/tidb-tools/pkg/table-filter" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + cerror "github.com/pingcap/tiflow/pkg/errors" "go.uber.org/zap" ) diff --git a/cdc/sink/dispatcher/index_value.go b/cdc/sink/dispatcher/index_value.go index e9824fc2808..79913bc636c 100644 --- a/cdc/sink/dispatcher/index_value.go +++ b/cdc/sink/dispatcher/index_value.go @@ -14,8 +14,8 @@ package dispatcher import ( - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/hash" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/hash" ) type indexValueDispatcher struct { diff --git a/cdc/sink/dispatcher/index_value_test.go b/cdc/sink/dispatcher/index_value_test.go index cbbffbaca90..5f0890885c2 100644 --- a/cdc/sink/dispatcher/index_value_test.go +++ b/cdc/sink/dispatcher/index_value_test.go @@ -15,8 +15,8 @@ package dispatcher import ( "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type IndexValueDispatcherSuite struct{} diff --git a/cdc/sink/dispatcher/switcher_test.go b/cdc/sink/dispatcher/switcher_test.go index e6fc8d7c984..6f3caf20143 100644 --- a/cdc/sink/dispatcher/switcher_test.go +++ b/cdc/sink/dispatcher/switcher_test.go @@ -15,9 +15,9 @@ package dispatcher import ( "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type SwitcherSuite struct{} diff --git a/cdc/sink/dispatcher/table.go b/cdc/sink/dispatcher/table.go index 28d4c04d464..98617f7ce22 100644 --- a/cdc/sink/dispatcher/table.go +++ b/cdc/sink/dispatcher/table.go @@ -14,8 +14,8 @@ package dispatcher import ( - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/hash" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/hash" ) type tableDispatcher struct { diff --git a/cdc/sink/dispatcher/table_test.go b/cdc/sink/dispatcher/table_test.go index 5aeb9d80936..9b2f17c4108 100644 --- a/cdc/sink/dispatcher/table_test.go +++ b/cdc/sink/dispatcher/table_test.go @@ -15,8 +15,8 @@ package dispatcher import ( "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type TableDispatcherSuite struct{} diff --git a/cdc/sink/dispatcher/ts.go b/cdc/sink/dispatcher/ts.go index 06d1fb1634a..e061734d210 100644 --- a/cdc/sink/dispatcher/ts.go +++ b/cdc/sink/dispatcher/ts.go @@ -13,7 +13,7 @@ package dispatcher -import "github.com/pingcap/ticdc/cdc/model" +import "github.com/pingcap/tiflow/cdc/model" type tsDispatcher struct { partitionNum int32 diff --git a/cdc/sink/dispatcher/ts_test.go b/cdc/sink/dispatcher/ts_test.go index 31099f6067a..f4eac2471bb 100644 --- a/cdc/sink/dispatcher/ts_test.go +++ b/cdc/sink/dispatcher/ts_test.go @@ -17,8 +17,8 @@ import ( "testing" "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/util/testleak" ) func Test(t *testing.T) { check.TestingT(t) } diff --git a/cdc/sink/manager.go b/cdc/sink/manager.go index 6ef33f3a7de..7d2db9a212e 100644 --- a/cdc/sink/manager.go +++ b/cdc/sink/manager.go @@ -23,8 +23,8 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/util" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/util" "github.com/prometheus/client_golang/prometheus" "go.uber.org/zap" ) diff --git a/cdc/sink/manager_test.go b/cdc/sink/manager_test.go index 354b06563ae..002b476a452 100644 --- a/cdc/sink/manager_test.go +++ b/cdc/sink/manager_test.go @@ -25,8 +25,8 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type managerSuite struct{} @@ -249,7 +249,7 @@ func (s *managerSuite) TestManagerDestroyTableSink(c *check.C) { } // Run the benchmark -// go test -benchmem -run='^$' -bench '^(BenchmarkManagerFlushing)$' github.com/pingcap/ticdc/cdc/sink +// go test -benchmem -run='^$' -bench '^(BenchmarkManagerFlushing)$' github.com/pingcap/tiflow/cdc/sink func BenchmarkManagerFlushing(b *testing.B) { ctx, cancel := context.WithCancel(context.Background()) errCh := make(chan error, 16) diff --git a/cdc/sink/mq.go b/cdc/sink/mq.go index bdd1c2f00e9..fe69ff7c5f9 100644 --- a/cdc/sink/mq.go +++ b/cdc/sink/mq.go @@ -22,18 +22,18 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/sink/codec" - "github.com/pingcap/ticdc/cdc/sink/dispatcher" - "github.com/pingcap/ticdc/cdc/sink/producer" - "github.com/pingcap/ticdc/cdc/sink/producer/kafka" - "github.com/pingcap/ticdc/cdc/sink/producer/pulsar" - "github.com/pingcap/ticdc/pkg/config" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/filter" - "github.com/pingcap/ticdc/pkg/notify" - "github.com/pingcap/ticdc/pkg/security" - "github.com/pingcap/ticdc/pkg/util" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/sink/codec" + "github.com/pingcap/tiflow/cdc/sink/dispatcher" + "github.com/pingcap/tiflow/cdc/sink/producer" + "github.com/pingcap/tiflow/cdc/sink/producer/kafka" + "github.com/pingcap/tiflow/cdc/sink/producer/pulsar" + "github.com/pingcap/tiflow/pkg/config" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/filter" + "github.com/pingcap/tiflow/pkg/notify" + "github.com/pingcap/tiflow/pkg/security" + "github.com/pingcap/tiflow/pkg/util" "go.uber.org/zap" "golang.org/x/sync/errgroup" ) diff --git a/cdc/sink/mq_test.go b/cdc/sink/mq_test.go index 2e570ad2b75..c2e0959d6a4 100644 --- a/cdc/sink/mq_test.go +++ b/cdc/sink/mq_test.go @@ -19,16 +19,16 @@ import ( "net/url" "github.com/pingcap/failpoint" - "github.com/pingcap/ticdc/cdc/sink/codec" + "github.com/pingcap/tiflow/cdc/sink/codec" "github.com/Shopify/sarama" "github.com/pingcap/check" "github.com/pingcap/errors" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/filter" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/filter" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type mqSinkSuite struct{} @@ -63,9 +63,9 @@ func (s mqSinkSuite) TestKafkaSink(c *check.C) { opts := map[string]string{} errCh := make(chan error, 1) - c.Assert(failpoint.Enable("github.com/pingcap/ticdc/cdc/sink/producer/kafka/SkipTopicAutoCreate", "return(true)"), check.IsNil) + c.Assert(failpoint.Enable("github.com/pingcap/tiflow/cdc/sink/producer/kafka/SkipTopicAutoCreate", "return(true)"), check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/sink/producer/kafka/SkipTopicAutoCreate") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/sink/producer/kafka/SkipTopicAutoCreate") }() sink, err := newKafkaSaramaSink(ctx, sinkURI, fr, replicaConfig, opts, errCh) @@ -166,9 +166,9 @@ func (s mqSinkSuite) TestKafkaSinkFilter(c *check.C) { opts := map[string]string{} errCh := make(chan error, 1) - c.Assert(failpoint.Enable("github.com/pingcap/ticdc/cdc/sink/producer/kafka/SkipTopicAutoCreate", "return(true)"), check.IsNil) + c.Assert(failpoint.Enable("github.com/pingcap/tiflow/cdc/sink/producer/kafka/SkipTopicAutoCreate", "return(true)"), check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/sink/producer/kafka/SkipTopicAutoCreate") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/sink/producer/kafka/SkipTopicAutoCreate") }() sink, err := newKafkaSaramaSink(ctx, sinkURI, fr, replicaConfig, opts, errCh) @@ -209,7 +209,7 @@ func (s mqSinkSuite) TestPulsarSinkEncoderConfig(c *check.C) { ctx, cancel := context.WithCancel(context.Background()) defer cancel() - err := failpoint.Enable("github.com/pingcap/ticdc/cdc/sink/producer/pulsar/MockPulsar", "return(true)") + err := failpoint.Enable("github.com/pingcap/tiflow/cdc/sink/producer/pulsar/MockPulsar", "return(true)") c.Assert(err, check.IsNil) uri := "pulsar://127.0.0.1:1234/kafka-test?" + diff --git a/cdc/sink/mysql.go b/cdc/sink/mysql.go index c0b25f7c9b4..cda8b5eb5d6 100644 --- a/cdc/sink/mysql.go +++ b/cdc/sink/mysql.go @@ -31,21 +31,21 @@ import ( "github.com/pingcap/log" timodel "github.com/pingcap/parser/model" "github.com/pingcap/parser/mysql" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/sink/common" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/cyclic" - "github.com/pingcap/ticdc/pkg/cyclic/mark" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/filter" - tifilter "github.com/pingcap/ticdc/pkg/filter" - "github.com/pingcap/ticdc/pkg/notify" - "github.com/pingcap/ticdc/pkg/quotes" - "github.com/pingcap/ticdc/pkg/retry" - "github.com/pingcap/ticdc/pkg/security" - "github.com/pingcap/ticdc/pkg/util" tddl "github.com/pingcap/tidb/ddl" "github.com/pingcap/tidb/infoschema" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/sink/common" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/cyclic" + "github.com/pingcap/tiflow/pkg/cyclic/mark" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/filter" + tifilter "github.com/pingcap/tiflow/pkg/filter" + "github.com/pingcap/tiflow/pkg/notify" + "github.com/pingcap/tiflow/pkg/quotes" + "github.com/pingcap/tiflow/pkg/retry" + "github.com/pingcap/tiflow/pkg/security" + "github.com/pingcap/tiflow/pkg/util" "github.com/prometheus/client_golang/prometheus" "go.uber.org/zap" ) diff --git a/cdc/sink/mysql_test.go b/cdc/sink/mysql_test.go index 4c37ba5574f..813575396ee 100644 --- a/cdc/sink/mysql_test.go +++ b/cdc/sink/mysql_test.go @@ -33,16 +33,16 @@ import ( "github.com/pingcap/errors" timodel "github.com/pingcap/parser/model" "github.com/pingcap/parser/mysql" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/sink/common" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/cyclic/mark" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/filter" - "github.com/pingcap/ticdc/pkg/notify" - "github.com/pingcap/ticdc/pkg/retry" - "github.com/pingcap/ticdc/pkg/util/testleak" "github.com/pingcap/tidb/infoschema" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/sink/common" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/cyclic/mark" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/filter" + "github.com/pingcap/tiflow/pkg/notify" + "github.com/pingcap/tiflow/pkg/retry" + "github.com/pingcap/tiflow/pkg/util/testleak" "golang.org/x/sync/errgroup" ) diff --git a/cdc/sink/producer/kafka/kafka.go b/cdc/sink/producer/kafka/kafka.go index c23e0de1ee7..7741e0de24e 100644 --- a/cdc/sink/producer/kafka/kafka.go +++ b/cdc/sink/producer/kafka/kafka.go @@ -28,12 +28,12 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/sink/codec" - "github.com/pingcap/ticdc/pkg/config" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/notify" - "github.com/pingcap/ticdc/pkg/security" - "github.com/pingcap/ticdc/pkg/util" + "github.com/pingcap/tiflow/cdc/sink/codec" + "github.com/pingcap/tiflow/pkg/config" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/notify" + "github.com/pingcap/tiflow/pkg/security" + "github.com/pingcap/tiflow/pkg/util" "go.uber.org/zap" ) @@ -599,7 +599,7 @@ func newSaramaConfig(ctx context.Context, c *Config) (*sarama.Config, error) { // Metadata.Retry.Backoff * Metadata.Retry.Max` // to fail. // See: https://github.com/Shopify/sarama/issues/765 - // and https://github.com/pingcap/ticdc/issues/3352. + // and https://github.com/pingcap/tiflow/issues/3352. config.Metadata.Timeout = 1 * time.Minute config.Producer.Partitioner = sarama.NewManualPartitioner diff --git a/cdc/sink/producer/kafka/kafka_test.go b/cdc/sink/producer/kafka/kafka_test.go index 3e3d5a095dc..b0226b58bad 100644 --- a/cdc/sink/producer/kafka/kafka_test.go +++ b/cdc/sink/producer/kafka/kafka_test.go @@ -26,12 +26,12 @@ import ( "github.com/pingcap/check" "github.com/pingcap/errors" "github.com/pingcap/failpoint" - "github.com/pingcap/ticdc/cdc/sink/codec" - "github.com/pingcap/ticdc/pkg/config" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/security" - "github.com/pingcap/ticdc/pkg/util" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/sink/codec" + "github.com/pingcap/tiflow/pkg/config" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/security" + "github.com/pingcap/tiflow/pkg/util" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type kafkaSuite struct{} @@ -146,10 +146,10 @@ func (s *kafkaSuite) TestSaramaProducer(c *check.C) { cfg.Producer.Flush.MaxMessages = 1 return cfg, err } - c.Assert(failpoint.Enable("github.com/pingcap/ticdc/cdc/sink/producer/kafka/SkipTopicAutoCreate", "return(true)"), check.IsNil) + c.Assert(failpoint.Enable("github.com/pingcap/tiflow/cdc/sink/producer/kafka/SkipTopicAutoCreate", "return(true)"), check.IsNil) defer func() { newSaramaConfigImpl = newSaramaConfigImplBak - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/sink/producer/kafka/SkipTopicAutoCreate") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/sink/producer/kafka/SkipTopicAutoCreate") }() producer, err := NewKafkaSaramaProducer(ctx, topic, codec.ProtocolDefault, config, errCh) @@ -347,10 +347,10 @@ func (s *kafkaSuite) TestCreateProducerFailed(c *check.C) { config.Version = "invalid" config.BrokerEndpoints = []string{"127.0.0.1:1111"} topic := "topic" - c.Assert(failpoint.Enable("github.com/pingcap/ticdc/cdc/sink/producer/kafka/SkipTopicAutoCreate", "return(true)"), check.IsNil) + c.Assert(failpoint.Enable("github.com/pingcap/tiflow/cdc/sink/producer/kafka/SkipTopicAutoCreate", "return(true)"), check.IsNil) _, err := NewKafkaSaramaProducer(ctx, topic, codec.ProtocolDefault, config, errCh) c.Assert(errors.Cause(err), check.ErrorMatches, "invalid version.*") - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/sink/producer/kafka/SkipTopicAutoCreate") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/sink/producer/kafka/SkipTopicAutoCreate") } func (s *kafkaSuite) TestProducerSendMessageFailed(c *check.C) { @@ -377,7 +377,7 @@ func (s *kafkaSuite) TestProducerSendMessageFailed(c *check.C) { config.AutoCreate = false config.BrokerEndpoints = strings.Split(leader.Addr(), ",") - c.Assert(failpoint.Enable("github.com/pingcap/ticdc/cdc/sink/producer/kafka/SkipTopicAutoCreate", "return(true)"), check.IsNil) + c.Assert(failpoint.Enable("github.com/pingcap/tiflow/cdc/sink/producer/kafka/SkipTopicAutoCreate", "return(true)"), check.IsNil) newSaramaConfigImplBak := newSaramaConfigImpl newSaramaConfigImpl = func(ctx context.Context, config *Config) (*sarama.Config, error) { @@ -395,7 +395,7 @@ func (s *kafkaSuite) TestProducerSendMessageFailed(c *check.C) { errCh := make(chan error, 1) producer, err := NewKafkaSaramaProducer(ctx, topic, codec.ProtocolDefault, config, errCh) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/sink/producer/kafka/SkipTopicAutoCreate") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/sink/producer/kafka/SkipTopicAutoCreate") err := producer.Close() c.Assert(err, check.IsNil) }() @@ -455,14 +455,14 @@ func (s *kafkaSuite) TestProducerDoubleClose(c *check.C) { config.AutoCreate = false config.BrokerEndpoints = strings.Split(leader.Addr(), ",") - c.Assert(failpoint.Enable("github.com/pingcap/ticdc/cdc/sink/producer/kafka/SkipTopicAutoCreate", "return(true)"), check.IsNil) + c.Assert(failpoint.Enable("github.com/pingcap/tiflow/cdc/sink/producer/kafka/SkipTopicAutoCreate", "return(true)"), check.IsNil) errCh := make(chan error, 1) producer, err := NewKafkaSaramaProducer(ctx, topic, codec.ProtocolDefault, config, errCh) defer func() { err := producer.Close() c.Assert(err, check.IsNil) - _ = failpoint.Disable("github.com/pingcap/ticdc/cdc/sink/producer/kafka/SkipTopicAutoCreate") + _ = failpoint.Disable("github.com/pingcap/tiflow/cdc/sink/producer/kafka/SkipTopicAutoCreate") }() c.Assert(err, check.IsNil) diff --git a/cdc/sink/producer/mq_producer.go b/cdc/sink/producer/mq_producer.go index 380065b679b..7e9664f61ed 100644 --- a/cdc/sink/producer/mq_producer.go +++ b/cdc/sink/producer/mq_producer.go @@ -16,7 +16,7 @@ package producer import ( "context" - "github.com/pingcap/ticdc/cdc/sink/codec" + "github.com/pingcap/tiflow/cdc/sink/codec" ) // Producer is an interface of mq producer diff --git a/cdc/sink/producer/pulsar/producer.go b/cdc/sink/producer/pulsar/producer.go index 26cb6c3485a..bf9664d2dce 100644 --- a/cdc/sink/producer/pulsar/producer.go +++ b/cdc/sink/producer/pulsar/producer.go @@ -21,8 +21,8 @@ import ( "github.com/apache/pulsar-client-go/pulsar" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/sink/codec" - cerror "github.com/pingcap/ticdc/pkg/errors" + "github.com/pingcap/tiflow/cdc/sink/codec" + cerror "github.com/pingcap/tiflow/pkg/errors" "go.uber.org/zap" ) diff --git a/cdc/sink/simple_mysql_tester.go b/cdc/sink/simple_mysql_tester.go index 3b3d7edc885..2bb46c14bb9 100644 --- a/cdc/sink/simple_mysql_tester.go +++ b/cdc/sink/simple_mysql_tester.go @@ -25,11 +25,11 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/filter" - "github.com/pingcap/ticdc/pkg/quotes" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/filter" + "github.com/pingcap/tiflow/pkg/quotes" "go.uber.org/zap" ) diff --git a/cdc/sink/sink.go b/cdc/sink/sink.go index 12a381d0f9f..f27e13b6c0c 100644 --- a/cdc/sink/sink.go +++ b/cdc/sink/sink.go @@ -18,11 +18,11 @@ import ( "net/url" "strings" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/sink/cdclog" - "github.com/pingcap/ticdc/pkg/config" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/filter" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/sink/cdclog" + "github.com/pingcap/tiflow/pkg/config" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/filter" ) // Sink options keys diff --git a/cdc/sink/statistics.go b/cdc/sink/statistics.go index b09a8c988c1..26c1bad7fb4 100644 --- a/cdc/sink/statistics.go +++ b/cdc/sink/statistics.go @@ -19,7 +19,7 @@ import ( "time" "github.com/pingcap/log" - "github.com/pingcap/ticdc/pkg/util" + "github.com/pingcap/tiflow/pkg/util" "github.com/prometheus/client_golang/prometheus" "go.uber.org/zap" ) diff --git a/cdc/sink/syncpointStore.go b/cdc/sink/syncpointStore.go index d20cb5e5960..230993ffbae 100644 --- a/cdc/sink/syncpointStore.go +++ b/cdc/sink/syncpointStore.go @@ -18,8 +18,8 @@ import ( "net/url" "strings" - "github.com/pingcap/ticdc/cdc/model" - cerror "github.com/pingcap/ticdc/pkg/errors" + "github.com/pingcap/tiflow/cdc/model" + cerror "github.com/pingcap/tiflow/pkg/errors" ) // SyncpointStore is an abstraction for anything that a changefeed may emit into. diff --git a/cdc/sink/txns_heap.go b/cdc/sink/txns_heap.go index a514a05dd38..16dd48e53bb 100644 --- a/cdc/sink/txns_heap.go +++ b/cdc/sink/txns_heap.go @@ -16,7 +16,7 @@ package sink import ( "container/heap" - "github.com/pingcap/ticdc/cdc/model" + "github.com/pingcap/tiflow/cdc/model" ) type innerTxnsHeap []innerHeapEntry diff --git a/cdc/sink/txns_heap_test.go b/cdc/sink/txns_heap_test.go index b488260419c..7084dc8ea47 100644 --- a/cdc/sink/txns_heap_test.go +++ b/cdc/sink/txns_heap_test.go @@ -15,8 +15,8 @@ package sink import ( "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type TxnsHeapSuite struct{} diff --git a/cdc/task.go b/cdc/task.go index 239ccfd46b4..efd27618294 100644 --- a/cdc/task.go +++ b/cdc/task.go @@ -18,8 +18,8 @@ import ( "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - cerror "github.com/pingcap/ticdc/pkg/errors" + "github.com/pingcap/tiflow/cdc/model" + cerror "github.com/pingcap/tiflow/pkg/errors" "go.etcd.io/etcd/clientv3" "go.etcd.io/etcd/mvcc" "go.uber.org/zap" diff --git a/cdc/task_test.go b/cdc/task_test.go index 1dabb53da32..caba59d7fa1 100644 --- a/cdc/task_test.go +++ b/cdc/task_test.go @@ -20,11 +20,11 @@ import ( "github.com/pingcap/check" "github.com/pingcap/failpoint" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/etcd" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/etcd" + "github.com/pingcap/tiflow/pkg/util/testleak" "go.etcd.io/etcd/clientv3" "go.etcd.io/etcd/embed" ) @@ -182,7 +182,7 @@ func (s *taskSuite) TestWatch(c *check.C) { ch := s.w.Watch(context.Background()) // Trigger the ErrCompacted error - c.Assert(failpoint.Enable("github.com/pingcap/ticdc/cdc.restart_task_watch", "50%off"), check.IsNil) + c.Assert(failpoint.Enable("github.com/pingcap/tiflow/cdc.restart_task_watch", "50%off"), check.IsNil) // Put task changefeed-1 c.Assert(client.PutTaskStatus(s.c.Ctx(), "changefeed-1", diff --git a/cmd/cdc/main.go b/cmd/cdc/main.go index 372eb3a1fc2..c31d34d73cb 100644 --- a/cmd/cdc/main.go +++ b/cmd/cdc/main.go @@ -14,8 +14,8 @@ package main import ( - "github.com/pingcap/ticdc/cmd" _ "github.com/pingcap/tidb/types/parser_driver" + "github.com/pingcap/tiflow/cmd" ) func main() { diff --git a/cmd/client.go b/cmd/client.go index adde9942846..6c0f20a4cd4 100644 --- a/cmd/client.go +++ b/cmd/client.go @@ -25,11 +25,11 @@ import ( _ "github.com/go-sql-driver/mysql" // mysql driver "github.com/mattn/go-shellwords" "github.com/pingcap/errors" - "github.com/pingcap/ticdc/cdc" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/logutil" - "github.com/pingcap/ticdc/pkg/version" + "github.com/pingcap/tiflow/cdc" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/logutil" + "github.com/pingcap/tiflow/pkg/version" "github.com/spf13/cobra" pd "github.com/tikv/pd/client" "go.etcd.io/etcd/clientv3" diff --git a/cmd/client_changefeed.go b/cmd/client_changefeed.go index 563eb4e3d26..351d3159163 100644 --- a/cmd/client_changefeed.go +++ b/cmd/client_changefeed.go @@ -25,16 +25,16 @@ import ( "github.com/google/uuid" "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/cyclic" - "github.com/pingcap/ticdc/pkg/cyclic/mark" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/security" - "github.com/pingcap/ticdc/pkg/util" - "github.com/pingcap/ticdc/pkg/version" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/cdc" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/cyclic" + "github.com/pingcap/tiflow/pkg/cyclic/mark" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/security" + "github.com/pingcap/tiflow/pkg/util" + "github.com/pingcap/tiflow/pkg/version" "github.com/r3labs/diff" "github.com/spf13/cobra" "github.com/spf13/pflag" diff --git a/cmd/client_changefeed_test.go b/cmd/client_changefeed_test.go index 864e07c6821..4d58b738990 100644 --- a/cmd/client_changefeed_test.go +++ b/cmd/client_changefeed_test.go @@ -19,7 +19,7 @@ import ( "path/filepath" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" "github.com/spf13/cobra" ) diff --git a/cmd/client_processor.go b/cmd/client_processor.go index fbc889225eb..95d71ef1b7a 100644 --- a/cmd/client_processor.go +++ b/cmd/client_processor.go @@ -15,7 +15,7 @@ package cmd import ( _ "github.com/go-sql-driver/mysql" // mysql driver - cerror "github.com/pingcap/ticdc/pkg/errors" + cerror "github.com/pingcap/tiflow/pkg/errors" "github.com/spf13/cobra" ) diff --git a/cmd/client_unsafe.go b/cmd/client_unsafe.go index 62020a85110..34dd2c6c640 100644 --- a/cmd/client_unsafe.go +++ b/cmd/client_unsafe.go @@ -18,7 +18,7 @@ import ( "strings" "github.com/pingcap/errors" - "github.com/pingcap/ticdc/cdc" + "github.com/pingcap/tiflow/cdc" "github.com/spf13/cobra" ) diff --git a/cmd/cmd_test.go b/cmd/cmd_test.go index 804058c3980..03c17131170 100644 --- a/cmd/cmd_test.go +++ b/cmd/cmd_test.go @@ -22,9 +22,9 @@ import ( "github.com/pingcap/check" "github.com/pingcap/parser/model" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/util/testleak" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/util/testleak" "github.com/spf13/cobra" pd "github.com/tikv/pd/client" ) diff --git a/cmd/kafka-consumer/main.go b/cmd/kafka-consumer/main.go index 3d00ca88ac5..1518d636b65 100644 --- a/cmd/kafka-consumer/main.go +++ b/cmd/kafka-consumer/main.go @@ -32,15 +32,15 @@ import ( "github.com/google/uuid" "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/sink" - "github.com/pingcap/ticdc/cdc/sink/codec" - "github.com/pingcap/ticdc/pkg/config" - cdcfilter "github.com/pingcap/ticdc/pkg/filter" - "github.com/pingcap/ticdc/pkg/logutil" - "github.com/pingcap/ticdc/pkg/quotes" - "github.com/pingcap/ticdc/pkg/security" - "github.com/pingcap/ticdc/pkg/util" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/sink" + "github.com/pingcap/tiflow/cdc/sink/codec" + "github.com/pingcap/tiflow/pkg/config" + cdcfilter "github.com/pingcap/tiflow/pkg/filter" + "github.com/pingcap/tiflow/pkg/logutil" + "github.com/pingcap/tiflow/pkg/quotes" + "github.com/pingcap/tiflow/pkg/security" + "github.com/pingcap/tiflow/pkg/util" "go.uber.org/zap" ) diff --git a/cmd/server.go b/cmd/server.go index 12632754ebc..96e2e2b4ea8 100644 --- a/cmd/server.go +++ b/cmd/server.go @@ -22,14 +22,14 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc" - "github.com/pingcap/ticdc/cdc/puller/sorter" - "github.com/pingcap/ticdc/pkg/config" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/logutil" - "github.com/pingcap/ticdc/pkg/util" - "github.com/pingcap/ticdc/pkg/version" ticonfig "github.com/pingcap/tidb/config" + "github.com/pingcap/tiflow/cdc" + "github.com/pingcap/tiflow/cdc/puller/sorter" + "github.com/pingcap/tiflow/pkg/config" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/logutil" + "github.com/pingcap/tiflow/pkg/util" + "github.com/pingcap/tiflow/pkg/version" "github.com/spf13/cobra" "github.com/spf13/pflag" "go.uber.org/zap" diff --git a/cmd/server_test.go b/cmd/server_test.go index 34c6444dbf3..31cedbd9cca 100644 --- a/cmd/server_test.go +++ b/cmd/server_test.go @@ -20,9 +20,9 @@ import ( "time" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/util/testleak" ticonfig "github.com/pingcap/tidb/config" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/util/testleak" "github.com/spf13/cobra" ) diff --git a/cmd/test.go b/cmd/test.go index 71ed91b2339..6d75c0f9df9 100644 --- a/cmd/test.go +++ b/cmd/test.go @@ -18,7 +18,7 @@ import ( "os" "strings" - "github.com/pingcap/ticdc/cdc/kv" + "github.com/pingcap/tiflow/cdc/kv" "github.com/spf13/cobra" pd "github.com/tikv/pd/client" ) diff --git a/cmd/util.go b/cmd/util.go index 6de001d7dfd..9bd69a030a8 100644 --- a/cmd/util.go +++ b/cmd/util.go @@ -31,18 +31,18 @@ import ( "github.com/BurntSushi/toml" "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc" - "github.com/pingcap/ticdc/cdc/entry" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/sink" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/filter" - "github.com/pingcap/ticdc/pkg/httputil" - "github.com/pingcap/ticdc/pkg/logutil" - "github.com/pingcap/ticdc/pkg/security" - "github.com/pingcap/ticdc/pkg/util" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/cdc" + "github.com/pingcap/tiflow/cdc/entry" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/sink" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/filter" + "github.com/pingcap/tiflow/pkg/httputil" + "github.com/pingcap/tiflow/pkg/logutil" + "github.com/pingcap/tiflow/pkg/security" + "github.com/pingcap/tiflow/pkg/util" "github.com/spf13/cobra" "github.com/spf13/pflag" "go.etcd.io/etcd/clientv3/concurrency" diff --git a/cmd/util_test.go b/cmd/util_test.go index 1fc25d17320..531c9d5ee9b 100644 --- a/cmd/util_test.go +++ b/cmd/util_test.go @@ -17,7 +17,7 @@ import ( "os" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type utilsSuite struct{} diff --git a/cmd/version.go b/cmd/version.go index 0bb98bc48b9..bb34afa25c5 100644 --- a/cmd/version.go +++ b/cmd/version.go @@ -16,7 +16,7 @@ package cmd import ( "fmt" - "github.com/pingcap/ticdc/pkg/version" + "github.com/pingcap/tiflow/pkg/version" "github.com/spf13/cobra" ) diff --git a/demo/java/README.md b/demo/java/README.md index cd545586d8f..db3761851c2 100644 --- a/demo/java/README.md +++ b/demo/java/README.md @@ -26,7 +26,7 @@ for (KafkaMessage kafkaMessage : kafkaMessages) { } ``` -[See com.pingcap.ticdc.cdc.TicdcEventDecoderTest.](src/test/java/com/pingcap/ticdc/cdc/TicdcEventDecoderTest.java). +[See com.pingcap.ticdc.cdc.TicdcEventDecoderTest.](src/test/java/com/pingcap/tiflow/cdc/TicdcEventDecoderTest.java). # How to install Prerequisites for building: @@ -36,7 +36,7 @@ Prerequisites for building: * Java 8 ``` -git clone git@github.com:pingcap/ticdc.git +git clone git@github.com:pingcap/tiflow.git cd ticdc/demo/java mvn install ``` diff --git a/docs/design/2020-03-25-ticdc-high-availability-new-design-cn.md b/docs/design/2020-03-25-ticdc-high-availability-new-design-cn.md index 20e0e3c74ac..20535a3eeb0 100644 --- a/docs/design/2020-03-25-ticdc-high-availability-new-design-cn.md +++ b/docs/design/2020-03-25-ticdc-high-availability-new-design-cn.md @@ -13,7 +13,7 @@ TiCDC 高可用是指任何一个 cdc 节点挂掉,都不影响集群整体的 本文总结已有代码发现的一些问题,并给出解决方案。 -> 注意,本文分析代码基于 [v4.0.0-beta.2](https://github.com/pingcap/ticdc/tree/v4.0.0-beta.2) 版本 +> 注意,本文分析代码基于 [v4.0.0-beta.2](https://github.com/pingcap/tiflow/tree/v4.0.0-beta.2) 版本 ## 问题 @@ -21,9 +21,9 @@ TiCDC 高可用是指任何一个 cdc 节点挂掉,都不影响集群整体的 一个 Session 是指节点与 etcd 之间维持的一种保持连接的状态。Session 中含有 Lease,并在节点存活期间保持心跳。节点挂掉后,Session 失效,与其中 Lease 关联的 Key 都被删除。这常用来服务发现中对服务节点是否存活的标识。 -起初,Capture 并没有使用 Session,而是仅仅在竞选 Owner 的时候创建了 Session。这样导致 Capture 挂掉后,其注册信息是无法被清理的。Capture 节点挂掉后(非正常退出),其负责的任务没有及时重新分配。这个问题在 PR [Refactor/capture watcher](https://github.com/pingcap/ticdc/pull/319) 中解决。 +起初,Capture 并没有使用 Session,而是仅仅在竞选 Owner 的时候创建了 Session。这样导致 Capture 挂掉后,其注册信息是无法被清理的。Capture 节点挂掉后(非正常退出),其负责的任务没有及时重新分配。这个问题在 PR [Refactor/capture watcher](https://github.com/pingcap/tiflow/pull/319) 中解决。 -另外,为了减少 RTO,我们引入了 Processor 的 Session,用来及时发现挂掉的 Processor。PR:[Reduce the RTO by watching the liveness of processors](https://github.com/pingcap/ticdc/pull/312) +另外,为了减少 RTO,我们引入了 Processor 的 Session,用来及时发现挂掉的 Processor。PR:[Reduce the RTO by watching the liveness of processors](https://github.com/pingcap/tiflow/pull/312) 因此,我们目前有三个 Session,一个是 Capture Session,用来维持 Capture 存活信息,一个是 Processor Session,用来维护 Processor 存活信息,还有一个是原来存在的 Manager Session,用来竞选 Owner。 diff --git a/go.mod b/go.mod index 3329722d423..0ffa6d75cba 100644 --- a/go.mod +++ b/go.mod @@ -1,4 +1,4 @@ -module github.com/pingcap/ticdc +module github.com/pingcap/tiflow go 1.13 diff --git a/integration/framework/avro/kafka_docker_env.go b/integration/framework/avro/kafka_docker_env.go index 86b83d85c6f..66bf8c9caa6 100644 --- a/integration/framework/avro/kafka_docker_env.go +++ b/integration/framework/avro/kafka_docker_env.go @@ -22,7 +22,7 @@ import ( "github.com/integralist/go-findroot/find" "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/integration/framework" + "github.com/pingcap/tiflow/integration/framework" "go.uber.org/zap" ) diff --git a/integration/framework/avro/kafka_docker_env_test.go b/integration/framework/avro/kafka_docker_env_test.go index f6bf90755db..2662a55a3b9 100644 --- a/integration/framework/avro/kafka_docker_env_test.go +++ b/integration/framework/avro/kafka_docker_env_test.go @@ -18,7 +18,7 @@ import ( "testing" "github.com/pingcap/log" - "github.com/pingcap/ticdc/integration/framework" + "github.com/pingcap/tiflow/integration/framework" "github.com/stretchr/testify/require" ) diff --git a/integration/framework/avro/kafka_single_table.go b/integration/framework/avro/kafka_single_table.go index 5395d674195..893f6411890 100644 --- a/integration/framework/avro/kafka_single_table.go +++ b/integration/framework/avro/kafka_single_table.go @@ -25,7 +25,7 @@ import ( "github.com/pingcap/log" "go.uber.org/zap" - "github.com/pingcap/ticdc/integration/framework" + "github.com/pingcap/tiflow/integration/framework" ) // SingleTableTask provides a basic implementation for an Avro test case diff --git a/integration/framework/avro/kafka_single_table_test.go b/integration/framework/avro/kafka_single_table_test.go index bc09561e820..7d4f266e790 100644 --- a/integration/framework/avro/kafka_single_table_test.go +++ b/integration/framework/avro/kafka_single_table_test.go @@ -17,7 +17,7 @@ import ( "database/sql" "testing" - "github.com/pingcap/ticdc/integration/framework" + "github.com/pingcap/tiflow/integration/framework" "github.com/stretchr/testify/require" ) diff --git a/integration/framework/canal/kafka_docker_env.go b/integration/framework/canal/kafka_docker_env.go index 9ee233fc28b..2e3071d60d9 100644 --- a/integration/framework/canal/kafka_docker_env.go +++ b/integration/framework/canal/kafka_docker_env.go @@ -21,7 +21,7 @@ import ( "github.com/integralist/go-findroot/find" "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/integration/framework" + "github.com/pingcap/tiflow/integration/framework" "go.uber.org/zap" ) diff --git a/integration/framework/canal/kafka_docker_env_test.go b/integration/framework/canal/kafka_docker_env_test.go index 57d7b340355..e150076feaa 100644 --- a/integration/framework/canal/kafka_docker_env_test.go +++ b/integration/framework/canal/kafka_docker_env_test.go @@ -18,7 +18,7 @@ import ( "testing" "github.com/pingcap/log" - "github.com/pingcap/ticdc/integration/framework" + "github.com/pingcap/tiflow/integration/framework" "github.com/stretchr/testify/require" ) diff --git a/integration/framework/canal/kafka_single_table.go b/integration/framework/canal/kafka_single_table.go index ad15240af15..c7c256a7efc 100644 --- a/integration/framework/canal/kafka_single_table.go +++ b/integration/framework/canal/kafka_single_table.go @@ -18,7 +18,7 @@ import ( "time" "github.com/pingcap/log" - "github.com/pingcap/ticdc/integration/framework" + "github.com/pingcap/tiflow/integration/framework" ) const ( diff --git a/integration/framework/canal/kafka_single_table_test.go b/integration/framework/canal/kafka_single_table_test.go index 91a96e67d7a..ed999aac93f 100644 --- a/integration/framework/canal/kafka_single_table_test.go +++ b/integration/framework/canal/kafka_single_table_test.go @@ -17,7 +17,7 @@ import ( "database/sql" "testing" - "github.com/pingcap/ticdc/integration/framework" + "github.com/pingcap/tiflow/integration/framework" "github.com/stretchr/testify/require" ) diff --git a/integration/framework/docker_compose_op.go b/integration/framework/docker_compose_op.go index 986b93a3c07..b448d4a5012 100644 --- a/integration/framework/docker_compose_op.go +++ b/integration/framework/docker_compose_op.go @@ -20,8 +20,8 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - cerrors "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/retry" + cerrors "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/retry" "go.uber.org/zap" "golang.org/x/net/context" ) diff --git a/integration/framework/docker_env.go b/integration/framework/docker_env.go index efb0402ce43..f9dae318f58 100644 --- a/integration/framework/docker_env.go +++ b/integration/framework/docker_env.go @@ -21,8 +21,8 @@ import ( "time" "github.com/pingcap/log" - cerrors "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/retry" + cerrors "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/retry" "go.uber.org/zap" ) diff --git a/integration/framework/mysql/docker_env.go b/integration/framework/mysql/docker_env.go index 63c6a7065a7..2cc5f9d9278 100644 --- a/integration/framework/mysql/docker_env.go +++ b/integration/framework/mysql/docker_env.go @@ -19,7 +19,7 @@ import ( "github.com/integralist/go-findroot/find" "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/integration/framework" + "github.com/pingcap/tiflow/integration/framework" "go.uber.org/zap" ) diff --git a/integration/framework/mysql/docker_env_test.go b/integration/framework/mysql/docker_env_test.go index 3ae307821c3..e99b0271190 100644 --- a/integration/framework/mysql/docker_env_test.go +++ b/integration/framework/mysql/docker_env_test.go @@ -18,7 +18,7 @@ import ( "testing" "github.com/pingcap/log" - "github.com/pingcap/ticdc/integration/framework" + "github.com/pingcap/tiflow/integration/framework" "github.com/stretchr/testify/require" ) diff --git a/integration/framework/mysql/single_table.go b/integration/framework/mysql/single_table.go index 3f6addc0b95..dc1ef419c49 100644 --- a/integration/framework/mysql/single_table.go +++ b/integration/framework/mysql/single_table.go @@ -18,7 +18,7 @@ import ( "time" "github.com/pingcap/log" - "github.com/pingcap/ticdc/integration/framework" + "github.com/pingcap/tiflow/integration/framework" ) const ( diff --git a/integration/framework/mysql/single_table_test.go b/integration/framework/mysql/single_table_test.go index ef1f8b8c19d..188f4e95ed0 100644 --- a/integration/framework/mysql/single_table_test.go +++ b/integration/framework/mysql/single_table_test.go @@ -17,7 +17,7 @@ import ( "database/sql" "testing" - "github.com/pingcap/ticdc/integration/framework" + "github.com/pingcap/tiflow/integration/framework" "github.com/stretchr/testify/require" ) diff --git a/integration/framework/sql_helper.go b/integration/framework/sql_helper.go index 2769c03c7d0..69a087110b1 100644 --- a/integration/framework/sql_helper.go +++ b/integration/framework/sql_helper.go @@ -24,7 +24,7 @@ import ( "github.com/jmoiron/sqlx" "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/pkg/quotes" + "github.com/pingcap/tiflow/pkg/quotes" "go.uber.org/zap" "go.uber.org/zap/zapcore" "upper.io/db.v3/lib/sqlbuilder" diff --git a/integration/integration.go b/integration/integration.go index 11e6a13cb0a..e7c0e2f8cc8 100644 --- a/integration/integration.go +++ b/integration/integration.go @@ -17,11 +17,11 @@ import ( "flag" "github.com/pingcap/log" - "github.com/pingcap/ticdc/integration/framework" - "github.com/pingcap/ticdc/integration/framework/avro" - "github.com/pingcap/ticdc/integration/framework/canal" - "github.com/pingcap/ticdc/integration/framework/mysql" - "github.com/pingcap/ticdc/integration/tests" + "github.com/pingcap/tiflow/integration/framework" + "github.com/pingcap/tiflow/integration/framework/avro" + "github.com/pingcap/tiflow/integration/framework/canal" + "github.com/pingcap/tiflow/integration/framework/mysql" + "github.com/pingcap/tiflow/integration/tests" "go.uber.org/zap" "go.uber.org/zap/zapcore" ) @@ -97,7 +97,7 @@ func testMySQL() { func testMySQLWithCheckingOldvValue() { env := mysql.NewDockerEnv(*dockerComposeFile) - env.DockerComposeOperator.ExecEnv = []string{"GO_FAILPOINTS=github.com/pingcap/ticdc/cdc/sink/SimpleMySQLSinkTester=return(ture)"} + env.DockerComposeOperator.ExecEnv = []string{"GO_FAILPOINTS=github.com/pingcap/tiflow/cdc/sink/SimpleMySQLSinkTester=return(ture)"} task := &mysql.SingleTableTask{TableName: "test", CheckOleValue: true} testCases := []framework.Task{ tests.NewSimpleCase(task), diff --git a/integration/tests/case_alter.go b/integration/tests/case_alter.go index 4dc972c88aa..34819c227c2 100644 --- a/integration/tests/case_alter.go +++ b/integration/tests/case_alter.go @@ -18,7 +18,7 @@ import ( "math/rand" "github.com/pingcap/errors" - "github.com/pingcap/ticdc/integration/framework" + "github.com/pingcap/tiflow/integration/framework" ) // AlterCase is base impl of test case for alter operation diff --git a/integration/tests/case_composite_pkey.go b/integration/tests/case_composite_pkey.go index a969b47f4cd..b0252f8b5e0 100644 --- a/integration/tests/case_composite_pkey.go +++ b/integration/tests/case_composite_pkey.go @@ -15,7 +15,7 @@ package tests import ( "github.com/pingcap/errors" - "github.com/pingcap/ticdc/integration/framework" + "github.com/pingcap/tiflow/integration/framework" ) // CompositePKeyCase is base impl of test case for composite primary keys diff --git a/integration/tests/case_date_time.go b/integration/tests/case_date_time.go index ac060b94036..a278a9a4965 100644 --- a/integration/tests/case_date_time.go +++ b/integration/tests/case_date_time.go @@ -18,10 +18,10 @@ import ( "time" "github.com/pingcap/log" - "github.com/pingcap/ticdc/integration/framework" - "github.com/pingcap/ticdc/integration/framework/avro" - "github.com/pingcap/ticdc/integration/framework/canal" - "github.com/pingcap/ticdc/integration/framework/mysql" + "github.com/pingcap/tiflow/integration/framework" + "github.com/pingcap/tiflow/integration/framework/avro" + "github.com/pingcap/tiflow/integration/framework/canal" + "github.com/pingcap/tiflow/integration/framework/mysql" ) // DateTimeCase is base impl of test case for different types data diff --git a/integration/tests/case_delete.go b/integration/tests/case_delete.go index e301abb3325..b48a2ea8ed2 100644 --- a/integration/tests/case_delete.go +++ b/integration/tests/case_delete.go @@ -17,7 +17,7 @@ import ( "errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/integration/framework" + "github.com/pingcap/tiflow/integration/framework" "go.uber.org/zap" ) diff --git a/integration/tests/case_many_types.go b/integration/tests/case_many_types.go index bcca8313891..5af2a25e815 100644 --- a/integration/tests/case_many_types.go +++ b/integration/tests/case_many_types.go @@ -18,10 +18,10 @@ import ( "math" "time" - "github.com/pingcap/ticdc/integration/framework" - "github.com/pingcap/ticdc/integration/framework/avro" - "github.com/pingcap/ticdc/integration/framework/canal" - "github.com/pingcap/ticdc/integration/framework/mysql" + "github.com/pingcap/tiflow/integration/framework" + "github.com/pingcap/tiflow/integration/framework/avro" + "github.com/pingcap/tiflow/integration/framework/canal" + "github.com/pingcap/tiflow/integration/framework/mysql" ) // ManyTypesCase is base impl of test case for different types data diff --git a/integration/tests/case_simple.go b/integration/tests/case_simple.go index dc78560020b..834a3233d5f 100644 --- a/integration/tests/case_simple.go +++ b/integration/tests/case_simple.go @@ -15,7 +15,7 @@ package tests import ( "github.com/pingcap/errors" - "github.com/pingcap/ticdc/integration/framework" + "github.com/pingcap/tiflow/integration/framework" ) // SimpleCase is base impl of simple test case diff --git a/integration/tests/case_unsigned.go b/integration/tests/case_unsigned.go index 79660403ca0..7978678a5a5 100644 --- a/integration/tests/case_unsigned.go +++ b/integration/tests/case_unsigned.go @@ -14,7 +14,7 @@ package tests import ( - "github.com/pingcap/ticdc/integration/framework" + "github.com/pingcap/tiflow/integration/framework" ) // UnsignedCase is base impl of test case for unsigned int type data diff --git a/kafka_consumer/Dockerfile b/kafka_consumer/Dockerfile index 4eb646c42c7..d19b51b6007 100644 --- a/kafka_consumer/Dockerfile +++ b/kafka_consumer/Dockerfile @@ -1,9 +1,9 @@ FROM golang:1.13 as builder -WORKDIR /go/src/github.com/pingcap/ticdc +WORKDIR /go/src/github.com/pingcap/tiflow COPY . . RUN go mod download RUN make kafka_consumer FROM alpine:3.11 -COPY --from=builder /go/src/github.com/pingcap/ticdc/bin/cdc_kafka_consumer /cdc_kafka_consumer +COPY --from=builder /go/src/github.com/pingcap/tiflow/bin/cdc_kafka_consumer /cdc_kafka_consumer CMD [ "/cdc_kafka_consumer" ] diff --git a/pkg/config/config.go b/pkg/config/config.go index 2352526306e..9a508907fa8 100644 --- a/pkg/config/config.go +++ b/pkg/config/config.go @@ -23,9 +23,9 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/pkg/config/outdated" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/security" + "github.com/pingcap/tiflow/pkg/config/outdated" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/security" "go.uber.org/zap" ) diff --git a/pkg/config/config_test.go b/pkg/config/config_test.go index a53328ce9d5..d0f2a0cc42a 100644 --- a/pkg/config/config_test.go +++ b/pkg/config/config_test.go @@ -17,7 +17,7 @@ import ( "testing" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) func Test(t *testing.T) { check.TestingT(t) } diff --git a/pkg/config/sorter.go b/pkg/config/sorter.go index 7ddef8b9218..8639dcc313b 100644 --- a/pkg/config/sorter.go +++ b/pkg/config/sorter.go @@ -13,7 +13,7 @@ package config -import cerror "github.com/pingcap/ticdc/pkg/errors" +import cerror "github.com/pingcap/tiflow/pkg/errors" // SorterConfig represents sorter config for a changefeed type SorterConfig struct { diff --git a/pkg/context/context.go b/pkg/context/context.go index 843d91ce7a9..d7b2a9f286e 100644 --- a/pkg/context/context.go +++ b/pkg/context/context.go @@ -18,13 +18,13 @@ import ( "time" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/pdtime" - "github.com/pingcap/ticdc/pkg/version" tidbkv "github.com/pingcap/tidb/kv" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/pdtime" + "github.com/pingcap/tiflow/pkg/version" pd "github.com/tikv/pd/client" "go.uber.org/zap" ) diff --git a/pkg/context/context_test.go b/pkg/context/context_test.go index b0caee01c3f..a0ae1a782e6 100644 --- a/pkg/context/context_test.go +++ b/pkg/context/context_test.go @@ -20,9 +20,9 @@ import ( "github.com/pingcap/check" "github.com/pingcap/errors" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/util/testleak" ) func TestSuite(t *testing.T) { check.TestingT(t) } diff --git a/pkg/cyclic/filter.go b/pkg/cyclic/filter.go index 94b866e2590..d33634699f7 100644 --- a/pkg/cyclic/filter.go +++ b/pkg/cyclic/filter.go @@ -15,8 +15,8 @@ package cyclic import ( "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/cyclic/mark" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/cyclic/mark" "go.uber.org/zap" ) diff --git a/pkg/cyclic/filter_test.go b/pkg/cyclic/filter_test.go index 4d3bdb550d1..f20811d7ef5 100644 --- a/pkg/cyclic/filter_test.go +++ b/pkg/cyclic/filter_test.go @@ -18,9 +18,9 @@ import ( "github.com/davecgh/go-spew/spew" "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/cyclic/mark" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/cyclic/mark" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type markSuite struct{} diff --git a/pkg/cyclic/mark/mark.go b/pkg/cyclic/mark/mark.go index aa39ddaa259..6a027d04f10 100644 --- a/pkg/cyclic/mark/mark.go +++ b/pkg/cyclic/mark/mark.go @@ -22,9 +22,9 @@ import ( "github.com/go-sql-driver/mysql" "github.com/pingcap/errors" "github.com/pingcap/log" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/quotes" - "github.com/pingcap/ticdc/pkg/security" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/quotes" + "github.com/pingcap/tiflow/pkg/security" "go.uber.org/zap" ) diff --git a/pkg/cyclic/mark/mark_test.go b/pkg/cyclic/mark/mark_test.go index cdbb66c8d9e..89f75c28685 100644 --- a/pkg/cyclic/mark/mark_test.go +++ b/pkg/cyclic/mark/mark_test.go @@ -17,7 +17,7 @@ import ( "testing" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type markSuite struct{} diff --git a/pkg/cyclic/replication.go b/pkg/cyclic/replication.go index 1c8f3dedfbb..7392f3c3add 100644 --- a/pkg/cyclic/replication.go +++ b/pkg/cyclic/replication.go @@ -23,10 +23,10 @@ import ( "fmt" "strings" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/cyclic/mark" - "github.com/pingcap/ticdc/pkg/quotes" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/cyclic/mark" + "github.com/pingcap/tiflow/pkg/quotes" ) // RelaxSQLMode returns relaxed SQL mode, "STRICT_TRANS_TABLES" is removed. diff --git a/pkg/cyclic/replication_test.go b/pkg/cyclic/replication_test.go index 71d6668590e..aec74535151 100644 --- a/pkg/cyclic/replication_test.go +++ b/pkg/cyclic/replication_test.go @@ -17,10 +17,10 @@ import ( "testing" "github.com/pingcap/check" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/cyclic/mark" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/cyclic/mark" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type cyclicSuite struct{} diff --git a/pkg/errors/helper_test.go b/pkg/errors/helper_test.go index f2f9d478fbd..1f398abf831 100644 --- a/pkg/errors/helper_test.go +++ b/pkg/errors/helper_test.go @@ -19,7 +19,7 @@ import ( "github.com/pingcap/check" "github.com/pingcap/errors" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) func TestSuite(t *testing.T) { diff --git a/pkg/etcd/client.go b/pkg/etcd/client.go index 94a693da8d0..23a0e219a58 100644 --- a/pkg/etcd/client.go +++ b/pkg/etcd/client.go @@ -18,8 +18,8 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - cerrors "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/retry" + cerrors "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/retry" "github.com/prometheus/client_golang/prometheus" "go.etcd.io/etcd/clientv3" "go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes" diff --git a/pkg/etcd/client_test.go b/pkg/etcd/client_test.go index dd310bad3ec..fbc9b3268b9 100644 --- a/pkg/etcd/client_test.go +++ b/pkg/etcd/client_test.go @@ -19,7 +19,7 @@ import ( "github.com/pingcap/check" "github.com/pingcap/errors" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" "go.etcd.io/etcd/clientv3" ) diff --git a/pkg/etcd/etcd_test.go b/pkg/etcd/etcd_test.go index c414e3a6238..0edcf44a9c1 100644 --- a/pkg/etcd/etcd_test.go +++ b/pkg/etcd/etcd_test.go @@ -20,7 +20,7 @@ import ( "time" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" "go.etcd.io/etcd/clientv3" "go.etcd.io/etcd/embed" ) diff --git a/pkg/etcd/etcdkey.go b/pkg/etcd/etcdkey.go index ca7ac9cfe15..ad1975a309f 100644 --- a/pkg/etcd/etcdkey.go +++ b/pkg/etcd/etcdkey.go @@ -17,7 +17,7 @@ import ( "strings" "github.com/pingcap/log" - cerror "github.com/pingcap/ticdc/pkg/errors" + cerror "github.com/pingcap/tiflow/pkg/errors" ) const ( diff --git a/pkg/etcd/etcdkey_test.go b/pkg/etcd/etcdkey_test.go index ba137f96f46..3c754638749 100644 --- a/pkg/etcd/etcdkey_test.go +++ b/pkg/etcd/etcdkey_test.go @@ -15,7 +15,7 @@ package etcd import ( "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type etcdkeySuite struct{} diff --git a/pkg/filelock/filelock.go b/pkg/filelock/filelock.go index 9f9630b6fc4..51dffa5a003 100644 --- a/pkg/filelock/filelock.go +++ b/pkg/filelock/filelock.go @@ -18,7 +18,7 @@ import ( "syscall" "github.com/pingcap/errors" - cerrors "github.com/pingcap/ticdc/pkg/errors" + cerrors "github.com/pingcap/tiflow/pkg/errors" ) // FileLock represents a file lock created by `flock`. diff --git a/pkg/filelock/filelock_test.go b/pkg/filelock/filelock_test.go index e414580b6cb..b4a033858ea 100644 --- a/pkg/filelock/filelock_test.go +++ b/pkg/filelock/filelock_test.go @@ -17,7 +17,7 @@ import ( "testing" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type fileLockSuite struct{} diff --git a/pkg/filter/filter.go b/pkg/filter/filter.go index b5b7f5843d4..32d45942175 100644 --- a/pkg/filter/filter.go +++ b/pkg/filter/filter.go @@ -15,11 +15,11 @@ package filter import ( "github.com/pingcap/parser/model" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/cyclic/mark" - cerror "github.com/pingcap/ticdc/pkg/errors" filterV1 "github.com/pingcap/tidb-tools/pkg/filter" filterV2 "github.com/pingcap/tidb-tools/pkg/table-filter" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/cyclic/mark" + cerror "github.com/pingcap/tiflow/pkg/errors" ) // Filter is a event filter implementation. diff --git a/pkg/filter/filter_test.go b/pkg/filter/filter_test.go index 63cf425f074..8408413031a 100644 --- a/pkg/filter/filter_test.go +++ b/pkg/filter/filter_test.go @@ -16,8 +16,8 @@ package filter import ( "testing" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/util/testleak" "github.com/pingcap/check" "github.com/pingcap/parser/model" diff --git a/pkg/flags/urls.go b/pkg/flags/urls.go index 2cbd26cdc5e..912e745a344 100644 --- a/pkg/flags/urls.go +++ b/pkg/flags/urls.go @@ -17,7 +17,7 @@ import ( "strings" "github.com/pingcap/errors" - "github.com/pingcap/ticdc/pkg/types" + "github.com/pingcap/tiflow/pkg/types" ) // URLsValue define a slice of URLs as a type diff --git a/pkg/flags/urls_test.go b/pkg/flags/urls_test.go index 382a10e46ab..a715bc8dfa6 100644 --- a/pkg/flags/urls_test.go +++ b/pkg/flags/urls_test.go @@ -17,7 +17,7 @@ import ( "testing" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) func Test(t *testing.T) { diff --git a/pkg/httputil/httputil.go b/pkg/httputil/httputil.go index 8d6e98b1654..a212b7a6802 100644 --- a/pkg/httputil/httputil.go +++ b/pkg/httputil/httputil.go @@ -16,8 +16,8 @@ package httputil import ( "net/http" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/security" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/security" ) // Client wraps an HTTP client and support TLS requests. diff --git a/pkg/httputil/httputil_test.go b/pkg/httputil/httputil_test.go index c1149b49495..12f3af46c5e 100644 --- a/pkg/httputil/httputil_test.go +++ b/pkg/httputil/httputil_test.go @@ -25,9 +25,9 @@ import ( "testing" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/security" - "github.com/pingcap/ticdc/pkg/util/testleak" "github.com/pingcap/tidb-tools/pkg/utils" + "github.com/pingcap/tiflow/pkg/security" + "github.com/pingcap/tiflow/pkg/util/testleak" ) func Test(t *testing.T) { check.TestingT(t) } diff --git a/pkg/logutil/log.go b/pkg/logutil/log.go index 7790a2090a8..4daa3eb8f54 100644 --- a/pkg/logutil/log.go +++ b/pkg/logutil/log.go @@ -194,8 +194,8 @@ func initGRPCLogger(level zapcore.Level) error { logger := log.L().With(zap.String("name", "grpc")) // For gRPC 1.26.0, logging call stack: // - // github.com/pingcap/ticdc/pkg/util.levelToFunc.func1 - // github.com/pingcap/ticdc/pkg/util.(*grpcLoggerWriter).Write + // github.com/pingcap/tiflow/pkg/util.levelToFunc.func1 + // github.com/pingcap/tiflow/pkg/util.(*grpcLoggerWriter).Write // log.(*Logger).Output // log.(*Logger).Printf // google.golang.org/grpc/grpclog.(*loggerT).Infof diff --git a/pkg/logutil/log_test.go b/pkg/logutil/log_test.go index 3d41eea5bed..22acf2d4eb9 100644 --- a/pkg/logutil/log_test.go +++ b/pkg/logutil/log_test.go @@ -21,7 +21,7 @@ import ( "github.com/pingcap/check" "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" "go.uber.org/zap" "go.uber.org/zap/zapcore" ) diff --git a/pkg/notify/notify.go b/pkg/notify/notify.go index 477aa67d0cd..5b58a6759c6 100644 --- a/pkg/notify/notify.go +++ b/pkg/notify/notify.go @@ -17,7 +17,7 @@ import ( "sync" "time" - "github.com/pingcap/ticdc/pkg/errors" + "github.com/pingcap/tiflow/pkg/errors" ) // Notifier provides a one-to-many notification mechanism diff --git a/pkg/notify/notify_test.go b/pkg/notify/notify_test.go index e2517988f8e..f6b3c6078be 100644 --- a/pkg/notify/notify_test.go +++ b/pkg/notify/notify_test.go @@ -19,8 +19,8 @@ import ( "time" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/util/testleak" ) func Test(t *testing.T) { diff --git a/pkg/orchestrator/batch.go b/pkg/orchestrator/batch.go index fec17080a3c..3bc98706167 100644 --- a/pkg/orchestrator/batch.go +++ b/pkg/orchestrator/batch.go @@ -15,8 +15,8 @@ package orchestrator import ( "github.com/pingcap/errors" - cerrors "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/orchestrator/util" + cerrors "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/orchestrator/util" ) const ( diff --git a/pkg/orchestrator/batch_test.go b/pkg/orchestrator/batch_test.go index 9a7267a6f9d..95a7721872f 100644 --- a/pkg/orchestrator/batch_test.go +++ b/pkg/orchestrator/batch_test.go @@ -17,7 +17,7 @@ import ( "fmt" "testing" - "github.com/pingcap/ticdc/pkg/orchestrator/util" + "github.com/pingcap/tiflow/pkg/orchestrator/util" "github.com/stretchr/testify/require" ) diff --git a/pkg/orchestrator/etcd_worker.go b/pkg/orchestrator/etcd_worker.go index acccfbdb21e..cb721f94041 100644 --- a/pkg/orchestrator/etcd_worker.go +++ b/pkg/orchestrator/etcd_worker.go @@ -21,9 +21,9 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - cerrors "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/etcd" - "github.com/pingcap/ticdc/pkg/orchestrator/util" + cerrors "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/etcd" + "github.com/pingcap/tiflow/pkg/orchestrator/util" "github.com/prometheus/client_golang/prometheus" "go.etcd.io/etcd/clientv3" "go.etcd.io/etcd/clientv3/concurrency" diff --git a/pkg/orchestrator/etcd_worker_bank_test.go b/pkg/orchestrator/etcd_worker_bank_test.go index 8785115ec31..5f4c766138f 100644 --- a/pkg/orchestrator/etcd_worker_bank_test.go +++ b/pkg/orchestrator/etcd_worker_bank_test.go @@ -24,9 +24,9 @@ import ( "github.com/pingcap/check" "github.com/pingcap/log" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/orchestrator/util" - "github.com/pingcap/ticdc/pkg/util/testleak" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/orchestrator/util" + "github.com/pingcap/tiflow/pkg/util/testleak" "go.uber.org/zap" ) diff --git a/pkg/orchestrator/etcd_worker_test.go b/pkg/orchestrator/etcd_worker_test.go index 65bfc26a8d8..d7715eb8d0b 100644 --- a/pkg/orchestrator/etcd_worker_test.go +++ b/pkg/orchestrator/etcd_worker_test.go @@ -26,10 +26,10 @@ import ( "github.com/pingcap/check" "github.com/pingcap/errors" "github.com/pingcap/log" - cerrors "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/etcd" - "github.com/pingcap/ticdc/pkg/orchestrator/util" - "github.com/pingcap/ticdc/pkg/util/testleak" + cerrors "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/etcd" + "github.com/pingcap/tiflow/pkg/orchestrator/util" + "github.com/pingcap/tiflow/pkg/util/testleak" "github.com/prometheus/client_golang/prometheus" "go.etcd.io/etcd/clientv3" "go.uber.org/zap" diff --git a/pkg/orchestrator/interfaces.go b/pkg/orchestrator/interfaces.go index cf29860a471..5e74fab592b 100644 --- a/pkg/orchestrator/interfaces.go +++ b/pkg/orchestrator/interfaces.go @@ -16,7 +16,7 @@ package orchestrator import ( "context" - "github.com/pingcap/ticdc/pkg/orchestrator/util" + "github.com/pingcap/tiflow/pkg/orchestrator/util" ) // Reactor is a stateful transform of states. diff --git a/pkg/orchestrator/reactor_state_tester.go b/pkg/orchestrator/reactor_state_tester.go index 5149cd34097..72b5f5e2c0a 100644 --- a/pkg/orchestrator/reactor_state_tester.go +++ b/pkg/orchestrator/reactor_state_tester.go @@ -16,8 +16,8 @@ package orchestrator import ( "github.com/pingcap/check" "github.com/pingcap/errors" - cerrors "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/orchestrator/util" + cerrors "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/orchestrator/util" ) // ReactorStateTester is a helper struct for unit-testing an implementer of ReactorState diff --git a/pkg/orchestrator/util/key_utils_test.go b/pkg/orchestrator/util/key_utils_test.go index baa74594819..d84e3304382 100644 --- a/pkg/orchestrator/util/key_utils_test.go +++ b/pkg/orchestrator/util/key_utils_test.go @@ -17,7 +17,7 @@ import ( "testing" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) func Test(t *testing.T) { check.TestingT(t) } diff --git a/pkg/pdtime/acquirer.go b/pkg/pdtime/acquirer.go index 49b1fda81c6..003b334db62 100644 --- a/pkg/pdtime/acquirer.go +++ b/pkg/pdtime/acquirer.go @@ -20,8 +20,8 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/pkg/retry" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/pkg/retry" pd "github.com/tikv/pd/client" "go.uber.org/zap" ) diff --git a/pkg/pdtime/acquirer_test.go b/pkg/pdtime/acquirer_test.go index 8e9e89fcc31..cf8cd7fc3bb 100644 --- a/pkg/pdtime/acquirer_test.go +++ b/pkg/pdtime/acquirer_test.go @@ -19,7 +19,7 @@ import ( "time" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" "github.com/pingcap/tidb/store/tikv/oracle" pd "github.com/tikv/pd/client" diff --git a/pkg/pipeline/context.go b/pkg/pipeline/context.go index f3de42a1e74..49b3214adb7 100644 --- a/pkg/pipeline/context.go +++ b/pkg/pipeline/context.go @@ -13,7 +13,7 @@ package pipeline -import "github.com/pingcap/ticdc/pkg/context" +import "github.com/pingcap/tiflow/pkg/context" // NodeContext adds two functions from `coutext.Context` and created by pipeline type NodeContext interface { diff --git a/pkg/pipeline/message.go b/pkg/pipeline/message.go index 37d26a9ddbb..c7602fe3fab 100644 --- a/pkg/pipeline/message.go +++ b/pkg/pipeline/message.go @@ -13,7 +13,7 @@ package pipeline -import "github.com/pingcap/ticdc/cdc/model" +import "github.com/pingcap/tiflow/cdc/model" // MessageType is the type of Message type MessageType int diff --git a/pkg/pipeline/pipeline.go b/pkg/pipeline/pipeline.go index ead3f445b22..2155984d373 100644 --- a/pkg/pipeline/pipeline.go +++ b/pkg/pipeline/pipeline.go @@ -19,8 +19,8 @@ import ( "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/pkg/context" - cerror "github.com/pingcap/ticdc/pkg/errors" + "github.com/pingcap/tiflow/pkg/context" + cerror "github.com/pingcap/tiflow/pkg/errors" "go.uber.org/zap" ) diff --git a/pkg/pipeline/pipeline_test.go b/pkg/pipeline/pipeline_test.go index 55a94eb8395..0a4e8039dd0 100644 --- a/pkg/pipeline/pipeline_test.go +++ b/pkg/pipeline/pipeline_test.go @@ -22,10 +22,10 @@ import ( "github.com/pingcap/check" "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/context" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/context" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/util/testleak" "go.uber.org/zap" ) @@ -498,7 +498,7 @@ func (n *forward) Destroy(ctx NodeContext) error { } // Run the benchmark -// go test -benchmem -run='^$' -bench '^(BenchmarkPipeline)$' github.com/pingcap/ticdc/pkg/pipeline +// go test -benchmem -run='^$' -bench '^(BenchmarkPipeline)$' github.com/pingcap/tiflow/pkg/pipeline func BenchmarkPipeline(b *testing.B) { ctx := context.NewContext(stdCtx.Background(), &context.GlobalVars{}) runnersSize, outputChannelSize := 2, 64 diff --git a/pkg/pipeline/runner.go b/pkg/pipeline/runner.go index 8e7858582f5..8288b8c9ed9 100644 --- a/pkg/pipeline/runner.go +++ b/pkg/pipeline/runner.go @@ -18,7 +18,7 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/pkg/context" + "github.com/pingcap/tiflow/pkg/context" "go.uber.org/zap" ) diff --git a/pkg/pipeline/test.go b/pkg/pipeline/test.go index 60d0ab73d02..bfc25ac69b8 100644 --- a/pkg/pipeline/test.go +++ b/pkg/pipeline/test.go @@ -13,7 +13,7 @@ package pipeline -import "github.com/pingcap/ticdc/pkg/context" +import "github.com/pingcap/tiflow/pkg/context" // SendMessageToNode4Test sends messages to specified `Node` through `Receive` in order. // This function is only for testing. diff --git a/pkg/quotes/quotes_test.go b/pkg/quotes/quotes_test.go index 82afd8bef16..ce411377553 100644 --- a/pkg/quotes/quotes_test.go +++ b/pkg/quotes/quotes_test.go @@ -17,7 +17,7 @@ import ( "testing" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) func Test(t *testing.T) { check.TestingT(t) } diff --git a/pkg/regionspan/region_range_lock_test.go b/pkg/regionspan/region_range_lock_test.go index aca0c3007bd..e2737e8b5cb 100644 --- a/pkg/regionspan/region_range_lock_test.go +++ b/pkg/regionspan/region_range_lock_test.go @@ -19,7 +19,7 @@ import ( "time" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type regionRangeLockSuite struct{} diff --git a/pkg/regionspan/region_test.go b/pkg/regionspan/region_test.go index ca1336519f2..1784240ad95 100644 --- a/pkg/regionspan/region_test.go +++ b/pkg/regionspan/region_test.go @@ -16,7 +16,7 @@ package regionspan import ( "github.com/pingcap/check" "github.com/pingcap/kvproto/pkg/metapb" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type regionSuite struct{} diff --git a/pkg/regionspan/span.go b/pkg/regionspan/span.go index 79fcb5eef7e..ed1dc39cf0c 100644 --- a/pkg/regionspan/span.go +++ b/pkg/regionspan/span.go @@ -19,10 +19,10 @@ import ( "fmt" "github.com/pingcap/log" - cerror "github.com/pingcap/ticdc/pkg/errors" "github.com/pingcap/tidb/kv" "github.com/pingcap/tidb/tablecodec" "github.com/pingcap/tidb/util/codec" + cerror "github.com/pingcap/tiflow/pkg/errors" "go.uber.org/zap" ) diff --git a/pkg/regionspan/span_test.go b/pkg/regionspan/span_test.go index 46940795816..215ba7819d1 100644 --- a/pkg/regionspan/span_test.go +++ b/pkg/regionspan/span_test.go @@ -17,8 +17,8 @@ import ( "testing" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" "github.com/pingcap/tidb/tablecodec" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type spanSuite struct{} diff --git a/pkg/retry/retry_test.go b/pkg/retry/retry_test.go index 96a8e72cd3e..375cc1380c4 100644 --- a/pkg/retry/retry_test.go +++ b/pkg/retry/retry_test.go @@ -21,7 +21,7 @@ import ( "github.com/pingcap/check" "github.com/pingcap/errors" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) func Test(t *testing.T) { check.TestingT(t) } diff --git a/pkg/retry/retry_with_opt.go b/pkg/retry/retry_with_opt.go index 7bf666777b1..c5482ebe130 100644 --- a/pkg/retry/retry_with_opt.go +++ b/pkg/retry/retry_with_opt.go @@ -20,7 +20,7 @@ import ( "time" "github.com/pingcap/errors" - cerror "github.com/pingcap/ticdc/pkg/errors" + cerror "github.com/pingcap/tiflow/pkg/errors" ) // Operation is the action need to retry diff --git a/pkg/scheduler/interface.go b/pkg/scheduler/interface.go index b3c83188bc2..c444f1ca0ae 100644 --- a/pkg/scheduler/interface.go +++ b/pkg/scheduler/interface.go @@ -15,7 +15,7 @@ package scheduler import ( "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" + "github.com/pingcap/tiflow/cdc/model" ) // Scheduler is an abstraction for anything that provide the schedule table feature diff --git a/pkg/scheduler/table_number.go b/pkg/scheduler/table_number.go index 99ae38c5f18..7bfe59b9ace 100644 --- a/pkg/scheduler/table_number.go +++ b/pkg/scheduler/table_number.go @@ -13,7 +13,7 @@ package scheduler -import "github.com/pingcap/ticdc/cdc/model" +import "github.com/pingcap/tiflow/cdc/model" // TableNumberScheduler provides a feature that scheduling by the table number type TableNumberScheduler struct { diff --git a/pkg/scheduler/table_number_test.go b/pkg/scheduler/table_number_test.go index 94ce5bc3364..f790a26cae7 100644 --- a/pkg/scheduler/table_number_test.go +++ b/pkg/scheduler/table_number_test.go @@ -16,8 +16,8 @@ package scheduler import ( "fmt" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/util/testleak" "github.com/pingcap/check" ) diff --git a/pkg/scheduler/workload.go b/pkg/scheduler/workload.go index ce84e22369b..a340d8db55b 100644 --- a/pkg/scheduler/workload.go +++ b/pkg/scheduler/workload.go @@ -16,7 +16,7 @@ package scheduler import ( "math" - "github.com/pingcap/ticdc/cdc/model" + "github.com/pingcap/tiflow/cdc/model" ) type workloads map[model.CaptureID]model.TaskWorkload diff --git a/pkg/scheduler/workload_test.go b/pkg/scheduler/workload_test.go index 791d89b5b3c..59f3794ab15 100644 --- a/pkg/scheduler/workload_test.go +++ b/pkg/scheduler/workload_test.go @@ -17,8 +17,8 @@ import ( "fmt" "testing" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/util/testleak" "github.com/pingcap/check" ) diff --git a/pkg/security/credential.go b/pkg/security/credential.go index b7e6bce19f4..9a284b4dd24 100644 --- a/pkg/security/credential.go +++ b/pkg/security/credential.go @@ -16,8 +16,8 @@ package security import ( "crypto/tls" - cerror "github.com/pingcap/ticdc/pkg/errors" "github.com/pingcap/tidb-tools/pkg/utils" + cerror "github.com/pingcap/tiflow/pkg/errors" pd "github.com/tikv/pd/client" "google.golang.org/grpc" "google.golang.org/grpc/credentials" diff --git a/pkg/txnutil/gc/gc_manager.go b/pkg/txnutil/gc/gc_manager.go index 5a7afb0709d..30968b8c153 100644 --- a/pkg/txnutil/gc/gc_manager.go +++ b/pkg/txnutil/gc/gc_manager.go @@ -20,11 +20,11 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/config" - cdcContext "github.com/pingcap/ticdc/pkg/context" - cerror "github.com/pingcap/ticdc/pkg/errors" "github.com/pingcap/tidb/store/tikv/oracle" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/config" + cdcContext "github.com/pingcap/tiflow/pkg/context" + cerror "github.com/pingcap/tiflow/pkg/errors" pd "github.com/tikv/pd/client" "go.uber.org/zap" ) diff --git a/pkg/txnutil/gc/gc_manager_test.go b/pkg/txnutil/gc/gc_manager_test.go index 29fdf8f81ae..abec30e14dc 100644 --- a/pkg/txnutil/gc/gc_manager_test.go +++ b/pkg/txnutil/gc/gc_manager_test.go @@ -20,11 +20,11 @@ import ( "github.com/pingcap/check" "github.com/pingcap/errors" - cdcContext "github.com/pingcap/ticdc/pkg/context" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/pdtime" - "github.com/pingcap/ticdc/pkg/util/testleak" "github.com/pingcap/tidb/store/tikv/oracle" + cdcContext "github.com/pingcap/tiflow/pkg/context" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/pdtime" + "github.com/pingcap/tiflow/pkg/util/testleak" ) func Test(t *testing.T) { diff --git a/pkg/txnutil/gc/gc_service.go b/pkg/txnutil/gc/gc_service.go index 56f51ee3d24..85e21d91909 100644 --- a/pkg/txnutil/gc/gc_service.go +++ b/pkg/txnutil/gc/gc_service.go @@ -19,8 +19,8 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - cerrors "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/retry" + cerrors "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/retry" pd "github.com/tikv/pd/client" "go.uber.org/zap" ) diff --git a/pkg/txnutil/gc/gc_service_test.go b/pkg/txnutil/gc/gc_service_test.go index ccd78237c81..70c38a56ac4 100644 --- a/pkg/txnutil/gc/gc_service_test.go +++ b/pkg/txnutil/gc/gc_service_test.go @@ -19,7 +19,7 @@ import ( "github.com/pingcap/check" "github.com/pingcap/errors" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" pd "github.com/tikv/pd/client" ) diff --git a/pkg/types/urls.go b/pkg/types/urls.go index 824e4ceadd9..b1d02927917 100644 --- a/pkg/types/urls.go +++ b/pkg/types/urls.go @@ -20,7 +20,7 @@ import ( "strings" "github.com/pingcap/errors" - cerror "github.com/pingcap/ticdc/pkg/errors" + cerror "github.com/pingcap/tiflow/pkg/errors" ) // URLs defines a slice of URLs as a type diff --git a/pkg/types/urls_test.go b/pkg/types/urls_test.go index 0adbc8c86e5..6fe6bd1c326 100644 --- a/pkg/types/urls_test.go +++ b/pkg/types/urls_test.go @@ -18,7 +18,7 @@ import ( "testing" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) func Test(t *testing.T) { diff --git a/pkg/util/bitflag_test.go b/pkg/util/bitflag_test.go index e2a86b3ce99..b0308c32608 100644 --- a/pkg/util/bitflag_test.go +++ b/pkg/util/bitflag_test.go @@ -15,7 +15,7 @@ package util import ( "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) const ( diff --git a/pkg/util/ctx_test.go b/pkg/util/ctx_test.go index 43315677c72..699be03e05e 100644 --- a/pkg/util/ctx_test.go +++ b/pkg/util/ctx_test.go @@ -17,7 +17,7 @@ import ( "context" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" "go.uber.org/zap" ) diff --git a/pkg/util/fileutil.go b/pkg/util/fileutil.go index 4b734e88de3..5ce00bbd531 100644 --- a/pkg/util/fileutil.go +++ b/pkg/util/fileutil.go @@ -23,8 +23,8 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/pkg/config" - cerror "github.com/pingcap/ticdc/pkg/errors" + "github.com/pingcap/tiflow/pkg/config" + cerror "github.com/pingcap/tiflow/pkg/errors" ) const ( diff --git a/pkg/util/fileutil_test.go b/pkg/util/fileutil_test.go index e498107d962..00e54ac297c 100644 --- a/pkg/util/fileutil_test.go +++ b/pkg/util/fileutil_test.go @@ -22,8 +22,8 @@ import ( "github.com/pingcap/check" "github.com/pingcap/failpoint" - "github.com/pingcap/ticdc/pkg/config" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/config" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type fileUtilSuite struct{} @@ -98,8 +98,8 @@ func (s *fileUtilSuite) TestCheckDataDirSatisfied(c *check.C) { conf.DataDir = dir config.StoreGlobalServerConfig(conf) - c.Assert(failpoint.Enable("github.com/pingcap/ticdc/pkg/util/InjectCheckDataDirSatisfied", ""), check.IsNil) + c.Assert(failpoint.Enable("github.com/pingcap/tiflow/pkg/util/InjectCheckDataDirSatisfied", ""), check.IsNil) err := CheckDataDirSatisfied() c.Assert(err, check.IsNil) - c.Assert(failpoint.Disable("github.com/pingcap/ticdc/pkg/util/InjectCheckDataDirSatisfied"), check.IsNil) + c.Assert(failpoint.Disable("github.com/pingcap/tiflow/pkg/util/InjectCheckDataDirSatisfied"), check.IsNil) } diff --git a/pkg/util/gc_service.go b/pkg/util/gc_service.go index e18db32caa0..03edc4de865 100644 --- a/pkg/util/gc_service.go +++ b/pkg/util/gc_service.go @@ -18,8 +18,8 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - cerrors "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/retry" + cerrors "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/retry" pd "github.com/tikv/pd/client" "go.uber.org/zap" ) diff --git a/pkg/util/gc_service_test.go b/pkg/util/gc_service_test.go index 015fb584566..6ae26b73f45 100644 --- a/pkg/util/gc_service_test.go +++ b/pkg/util/gc_service_test.go @@ -19,7 +19,7 @@ import ( "github.com/pingcap/check" "github.com/pingcap/errors" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" pd "github.com/tikv/pd/client" ) diff --git a/pkg/util/overlap_merge_test.go b/pkg/util/overlap_merge_test.go index 5c84674718d..db8f329cf03 100644 --- a/pkg/util/overlap_merge_test.go +++ b/pkg/util/overlap_merge_test.go @@ -18,7 +18,7 @@ import ( "fmt" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type overlapSuite struct{} diff --git a/pkg/util/test_helper_test.go b/pkg/util/test_helper_test.go index 5b78d437dc2..07f9307c3fb 100644 --- a/pkg/util/test_helper_test.go +++ b/pkg/util/test_helper_test.go @@ -21,7 +21,7 @@ import ( "time" "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) func Test(t *testing.T) { diff --git a/pkg/util/testleak/leaktest.go b/pkg/util/testleak/leaktest.go index 513eb1fede4..251feb1bf18 100644 --- a/pkg/util/testleak/leaktest.go +++ b/pkg/util/testleak/leaktest.go @@ -53,11 +53,11 @@ func interestingGoroutines() (gs []string) { // library used by sarama, ref: https://github.com/rcrowley/go-metrics/pull/266 "github.com/rcrowley/go-metrics.(*meterArbiter).tick", // TODO: remove these two lines after unified sorter is fixed - "github.com/pingcap/ticdc/cdc/puller/sorter.newBackEndPool", - "github.com/pingcap/ticdc/cdc/puller/sorter.(*heapSorter).flush", + "github.com/pingcap/tiflow/cdc/puller/sorter.newBackEndPool", + "github.com/pingcap/tiflow/cdc/puller/sorter.(*heapSorter).flush", // kv client region worker pool - "github.com/pingcap/ticdc/cdc/kv.RunWorkerPool", - "github.com/pingcap/ticdc/pkg/workerpool.(*defaultPoolImpl).Run", + "github.com/pingcap/tiflow/cdc/kv.RunWorkerPool", + "github.com/pingcap/tiflow/pkg/workerpool.(*defaultPoolImpl).Run", } shouldIgnore := func(stack string) bool { if stack == "" { diff --git a/pkg/util/tz.go b/pkg/util/tz.go index 632e9810860..726c08ee7e5 100644 --- a/pkg/util/tz.go +++ b/pkg/util/tz.go @@ -19,7 +19,7 @@ import ( "strings" "time" - cerror "github.com/pingcap/ticdc/pkg/errors" + cerror "github.com/pingcap/tiflow/pkg/errors" ) // GetTimezone returns the timezone specified by the name diff --git a/pkg/util/tz_test.go b/pkg/util/tz_test.go index aa25a33c285..885b3fa1404 100644 --- a/pkg/util/tz_test.go +++ b/pkg/util/tz_test.go @@ -15,7 +15,7 @@ package util import ( "github.com/pingcap/check" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" ) type tzSuite struct{} diff --git a/pkg/version/check.go b/pkg/version/check.go index 7e5e5dea67f..eb639939978 100644 --- a/pkg/version/check.go +++ b/pkg/version/check.go @@ -25,9 +25,9 @@ import ( "github.com/coreos/go-semver/semver" "github.com/pingcap/kvproto/pkg/metapb" "github.com/pingcap/log" - cerror "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/httputil" - "github.com/pingcap/ticdc/pkg/security" + cerror "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/httputil" + "github.com/pingcap/tiflow/pkg/security" pd "github.com/tikv/pd/client" "go.uber.org/zap" ) diff --git a/pkg/version/check_test.go b/pkg/version/check_test.go index 154fa4afcf4..36a2ba1a082 100644 --- a/pkg/version/check_test.go +++ b/pkg/version/check_test.go @@ -24,7 +24,7 @@ import ( "github.com/coreos/go-semver/semver" "github.com/pingcap/check" "github.com/pingcap/kvproto/pkg/metapb" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" pd "github.com/tikv/pd/client" "github.com/tikv/pd/pkg/tempurl" ) diff --git a/pkg/version/version.go b/pkg/version/version.go index 3c6d4b960cc..ba4d2f78e8a 100644 --- a/pkg/version/version.go +++ b/pkg/version/version.go @@ -18,7 +18,7 @@ import ( "github.com/coreos/go-semver/semver" "github.com/pingcap/log" - "github.com/pingcap/ticdc/pkg/util" + "github.com/pingcap/tiflow/pkg/util" "go.uber.org/zap" ) diff --git a/pkg/workerpool/async_pool_impl.go b/pkg/workerpool/async_pool_impl.go index e2bf3ab6113..87c027e56b8 100644 --- a/pkg/workerpool/async_pool_impl.go +++ b/pkg/workerpool/async_pool_impl.go @@ -19,8 +19,8 @@ import ( "sync/atomic" "github.com/pingcap/errors" - cerrors "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/retry" + cerrors "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/retry" "golang.org/x/sync/errgroup" ) diff --git a/pkg/workerpool/async_pool_test.go b/pkg/workerpool/async_pool_test.go index d1e2107c607..0161b4e2ffc 100644 --- a/pkg/workerpool/async_pool_test.go +++ b/pkg/workerpool/async_pool_test.go @@ -24,7 +24,7 @@ import ( "github.com/pingcap/check" "github.com/pingcap/errors" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" "golang.org/x/sync/errgroup" ) diff --git a/pkg/workerpool/pool_impl.go b/pkg/workerpool/pool_impl.go index d98d4ffc1a8..97af0aaec33 100644 --- a/pkg/workerpool/pool_impl.go +++ b/pkg/workerpool/pool_impl.go @@ -23,8 +23,8 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" - cerrors "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/notify" + cerrors "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/notify" "go.uber.org/zap" "golang.org/x/sync/errgroup" "golang.org/x/time/rate" diff --git a/pkg/workerpool/pool_test.go b/pkg/workerpool/pool_test.go index c34378fd625..729c20d7a31 100644 --- a/pkg/workerpool/pool_test.go +++ b/pkg/workerpool/pool_test.go @@ -24,7 +24,7 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/pkg/util/testleak" + "github.com/pingcap/tiflow/pkg/util/testleak" "github.com/stretchr/testify/require" "go.uber.org/zap" "golang.org/x/sync/errgroup" @@ -207,10 +207,10 @@ func (s *workerPoolSuite) TestCancelHandle(c *check.C) { } } - err := failpoint.Enable("github.com/pingcap/ticdc/pkg/workerpool/addEventDelayPoint", "1*sleep(500)") + err := failpoint.Enable("github.com/pingcap/tiflow/pkg/workerpool/addEventDelayPoint", "1*sleep(500)") c.Assert(err, check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/pkg/workerpool/addEventDelayPoint") + _ = failpoint.Disable("github.com/pingcap/tiflow/pkg/workerpool/addEventDelayPoint") }() handle.Unregister() @@ -240,10 +240,10 @@ func (s *workerPoolSuite) TestCancelTimer(c *check.C) { return pool.Run(ctx) }) - err := failpoint.Enable("github.com/pingcap/ticdc/pkg/workerpool/unregisterDelayPoint", "sleep(5000)") + err := failpoint.Enable("github.com/pingcap/tiflow/pkg/workerpool/unregisterDelayPoint", "sleep(5000)") c.Assert(err, check.IsNil) defer func() { - _ = failpoint.Disable("github.com/pingcap/ticdc/pkg/workerpool/unregisterDelayPoint") + _ = failpoint.Disable("github.com/pingcap/tiflow/pkg/workerpool/unregisterDelayPoint") }() handle := pool.RegisterEvent(func(ctx context.Context, event interface{}) error { @@ -460,7 +460,7 @@ func TestSynchronizeLog(t *testing.T) { } // Benchmark workerpool with ping-pong workflow. -// go test -benchmem -run='^$' -bench '^(BenchmarkWorkerpool)$' github.com/pingcap/ticdc/pkg/workerpool +// go test -benchmem -run='^$' -bench '^(BenchmarkWorkerpool)$' github.com/pingcap/tiflow/pkg/workerpool func BenchmarkWorkerpool(b *testing.B) { ctx, cancel := context.WithCancel(context.Background()) defer cancel() diff --git a/scripts/jenkins_ci/cdc_ghpr_build.groovy b/scripts/jenkins_ci/cdc_ghpr_build.groovy index 154bda8a085..05f6de1eed6 100644 --- a/scripts/jenkins_ci/cdc_ghpr_build.groovy +++ b/scripts/jenkins_ci/cdc_ghpr_build.groovy @@ -7,7 +7,7 @@ catchError { deleteDir() unstash 'ticdc' - dir("go/src/github.com/pingcap/ticdc") { + dir("go/src/github.com/pingcap/tiflow") { sh """ GO111MODULE=off GOPATH=\$GOPATH:${ws}/go PATH=\$GOPATH/bin:${ws}/go/bin:\$PATH make """ diff --git a/scripts/jenkins_ci/cdc_ghpr_check.groovy b/scripts/jenkins_ci/cdc_ghpr_check.groovy index b8863002d02..94d2f9f2caf 100644 --- a/scripts/jenkins_ci/cdc_ghpr_check.groovy +++ b/scripts/jenkins_ci/cdc_ghpr_check.groovy @@ -7,7 +7,7 @@ catchError { deleteDir() unstash 'ticdc' - dir("go/src/github.com/pingcap/ticdc") { + dir("go/src/github.com/pingcap/tiflow") { sh """ GOPATH=\$GOPATH:${ws}/go PATH=\$GOPATH/bin:${ws}/go/bin:\$PATH make check """ diff --git a/scripts/jenkins_ci/cdc_ghpr_integration_test.groovy b/scripts/jenkins_ci/cdc_ghpr_integration_test.groovy index 2b959b27548..0c3945a541c 100644 --- a/scripts/jenkins_ci/cdc_ghpr_integration_test.groovy +++ b/scripts/jenkins_ci/cdc_ghpr_integration_test.groovy @@ -1,4 +1,4 @@ -def script_path = "go/src/github.com/pingcap/ticdc/scripts/jenkins_ci/integration_test_common.groovy" +def script_path = "go/src/github.com/pingcap/tiflow/scripts/jenkins_ci/integration_test_common.groovy" def common = load script_path catchError { diff --git a/scripts/jenkins_ci/cdc_ghpr_kafka_integration_test.groovy b/scripts/jenkins_ci/cdc_ghpr_kafka_integration_test.groovy index 532d111db71..ae3b5731ca4 100644 --- a/scripts/jenkins_ci/cdc_ghpr_kafka_integration_test.groovy +++ b/scripts/jenkins_ci/cdc_ghpr_kafka_integration_test.groovy @@ -1,9 +1,9 @@ -def script_path = "go/src/github.com/pingcap/ticdc/scripts/jenkins_ci/integration_test_common.groovy" +def script_path = "go/src/github.com/pingcap/tiflow/scripts/jenkins_ci/integration_test_common.groovy" def common = load script_path // HACK! Download jks by injecting RACK_COMMAND -// https://git.io/JJZXX -> https://github.com/pingcap/ticdc/raw/6e62afcfecc4e3965d8818784327d4bf2600d9fa/tests/_certificates/kafka.server.keystore.jks -// https://git.io/JJZXM -> https://github.com/pingcap/ticdc/raw/6e62afcfecc4e3965d8818784327d4bf2600d9fa/tests/_certificates/kafka.server.truststore.jks +// https://git.io/JJZXX -> https://github.com/pingcap/tiflow/raw/6e62afcfecc4e3965d8818784327d4bf2600d9fa/tests/_certificates/kafka.server.keystore.jks +// https://git.io/JJZXM -> https://github.com/pingcap/tiflow/raw/6e62afcfecc4e3965d8818784327d4bf2600d9fa/tests/_certificates/kafka.server.truststore.jks def download_jks = 'curl -sfL https://git.io/JJZXX -o /tmp/kafka.server.keystore.jks && curl -sfL https://git.io/JJZXM -o /tmp/kafka.server.truststore.jks' diff --git a/scripts/jenkins_ci/cdc_ghpr_leak_test.groovy b/scripts/jenkins_ci/cdc_ghpr_leak_test.groovy index 447c6c8b62d..8f332e33065 100644 --- a/scripts/jenkins_ci/cdc_ghpr_leak_test.groovy +++ b/scripts/jenkins_ci/cdc_ghpr_leak_test.groovy @@ -7,7 +7,7 @@ catchError { deleteDir() unstash 'ticdc' - dir("go/src/github.com/pingcap/ticdc") { + dir("go/src/github.com/pingcap/tiflow") { sh """ GO111MODULE=off GOPATH=\$GOPATH:${ws}/go PATH=\$GOPATH/bin:${ws}/go/bin:\$PATH make leak_test """ diff --git a/scripts/jenkins_ci/cdc_ghpr_test.groovy b/scripts/jenkins_ci/cdc_ghpr_test.groovy index 9519953a697..eeb487618d6 100644 --- a/scripts/jenkins_ci/cdc_ghpr_test.groovy +++ b/scripts/jenkins_ci/cdc_ghpr_test.groovy @@ -7,7 +7,7 @@ catchError { deleteDir() unstash 'ticdc' - dir("go/src/github.com/pingcap/ticdc") { + dir("go/src/github.com/pingcap/tiflow") { sh """ GO111MODULE=off GOPATH=\$GOPATH:${ws}/go PATH=\$GOPATH/bin:${ws}/go/bin:\$PATH make test """ diff --git a/scripts/jenkins_ci/integration_test_common.groovy b/scripts/jenkins_ci/integration_test_common.groovy index 438a37d153d..cd8cc06f5d5 100644 --- a/scripts/jenkins_ci/integration_test_common.groovy +++ b/scripts/jenkins_ci/integration_test_common.groovy @@ -12,7 +12,7 @@ def prepare_binaries() { deleteDir() unstash 'ticdc' - dir("go/src/github.com/pingcap/ticdc") { + dir("go/src/github.com/pingcap/tiflow") { sh """ GO111MODULE=off GOPATH=\$GOPATH:${ws}/go PATH=\$GOPATH/bin:${ws}/go/bin:\$PATH make cdc GO111MODULE=off GOPATH=\$GOPATH:${ws}/go PATH=\$GOPATH/bin:${ws}/go/bin:\$PATH make integration_test_build @@ -22,14 +22,14 @@ def prepare_binaries() { curl -F test/cdc/ci/ticdc_bin_${env.BUILD_NUMBER}.tar.gz=@ticdc_bin.tar.gz http://fileserver.pingcap.net/upload """ } - dir("go/src/github.com/pingcap/ticdc/tests") { + dir("go/src/github.com/pingcap/tiflow/tests") { def cases_name = sh ( script: 'find . -maxdepth 2 -mindepth 2 -name \'run.sh\' | awk -F/ \'{print $2}\'', returnStdout: true ).trim().split().join(" ") sh "echo ${cases_name} > CASES" } - stash includes: "go/src/github.com/pingcap/ticdc/tests/CASES", name: "cases_name", useDefaultExcludes: false + stash includes: "go/src/github.com/pingcap/tiflow/tests/CASES", name: "cases_name", useDefaultExcludes: false } } } @@ -50,7 +50,7 @@ def tests(sink_type, node_label) { println "work space path:\n${ws}" unstash 'ticdc' - dir("go/src/github.com/pingcap/ticdc") { + dir("go/src/github.com/pingcap/tiflow") { sh """ rm -rf /tmp/tidb_cdc_test mkdir -p /tmp/tidb_cdc_test @@ -64,7 +64,7 @@ def tests(sink_type, node_label) { tail /tmp/tidb_cdc_test/cov* """ } - stash includes: "go/src/github.com/pingcap/ticdc/cov_dir/**", name: "unit_test", useDefaultExcludes: false + stash includes: "go/src/github.com/pingcap/tiflow/cov_dir/**", name: "unit_test", useDefaultExcludes: false } } } @@ -78,7 +78,7 @@ def tests(sink_type, node_label) { println "work space path:\n${ws}" println "this step will run tests: ${case_names}" unstash 'ticdc' - dir("go/src/github.com/pingcap/ticdc") { + dir("go/src/github.com/pingcap/tiflow") { download_binaries() try { sh """ @@ -110,7 +110,7 @@ def tests(sink_type, node_label) { throw e; } } - stash includes: "go/src/github.com/pingcap/ticdc/cov_dir/**", name: "integration_test_${step_name}", useDefaultExcludes: false + stash includes: "go/src/github.com/pingcap/tiflow/cov_dir/**", name: "integration_test_${step_name}", useDefaultExcludes: false } } } @@ -118,7 +118,7 @@ def tests(sink_type, node_label) { unstash 'cases_name' def cases_name = sh ( - script: 'cat go/src/github.com/pingcap/ticdc/tests/CASES', + script: 'cat go/src/github.com/pingcap/tiflow/tests/CASES', returnStdout: true ).trim().split() @@ -233,7 +233,7 @@ def coverage() { unstash "integration_test_step_${i-1}" } - dir("go/src/github.com/pingcap/ticdc") { + dir("go/src/github.com/pingcap/tiflow") { container("golang") { archiveArtifacts artifacts: 'cov_dir/*', fingerprint: true diff --git a/testing_utils/cdc_state_checker/cdc_monitor.go b/testing_utils/cdc_state_checker/cdc_monitor.go index 30179b29de0..c628c4e67a0 100644 --- a/testing_utils/cdc_state_checker/cdc_monitor.go +++ b/testing_utils/cdc_state_checker/cdc_monitor.go @@ -17,14 +17,14 @@ import ( "context" "time" - "github.com/pingcap/ticdc/pkg/security" + "github.com/pingcap/tiflow/pkg/security" "github.com/pingcap/log" "github.com/pingcap/errors" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/pkg/etcd" - "github.com/pingcap/ticdc/pkg/orchestrator" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/pkg/etcd" + "github.com/pingcap/tiflow/pkg/orchestrator" "github.com/prometheus/client_golang/prometheus" "go.etcd.io/etcd/clientv3" "go.etcd.io/etcd/pkg/logutil" diff --git a/testing_utils/cdc_state_checker/main.go b/testing_utils/cdc_state_checker/main.go index b1408f91d19..5f639e3a103 100644 --- a/testing_utils/cdc_state_checker/main.go +++ b/testing_utils/cdc_state_checker/main.go @@ -18,7 +18,7 @@ import ( "flag" "strings" - "github.com/pingcap/ticdc/pkg/security" + "github.com/pingcap/tiflow/pkg/security" "github.com/pingcap/log" "go.uber.org/zap" diff --git a/testing_utils/cdc_state_checker/reactor.go b/testing_utils/cdc_state_checker/reactor.go index 2c0acd8d1e8..619b19fdf00 100644 --- a/testing_utils/cdc_state_checker/reactor.go +++ b/testing_utils/cdc_state_checker/reactor.go @@ -18,8 +18,8 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/orchestrator" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/orchestrator" "go.uber.org/zap" ) diff --git a/testing_utils/cdc_state_checker/state.go b/testing_utils/cdc_state_checker/state.go index ffc371a5c35..9cdbf1f8ac6 100644 --- a/testing_utils/cdc_state_checker/state.go +++ b/testing_utils/cdc_state_checker/state.go @@ -21,10 +21,10 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/kv" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/pkg/orchestrator" - "github.com/pingcap/ticdc/pkg/orchestrator/util" + "github.com/pingcap/tiflow/cdc/kv" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/pkg/orchestrator" + "github.com/pingcap/tiflow/pkg/orchestrator/util" ) type cdcReactorState struct { diff --git a/testing_utils/many_sorters_test/many_sorters.go b/testing_utils/many_sorters_test/many_sorters.go index d3dc5dd807b..04eedddc0bf 100644 --- a/testing_utils/many_sorters_test/many_sorters.go +++ b/testing_utils/many_sorters_test/many_sorters.go @@ -26,11 +26,11 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/puller" - pullerSorter "github.com/pingcap/ticdc/cdc/puller/sorter" - "github.com/pingcap/ticdc/pkg/config" - cerrors "github.com/pingcap/ticdc/pkg/errors" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/puller" + pullerSorter "github.com/pingcap/tiflow/cdc/puller/sorter" + "github.com/pingcap/tiflow/pkg/config" + cerrors "github.com/pingcap/tiflow/pkg/errors" "go.uber.org/zap" "go.uber.org/zap/zapcore" "golang.org/x/sync/errgroup" @@ -45,7 +45,7 @@ var ( func main() { flag.Parse() - err := failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/sorterDebug", "return(true)") + err := failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/sorterDebug", "return(true)") if err != nil { log.Fatal("Could not enable failpoint", zap.Error(err)) } diff --git a/testing_utils/sorter_stress_test/sorter_stress.go b/testing_utils/sorter_stress_test/sorter_stress.go index e54e2de4317..4ac8790a2cd 100644 --- a/testing_utils/sorter_stress_test/sorter_stress.go +++ b/testing_utils/sorter_stress_test/sorter_stress.go @@ -24,10 +24,10 @@ import ( "github.com/pingcap/failpoint" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/model" - "github.com/pingcap/ticdc/cdc/puller" - pullerSorter "github.com/pingcap/ticdc/cdc/puller/sorter" - "github.com/pingcap/ticdc/pkg/config" + "github.com/pingcap/tiflow/cdc/model" + "github.com/pingcap/tiflow/cdc/puller" + pullerSorter "github.com/pingcap/tiflow/cdc/puller/sorter" + "github.com/pingcap/tiflow/pkg/config" "go.uber.org/zap" "golang.org/x/sync/errgroup" ) @@ -42,7 +42,7 @@ var ( func main() { flag.Parse() log.SetLevel(zap.DebugLevel) - err := failpoint.Enable("github.com/pingcap/ticdc/cdc/puller/sorter/sorterDebug", "return(true)") + err := failpoint.Enable("github.com/pingcap/tiflow/cdc/puller/sorter/sorterDebug", "return(true)") if err != nil { log.Fatal("Could not enable failpoint", zap.Error(err)) } diff --git a/tests/integration_tests/_utils/run_cdc_cli_tso_query b/tests/integration_tests/_utils/run_cdc_cli_tso_query index 290c7f3a8fe..6303e24063f 100755 --- a/tests/integration_tests/_utils/run_cdc_cli_tso_query +++ b/tests/integration_tests/_utils/run_cdc_cli_tso_query @@ -11,7 +11,7 @@ pd_port=${2} tso=$(run_cdc_cli tso query --pd=http://${pd_host}:${pd_port}) # make sure get tso only # the tso got above is: -# "427768583921860609 PASS coverage: 2.7% of statements in github.com/pingcap/ticdc/..." +# "427768583921860609 PASS coverage: 2.7% of statements in github.com/pingcap/tiflow/..." # and only "427768583921860609" is a real tso echo $tso | awk -F " " '{print $1}' diff --git a/tests/integration_tests/availability/owner.sh b/tests/integration_tests/availability/owner.sh index 273b958db26..9c5bfc5da64 100755 --- a/tests/integration_tests/availability/owner.sh +++ b/tests/integration_tests/availability/owner.sh @@ -159,7 +159,7 @@ function test_owner_cleanup_stale_tasks() { function test_owner_retryable_error() { echo "run test case test_owner_retryable_error" - export GO_FAILPOINTS='github.com/pingcap/ticdc/cdc/capture/capture-campaign-compacted-error=1*return(true)' + export GO_FAILPOINTS='github.com/pingcap/tiflow/cdc/capture/capture-campaign-compacted-error=1*return(true)' # start a capture server run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY --logsuffix test_owner_retryable_error.server1 @@ -171,7 +171,7 @@ function test_owner_retryable_error() { echo "owner pid:" $owner_pid echo "owner id" $owner_id - export GO_FAILPOINTS='github.com/pingcap/ticdc/cdc/owner/owner-run-with-error=1*return(true);github.com/pingcap/ticdc/cdc/capture/capture-resign-failed=1*return(true)' + export GO_FAILPOINTS='github.com/pingcap/tiflow/cdc/owner/owner-run-with-error=1*return(true);github.com/pingcap/tiflow/cdc/capture/capture-resign-failed=1*return(true)' # run another server run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY --logsuffix test_owner_retryable_error.server2 --addr "127.0.0.1:8301" @@ -196,7 +196,7 @@ function test_owner_retryable_error() { function test_gap_between_watch_capture() { echo "run test case test_gap_between_watch_capture" - export GO_FAILPOINTS='github.com/pingcap/ticdc/cdc/owner/sleep-in-owner-tick=1*sleep(6000)' + export GO_FAILPOINTS='github.com/pingcap/tiflow/cdc/owner/sleep-in-owner-tick=1*sleep(6000)' # start a capture server run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY --logsuffix test_gap_between_watch_capture.server1 diff --git a/tests/integration_tests/bank/case.go b/tests/integration_tests/bank/case.go index 6ed50e4885a..ce3b51d90a7 100644 --- a/tests/integration_tests/bank/case.go +++ b/tests/integration_tests/bank/case.go @@ -25,7 +25,7 @@ import ( _ "github.com/go-sql-driver/mysql" // MySQL driver "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/pkg/retry" + "github.com/pingcap/tiflow/pkg/retry" "go.uber.org/zap" "golang.org/x/sync/errgroup" ) diff --git a/tests/integration_tests/capture_session_done_during_task/run.sh b/tests/integration_tests/capture_session_done_during_task/run.sh index 89c5ad36f3b..0205d74943d 100644 --- a/tests/integration_tests/capture_session_done_during_task/run.sh +++ b/tests/integration_tests/capture_session_done_during_task/run.sh @@ -28,7 +28,7 @@ function run() { run_sql "CREATE table capture_session_done_during_task.t (id int primary key auto_increment, a int)" ${DOWN_TIDB_HOST} ${DOWN_TIDB_PORT} start_ts=$(run_cdc_cli_tso_query ${UP_PD_HOST_1} ${UP_PD_PORT_1}) run_sql "INSERT INTO capture_session_done_during_task.t values (),(),(),(),(),(),()" ${UP_TIDB_HOST} ${UP_TIDB_PORT} - export GO_FAILPOINTS='github.com/pingcap/ticdc/cdc/processor/processorManagerHandleNewChangefeedDelay=sleep(2000)' + export GO_FAILPOINTS='github.com/pingcap/tiflow/cdc/processor/processorManagerHandleNewChangefeedDelay=sleep(2000)' run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY --addr "127.0.0.1:8300" --pd $pd_addr changefeed_id=$(cdc cli changefeed create --pd=$pd_addr --start-ts=$start_ts --sink-uri="$SINK_URI" 2>&1 | tail -n2 | head -n1 | awk '{print $2}') # wait task is dispatched diff --git a/tests/integration_tests/capture_suicide_while_balance_table/run.sh b/tests/integration_tests/capture_suicide_while_balance_table/run.sh index 8e0597921bd..3accdee5b4f 100644 --- a/tests/integration_tests/capture_suicide_while_balance_table/run.sh +++ b/tests/integration_tests/capture_suicide_while_balance_table/run.sh @@ -36,7 +36,7 @@ function run() { pd_addr="http://$UP_PD_HOST_1:$UP_PD_PORT_1" run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY --pd $pd_addr --logsuffix 1 --addr "127.0.0.1:8300" - export GO_FAILPOINTS='github.com/pingcap/ticdc/cdc/sink/MySQLSinkHangLongTime=1*return(true)' + export GO_FAILPOINTS='github.com/pingcap/tiflow/cdc/sink/MySQLSinkHangLongTime=1*return(true)' run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY --pd $pd_addr --logsuffix 2 --addr "127.0.0.1:8301" SINK_URI="mysql://normal:123456@127.0.0.1:3306/?max-txn-row=1" diff --git a/tests/integration_tests/cdc/cdc.go b/tests/integration_tests/cdc/cdc.go index a62dcad8b98..6b7f56cb36f 100644 --- a/tests/integration_tests/cdc/cdc.go +++ b/tests/integration_tests/cdc/cdc.go @@ -20,8 +20,8 @@ import ( _ "github.com/go-sql-driver/mysql" "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/tests/integration_tests/dailytest" - "github.com/pingcap/ticdc/tests/integration_tests/util" + "github.com/pingcap/tiflow/tests/integration_tests/dailytest" + "github.com/pingcap/tiflow/tests/integration_tests/util" ) func main() { diff --git a/tests/integration_tests/changefeed_auto_stop/run.sh b/tests/integration_tests/changefeed_auto_stop/run.sh index a77e5d99527..5229e6e7f8e 100755 --- a/tests/integration_tests/changefeed_auto_stop/run.sh +++ b/tests/integration_tests/changefeed_auto_stop/run.sh @@ -42,7 +42,7 @@ function run() { run_sql "CREATE DATABASE $db;" ${UP_TIDB_HOST} ${UP_TIDB_PORT} go-ycsb load mysql -P $CUR/conf/workload -p mysql.host=${UP_TIDB_HOST} -p mysql.port=${UP_TIDB_PORT} -p mysql.user=root -p mysql.db=$db done - export GO_FAILPOINTS='github.com/pingcap/ticdc/cdc/processor/pipeline/ProcessorSyncResolvedError=1*return(true);github.com/pingcap/ticdc/cdc/processor/ProcessorUpdatePositionDelaying=sleep(1000)' + export GO_FAILPOINTS='github.com/pingcap/tiflow/cdc/processor/pipeline/ProcessorSyncResolvedError=1*return(true);github.com/pingcap/tiflow/cdc/processor/ProcessorUpdatePositionDelaying=sleep(1000)' run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY --logsuffix "1" --addr "127.0.0.1:8301" --pd "http://${UP_PD_HOST_1}:${UP_PD_PORT_1}" run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY --logsuffix "2" --addr "127.0.0.1:8302" --pd "http://${UP_PD_HOST_1}:${UP_PD_PORT_1}" export GO_FAILPOINTS='' diff --git a/tests/integration_tests/changefeed_error/run.sh b/tests/integration_tests/changefeed_error/run.sh index c4a32f48088..6c5b878c187 100755 --- a/tests/integration_tests/changefeed_error/run.sh +++ b/tests/integration_tests/changefeed_error/run.sh @@ -114,7 +114,7 @@ function run() { start_ts=$(run_cdc_cli_tso_query ${UP_PD_HOST_1} ${UP_PD_PORT_1}) run_sql "CREATE DATABASE changefeed_error;" ${UP_TIDB_HOST} ${UP_TIDB_PORT} go-ycsb load mysql -P $CUR/conf/workload -p mysql.host=${UP_TIDB_HOST} -p mysql.port=${UP_TIDB_PORT} -p mysql.user=root -p mysql.db=changefeed_error - export GO_FAILPOINTS='github.com/pingcap/ticdc/cdc/owner/NewChangefeedNoRetryError=1*return(true)' + export GO_FAILPOINTS='github.com/pingcap/tiflow/cdc/owner/NewChangefeedNoRetryError=1*return(true)' run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY capture_pid=$(ps -C $CDC_BINARY -o pid= | awk '{print $1}') @@ -138,7 +138,7 @@ function run() { go-ycsb load mysql -P $CUR/conf/workload -p mysql.host=${UP_TIDB_HOST} -p mysql.port=${UP_TIDB_PORT} -p mysql.user=root -p mysql.db=changefeed_error check_sync_diff $WORK_DIR $CUR/conf/diff_config.toml - export GO_FAILPOINTS='github.com/pingcap/ticdc/cdc/owner/NewChangefeedRetryError=return(true)' + export GO_FAILPOINTS='github.com/pingcap/tiflow/cdc/owner/NewChangefeedRetryError=return(true)' kill $capture_pid ensure $MAX_RETRIES check_no_capture http://${UP_PD_HOST_1}:${UP_PD_PORT_1} run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY @@ -151,7 +151,7 @@ function run() { cleanup_process $CDC_BINARY # owner DDL error case - export GO_FAILPOINTS='github.com/pingcap/ticdc/cdc/owner/InjectChangefeedDDLError=return(true)' + export GO_FAILPOINTS='github.com/pingcap/tiflow/cdc/owner/InjectChangefeedDDLError=return(true)' run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY changefeedid_1="changefeed-error-1" run_cdc_cli changefeed create --start-ts=$start_ts --sink-uri="$SINK_URI" -c $changefeedid_1 @@ -163,7 +163,7 @@ function run() { cleanup_process $CDC_BINARY # updating GC safepoint failure case - export GO_FAILPOINTS='github.com/pingcap/ticdc/pkg/txnutil/gc/InjectActualGCSafePoint=return(9223372036854775807)' + export GO_FAILPOINTS='github.com/pingcap/tiflow/pkg/txnutil/gc/InjectActualGCSafePoint=return(9223372036854775807)' run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY changefeedid_2="changefeed-error-2" diff --git a/tests/integration_tests/changefeed_fast_fail/run.sh b/tests/integration_tests/changefeed_fast_fail/run.sh index 273368f5130..a5bdaa60d17 100644 --- a/tests/integration_tests/changefeed_fast_fail/run.sh +++ b/tests/integration_tests/changefeed_fast_fail/run.sh @@ -44,7 +44,7 @@ function run() { start_ts=$(run_cdc_cli_tso_query ${UP_PD_HOST_1} ${UP_PD_PORT_1}) run_sql "CREATE DATABASE changefeed_error;" ${UP_TIDB_HOST} ${UP_TIDB_PORT} - export GO_FAILPOINTS='github.com/pingcap/ticdc/cdc/owner/InjectChangefeedFastFailError=return(true)' + export GO_FAILPOINTS='github.com/pingcap/tiflow/cdc/owner/InjectChangefeedFastFailError=return(true)' run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY SINK_URI="mysql://normal:123456@127.0.0.1:3306/?max-txn-row=1" diff --git a/tests/integration_tests/dailytest/db.go b/tests/integration_tests/dailytest/db.go index 76f4f90c7be..db7c5f7968c 100644 --- a/tests/integration_tests/dailytest/db.go +++ b/tests/integration_tests/dailytest/db.go @@ -24,7 +24,7 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" "github.com/pingcap/parser/mysql" - "github.com/pingcap/ticdc/tests/integration_tests/util" + "github.com/pingcap/tiflow/tests/integration_tests/util" "go.uber.org/zap/zapcore" ) diff --git a/tests/integration_tests/ddl_async/run.sh b/tests/integration_tests/ddl_async/run.sh index bb54b2a6f47..9eaa8fddf24 100644 --- a/tests/integration_tests/ddl_async/run.sh +++ b/tests/integration_tests/ddl_async/run.sh @@ -65,7 +65,7 @@ function run() { run_sql_file $CUR/data/prepare.sql ${UP_TIDB_HOST} ${UP_TIDB_PORT} - export GO_FAILPOINTS='github.com/pingcap/ticdc/cdc/owner/InjectChangefeedDDLBlock=1*return(true)' + export GO_FAILPOINTS='github.com/pingcap/tiflow/cdc/owner/InjectChangefeedDDLBlock=1*return(true)' run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY # normal changefeed run_cdc_cli changefeed create -c="changefeed-ddl-normal" --start-ts=$start_ts --sink-uri="$SINK_URI" --config="$CUR/conf/normal_cf_config.toml" diff --git a/tests/integration_tests/ddl_puller_lag/run.sh b/tests/integration_tests/ddl_puller_lag/run.sh index e25f38489de..8f9595d7e0a 100644 --- a/tests/integration_tests/ddl_puller_lag/run.sh +++ b/tests/integration_tests/ddl_puller_lag/run.sh @@ -21,7 +21,7 @@ function prepare() { run_sql "CREATE table test.ddl_puller_lag1(id int primary key, val int);" run_sql "CREATE table test.ddl_puller_lag2(id int primary key, val int);" - run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY --failpoint 'github.com/pingcap/ticdc/cdc/processor/processorDDLResolved=1*sleep(180000)' + run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY --failpoint 'github.com/pingcap/tiflow/cdc/processor/processorDDLResolved=1*sleep(180000)' TOPIC_NAME="ticdc-ddl-puller-lag-test-$RANDOM" case $SINK_TYPE in diff --git a/tests/integration_tests/force_replicate_table/run.sh b/tests/integration_tests/force_replicate_table/run.sh index 76e5581be2f..1b3e7ea04ef 100755 --- a/tests/integration_tests/force_replicate_table/run.sh +++ b/tests/integration_tests/force_replicate_table/run.sh @@ -72,7 +72,7 @@ function run() { table="force_replicate_table.t$i" check_table_exists $table ${DOWN_TIDB_HOST} ${DOWN_TIDB_PORT} done - # data could be duplicated due to https://github.com/pingcap/ticdc/issues/964, + # data could be duplicated due to https://github.com/pingcap/tiflow/issues/964, # so we just check downstream contains all data in upstream. for i in $(seq 0 6); do ensure 5 check_data_subset "force_replicate_table.t$i" \ diff --git a/tests/integration_tests/gc_safepoint/run.sh b/tests/integration_tests/gc_safepoint/run.sh index 658955e26f6..d3e219fe560 100755 --- a/tests/integration_tests/gc_safepoint/run.sh +++ b/tests/integration_tests/gc_safepoint/run.sh @@ -93,7 +93,7 @@ function run() { *) SINK_URI="mysql://normal:123456@127.0.0.1:3306/?max-txn-row=1" ;; esac - export GO_FAILPOINTS='github.com/pingcap/ticdc/pkg/txnutil/gc/InjectGcSafepointUpdateInterval=return(500)' + export GO_FAILPOINTS='github.com/pingcap/tiflow/pkg/txnutil/gc/InjectGcSafepointUpdateInterval=return(500)' run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY --addr "127.0.0.1:8300" --pd $pd_addr changefeed_id=$(cdc cli changefeed create --pd=$pd_addr --sink-uri="$SINK_URI" 2>&1 | tail -n2 | head -n1 | awk '{print $2}') diff --git a/tests/integration_tests/kafka_sink_error_resume/run.sh b/tests/integration_tests/kafka_sink_error_resume/run.sh index 7039c16c042..1020d5cd233 100755 --- a/tests/integration_tests/kafka_sink_error_resume/run.sh +++ b/tests/integration_tests/kafka_sink_error_resume/run.sh @@ -39,7 +39,7 @@ function run() { TOPIC_NAME="ticdc-kafka-sink-error-resume-test-$RANDOM" SINK_URI="kafka://127.0.0.1:9092/$TOPIC_NAME?partition-num=4&kafka-version=${KAFKA_VERSION}&max-message-bytes=10485760" - export GO_FAILPOINTS='github.com/pingcap/ticdc/cdc/sink/producer/kafka/KafkaSinkAsyncSendError=4*return(true)' + export GO_FAILPOINTS='github.com/pingcap/tiflow/cdc/sink/producer/kafka/KafkaSinkAsyncSendError=4*return(true)' run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY --addr "127.0.0.1:8300" --pd $pd_addr changefeed_id=$(cdc cli changefeed create --pd=$pd_addr --sink-uri="$SINK_URI" 2>&1 | tail -n2 | head -n1 | awk '{print $2}') run_kafka_consumer $WORK_DIR "kafka://127.0.0.1:9092/$TOPIC_NAME?partition-num=4&version=${KAFKA_VERSION}&max-message-bytes=10485760" diff --git a/tests/integration_tests/kill_owner_with_ddl/run.sh b/tests/integration_tests/kill_owner_with_ddl/run.sh index e722ab974a4..d767c727b66 100755 --- a/tests/integration_tests/kill_owner_with_ddl/run.sh +++ b/tests/integration_tests/kill_owner_with_ddl/run.sh @@ -54,7 +54,7 @@ function run() { run_sql "CREATE table kill_owner_with_ddl.t1 (id int primary key auto_increment, val int);" ${UP_TIDB_HOST} ${UP_TIDB_PORT} check_table_exists "kill_owner_with_ddl.t1" ${DOWN_TIDB_HOST} ${DOWN_TIDB_PORT} - export GO_FAILPOINTS='github.com/pingcap/ticdc/cdc/sink/MySQLSinkExecDDLDelay=return(true);github.com/pingcap/ticdc/cdc/ownerFlushIntervalInject=return(0)' + export GO_FAILPOINTS='github.com/pingcap/tiflow/cdc/sink/MySQLSinkExecDDLDelay=return(true);github.com/pingcap/tiflow/cdc/ownerFlushIntervalInject=return(0)' kill_cdc_and_restart $pd_addr $WORK_DIR $CDC_BINARY for i in $(seq 2 3); do diff --git a/tests/integration_tests/kv_client_stream_reconnect/run.sh b/tests/integration_tests/kv_client_stream_reconnect/run.sh index ce4c102b463..ab39329419e 100644 --- a/tests/integration_tests/kv_client_stream_reconnect/run.sh +++ b/tests/integration_tests/kv_client_stream_reconnect/run.sh @@ -24,7 +24,7 @@ function run() { esac # this will be triggered every 5s in kv client - export GO_FAILPOINTS='github.com/pingcap/ticdc/cdc/kv/kvClientForceReconnect=return(true)' + export GO_FAILPOINTS='github.com/pingcap/tiflow/cdc/kv/kvClientForceReconnect=return(true)' run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY --addr "127.0.0.1:8300" --pd $pd_addr changefeed_id=$(cdc cli changefeed create --pd=$pd_addr --sink-uri="$SINK_URI" 2>&1 | tail -n2 | head -n1 | awk '{print $2}') if [ "$SINK_TYPE" == "kafka" ]; then diff --git a/tests/integration_tests/many_pk_or_uk/main.go b/tests/integration_tests/many_pk_or_uk/main.go index 152e40acaba..aa00fe72812 100644 --- a/tests/integration_tests/many_pk_or_uk/main.go +++ b/tests/integration_tests/many_pk_or_uk/main.go @@ -23,7 +23,7 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/tests/integration_tests/util" + "github.com/pingcap/tiflow/tests/integration_tests/util" ) func main() { diff --git a/tests/integration_tests/move_table/main.go b/tests/integration_tests/move_table/main.go index 0321660fe2e..e43b2edd87b 100644 --- a/tests/integration_tests/move_table/main.go +++ b/tests/integration_tests/move_table/main.go @@ -26,9 +26,9 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/cdc/kv" - cerrors "github.com/pingcap/ticdc/pkg/errors" - "github.com/pingcap/ticdc/pkg/retry" + "github.com/pingcap/tiflow/cdc/kv" + cerrors "github.com/pingcap/tiflow/pkg/errors" + "github.com/pingcap/tiflow/pkg/retry" "go.etcd.io/etcd/clientv3" "go.etcd.io/etcd/pkg/logutil" "go.uber.org/zap" diff --git a/tests/integration_tests/multi_source/main.go b/tests/integration_tests/multi_source/main.go index d6af565d2a5..44c94bb3a8f 100644 --- a/tests/integration_tests/multi_source/main.go +++ b/tests/integration_tests/multi_source/main.go @@ -28,7 +28,7 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/tests/integration_tests/util" + "github.com/pingcap/tiflow/tests/integration_tests/util" "go.uber.org/zap" ) diff --git a/tests/integration_tests/owner_remove_table_error/run.sh b/tests/integration_tests/owner_remove_table_error/run.sh index bae27f0a874..5ba75eb1ef1 100644 --- a/tests/integration_tests/owner_remove_table_error/run.sh +++ b/tests/integration_tests/owner_remove_table_error/run.sh @@ -25,7 +25,7 @@ function run() { pd_addr="http://$UP_PD_HOST_1:$UP_PD_PORT_1" SINK_URI="mysql://normal:123456@127.0.0.1:3306/?max-txn-row=1" - export GO_FAILPOINTS='github.com/pingcap/ticdc/cdc/owner/OwnerRemoveTableError=1*return(true)' + export GO_FAILPOINTS='github.com/pingcap/tiflow/cdc/owner/OwnerRemoveTableError=1*return(true)' run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY --addr "127.0.0.1:8300" --pd $pd_addr changefeed_id=$(cdc cli changefeed create --pd=$pd_addr --sink-uri="$SINK_URI" 2>&1 | tail -n2 | head -n1 | awk '{print $2}') diff --git a/tests/integration_tests/processor_err_chan/run.sh b/tests/integration_tests/processor_err_chan/run.sh index ce1a2b994e7..b72dbe55a00 100644 --- a/tests/integration_tests/processor_err_chan/run.sh +++ b/tests/integration_tests/processor_err_chan/run.sh @@ -47,7 +47,7 @@ function run() { run_sql "CREATE table processor_err_chan.t$i (id int primary key auto_increment)" ${DOWN_TIDB_HOST} ${DOWN_TIDB_PORT} done - export GO_FAILPOINTS='github.com/pingcap/ticdc/cdc/processor/pipeline/ProcessorAddTableError=1*return(true)' + export GO_FAILPOINTS='github.com/pingcap/tiflow/cdc/processor/pipeline/ProcessorAddTableError=1*return(true)' run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY --addr "127.0.0.1:8300" --pd $pd_addr export GO_FAILPOINTS='' changefeed_id=$(cdc cli changefeed create --pd=$pd_addr --sink-uri="$SINK_URI" 2>&1 | tail -n2 | head -n1 | awk '{print $2}') diff --git a/tests/integration_tests/processor_panic/main.go b/tests/integration_tests/processor_panic/main.go index fa881ff13db..e4ae6e0b03e 100644 --- a/tests/integration_tests/processor_panic/main.go +++ b/tests/integration_tests/processor_panic/main.go @@ -22,8 +22,8 @@ import ( "github.com/pingcap/errors" "github.com/pingcap/log" - "github.com/pingcap/ticdc/pkg/quotes" - "github.com/pingcap/ticdc/tests/integration_tests/util" + "github.com/pingcap/tiflow/pkg/quotes" + "github.com/pingcap/tiflow/tests/integration_tests/util" "go.uber.org/zap" "golang.org/x/sync/errgroup" ) diff --git a/tests/integration_tests/processor_panic/run.sh b/tests/integration_tests/processor_panic/run.sh index ac4167a3572..20f9aa6fd8b 100644 --- a/tests/integration_tests/processor_panic/run.sh +++ b/tests/integration_tests/processor_panic/run.sh @@ -19,7 +19,7 @@ function prepare() { start_ts=$(run_cdc_cli_tso_query ${UP_PD_HOST_1} ${UP_PD_PORT_1}) run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY --logsuffix 1 --addr 127.0.0.1:8300 --restart true \ - --failpoint 'github.com/pingcap/ticdc/cdc/processor/pipeline/ProcessorSyncResolvedPreEmit=return(true)' + --failpoint 'github.com/pingcap/tiflow/cdc/processor/pipeline/ProcessorSyncResolvedPreEmit=return(true)' run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY --logsuffix 2 --addr 127.0.0.1:8301 diff --git a/tests/integration_tests/processor_resolved_ts_fallback/run.sh b/tests/integration_tests/processor_resolved_ts_fallback/run.sh index 251c058d40e..b99754b42d6 100755 --- a/tests/integration_tests/processor_resolved_ts_fallback/run.sh +++ b/tests/integration_tests/processor_resolved_ts_fallback/run.sh @@ -18,7 +18,7 @@ function run() { start_tidb_cluster --workdir $WORK_DIR cd $WORK_DIR - export GO_FAILPOINTS='github.com/pingcap/ticdc/cdc/sink/SinkFlushDMLPanic=return(true);github.com/pingcap/ticdc/cdc/sink/producer/kafka/SinkFlushDMLPanic=return(true)' + export GO_FAILPOINTS='github.com/pingcap/tiflow/cdc/sink/SinkFlushDMLPanic=return(true);github.com/pingcap/tiflow/cdc/sink/producer/kafka/SinkFlushDMLPanic=return(true)' run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY --logsuffix "1" --addr "127.0.0.1:8301" --pd "http://${UP_PD_HOST_1}:${UP_PD_PORT_1}" TOPIC_NAME="ticdc-processor-resolved-ts-fallback-test-$RANDOM" diff --git a/tests/integration_tests/processor_stop_delay/run.sh b/tests/integration_tests/processor_stop_delay/run.sh index 55a8f57e48f..89d23b963fb 100644 --- a/tests/integration_tests/processor_stop_delay/run.sh +++ b/tests/integration_tests/processor_stop_delay/run.sh @@ -20,7 +20,7 @@ function run() { kafka) SINK_URI="kafka://127.0.0.1:9092/$TOPIC_NAME?partition-num=4&kafka-version=${KAFKA_VERSION}&max-message-bytes=10485760" ;; *) SINK_URI="mysql://normal:123456@127.0.0.1:3306/?max-txn-row=1" ;; esac - export GO_FAILPOINTS='github.com/pingcap/ticdc/cdc/processor/processorStopDelay=1*sleep(10000)' + export GO_FAILPOINTS='github.com/pingcap/tiflow/cdc/processor/processorStopDelay=1*sleep(10000)' run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY --addr "127.0.0.1:8300" --pd $pd_addr changefeed_id=$(cdc cli changefeed create --pd=$pd_addr --sink-uri="$SINK_URI" 2>&1 | tail -n2 | head -n1 | awk '{print $2}') diff --git a/tests/integration_tests/resolve_lock/main.go b/tests/integration_tests/resolve_lock/main.go index c1763ed19f7..3bd7ff0b90d 100644 --- a/tests/integration_tests/resolve_lock/main.go +++ b/tests/integration_tests/resolve_lock/main.go @@ -32,11 +32,11 @@ import ( "github.com/pingcap/kvproto/pkg/kvrpcpb" "github.com/pingcap/log" "github.com/pingcap/parser/model" - "github.com/pingcap/ticdc/tests/integration_tests/util" "github.com/pingcap/tidb/store/tikv" "github.com/pingcap/tidb/store/tikv/oracle" "github.com/pingcap/tidb/store/tikv/tikvrpc" "github.com/pingcap/tidb/tablecodec" + "github.com/pingcap/tiflow/tests/integration_tests/util" pd "github.com/tikv/pd/client" ) diff --git a/tests/integration_tests/sink_hang/run.sh b/tests/integration_tests/sink_hang/run.sh index 4a73b6fbb71..51f532a59b0 100644 --- a/tests/integration_tests/sink_hang/run.sh +++ b/tests/integration_tests/sink_hang/run.sh @@ -42,7 +42,7 @@ function run() { *) SINK_URI="mysql://normal:123456@127.0.0.1:3306/?max-txn-row=1" ;; esac - export GO_FAILPOINTS='github.com/pingcap/ticdc/cdc/sink/MySQLSinkHangLongTime=1*return(true);github.com/pingcap/ticdc/cdc/sink/MySQLSinkExecDMLError=9*return(true)' + export GO_FAILPOINTS='github.com/pingcap/tiflow/cdc/sink/MySQLSinkHangLongTime=1*return(true);github.com/pingcap/tiflow/cdc/sink/MySQLSinkExecDMLError=9*return(true)' run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY --addr "127.0.0.1:8300" --pd $pd_addr changefeed_id=$(cdc cli changefeed create --pd=$pd_addr --sink-uri="$SINK_URI" 2>&1 | tail -n2 | head -n1 | awk '{print $2}') if [ "$SINK_TYPE" == "kafka" ]; then diff --git a/tests/integration_tests/sink_retry/run.sh b/tests/integration_tests/sink_retry/run.sh index 0f19d3fb016..88b0219257a 100755 --- a/tests/integration_tests/sink_retry/run.sh +++ b/tests/integration_tests/sink_retry/run.sh @@ -21,7 +21,7 @@ function run() { start_ts=$(run_cdc_cli_tso_query ${UP_PD_HOST_1} ${UP_PD_PORT_1}) run_sql "CREATE DATABASE sink_retry;" go-ycsb load mysql -P $CUR/conf/workload -p mysql.host=${UP_TIDB_HOST} -p mysql.port=${UP_TIDB_PORT} -p mysql.user=root -p mysql.db=sink_retry - export GO_FAILPOINTS='github.com/pingcap/ticdc/cdc/sink/MySQLSinkTxnRandomError=25%return(true)' + export GO_FAILPOINTS='github.com/pingcap/tiflow/cdc/sink/MySQLSinkTxnRandomError=25%return(true)' run_cdc_server --workdir $WORK_DIR --binary $CDC_BINARY TOPIC_NAME="ticdc-sink-retry-test-$RANDOM" diff --git a/tools/check/check-errdoc.sh b/tools/check/check-errdoc.sh index 13d133e6bf2..26d4aba3176 100755 --- a/tools/check/check-errdoc.sh +++ b/tools/check/check-errdoc.sh @@ -17,5 +17,5 @@ set -euo pipefail cd -P . cp errors.toml /tmp/errors.toml.before -./tools/bin/errdoc-gen --source . --module github.com/pingcap/ticdc --output errors.toml +./tools/bin/errdoc-gen --source . --module github.com/pingcap/tiflow --output errors.toml diff -q errors.toml /tmp/errors.toml.before