Note:
This topic has been translated from a Chinese forum by GPT and might contain errors.
Original topic: sink uri invalid ‘protocol is incompatible with mysql scheme’](]sink uri invalid 'protocol is incompatible with mysql scheme' - TiDB 的问答社区)
In version 7.4.0, creating a changefeed reports an error, while in version 7.1, it works fine with the same downstream.
[tidb@tgypt-xx13d002-cs76w ~]$ cdc cli changefeed create --pd=http://1.1.8.16:23791 --sink-uri="mysql://root:PassWdGr@1.1.8.18:4001/" --changefeed-id="v740-2-v741-1" --config=cdc.yaml
`Error: [CDC:ErrSinkURIInvalid]sink uri invalid 'protocol is incompatible with mysql scheme'`
cdc cli changefeed create --pd=http://1.1.8.16:23794 --sink-uri="mysql://root:PassWdGr@1.1.8.18:4001/" --changefeed-id="v740-2-v741-1" --config=cdc.yaml
Create changefeed successfully!
ID: v740-2-v741-1
@h5n1 I couldn’t reproduce this issue using cdc 7.4.0 (Git Commit Hash: 744211d931db53bdce429063a64f4db8bf4ad3bf). Please provide the cdc.yaml content and cdc logs, thank you.
ARM platform
[2023/11/06 17:28:37.710 +08:00] [ERROR] [tso_dispatcher.go:557] [“[tso] update connection contexts failed”] [dc=global] [error=“rpc error: code = Canceled desc = context canceled”]
[2023/11/06 17:28:37.710 +08:00] [INFO] [tso_dispatcher.go:240] [“exit tso dispatcher loop”]
[2023/11/06 17:28:37.711 +08:00] [INFO] [tso_dispatcher.go:186] [“exit tso requests cancel loop”]
[2023/11/06 17:28:37.710 +08:00] [INFO] [resource_manager_client.go:314] [“[resource manager] exit resource token dispatcher”]
[2023/11/06 17:28:37.711 +08:00] [INFO] [tso_dispatcher.go:339] [“[tso] exit tso dispatcher”] [dc-location=global]
[2023/11/06 17:28:37.711 +08:00] [INFO] [pd_service_discovery.go:524] [“[pd] cannot update member from this address”] [address=http://10.125.144.16:23794] [error=“[PD:client:ErrClientGetMember]error:rpc error: code = Canceled desc = context canceled target:10.125.144.16:23794 status:READY: error:rpc error: code = Canceled desc = context canceled target:10.125.144.16:23794 status:READY”]
[2023/11/06 17:28:37.711 +08:00] [ERROR] [pd_service_discovery.go:257] [“[pd] failed to update member”] [urls=“[http://10.125.144.16:23794,http://10.125.144.17:23794,http://10.125.144.18:23794]”] [error=“[PD:client:ErrClientGetMember]error:rpc error: code = Canceled desc = context canceled target:10.125.144.16:23794 status:READY: error:rpc error: code = Canceled desc = context canceled target:10.125.144.16:23794 status:READY”] [errorVerbose=“[PD:client:ErrClientGetMember]error:rpc error: code = Canceled desc = context canceled target:10.125.144.16:23794 status:READY: error:rpc error: code = Canceled desc = context canceled target:10.125.144.16:23794 status:READY\ngithub.com/tikv/pd/client.(*pdServiceDiscovery).updateMember\n\tgithub.com/tikv/pd/client@v0.0.0-20230912103610-2f57a9f050eb/pd_service_discovery.go:529\ngithub.com/tikv/pd/client/retry.(*BackOffer).Exec\n\tgithub.com/tikv/pd/client@v0.0.0-20230912103610-2f57a9f050eb/retry/backoff.go:36\ngithub.com/tikv/pd/client.(*pdServiceDiscovery).updateMemberLoop\n\tgithub.com/tikv/pd/client@v0.0.0-20230912103610-2f57a9f050eb/pd_service_discovery.go:256\nruntime.goexit\n\truntime/asm_arm64.s:1197”]
[2023/11/06 17:28:37.711 +08:00] [INFO] [pd_service_discovery.go:248] [“[pd] exit member loop due to context canceled”]
[2023/11/06 17:28:37.711 +08:00] [INFO] [tso_client.go:134] [“closing tso client”]
[2023/11/06 17:28:37.711 +08:00] [INFO] [tso_client.go:139] [“close tso client”]
[2023/11/06 17:28:37.711 +08:00] [INFO] [tso_client.go:150] [“tso client is closed”]
[2023/11/06 17:28:37.711 +08:00] [INFO] [pd_service_discovery.go:294] [“[pd] close pd service discovery client”]
[2023/11/06 17:28:37.736 +08:00] [INFO] [tso_dispatcher.go:240] [“exit tso dispatcher loop”]
[2023/11/06 17:28:37.736 +08:00] [INFO] [resource_manager_client.go:314] [“[resource manager] exit resource token dispatcher”]
[2023/11/06 17:28:37.736 +08:00] [INFO] [tso_dispatcher.go:405] [“[tso] stop fetching the pending tso requests due to context canceled”] [dc-location=global]
[2023/11/06 17:28:37.736 +08:00] [INFO] [tso_dispatcher.go:186] [“exit tso requests cancel loop”]
[2023/11/06 17:28:37.736 +08:00] [INFO] [tso_dispatcher.go:339] [“[tso] exit tso dispatcher”] [dc-location=global]
[2023/11/06 17:28:37.736 +08:00] [INFO] [pd_service_discovery.go:248] [“[pd] exit member loop due to context canceled”]
[2023/11/06 17:28:37.736 +08:00] [INFO] [tso_client.go:134] [“closing tso client”]
[2023/11/06 17:28:37.736 +08:00] [INFO] [tso_client.go:139] [“close tso client”]
[2023/11/06 17:28:37.736 +08:00] [INFO] [tso_client.go:150] [“tso client is closed”]
[2023/11/06 17:28:37.736 +08:00] [INFO] [pd_service_discovery.go:294] [“[pd] close pd service discovery client”]
[2023/11/06 17:28:37.736 +08:00] [INFO] [middleware.go:49] [/api/v2/changefeeds] [status=400] [method=POST] [path=/api/v2/changefeeds] [query=] [ip=10.125.144.16] [user-agent=Go-http-client/1.1] [client-version=v6.6.0] [error=“[CDC:ErrSinkURIInvalid]sink uri invalid ‘protocol is incompatible with mysql scheme’”] [errorVerbose=“[CDC:ErrSinkURIInvalid]sink uri invalid ‘protocol is incompatible with mysql scheme’\ngithub.com/pingcap/errors.AddStack\n\tgithub.com/pingcap/errors@v0.11.5-0.20221009092201-b66cddb77c32/errors.go:174\ngithub.com/pingcap/errors.(*Error).GenWithStackByArgs\n\tgithub.com/pingcap/errors@v0.11.5-0.20221009092201-b66cddb77c32/normalize.go:164\ngithub.com/pingcap/tiflow/pkg/config.(*SinkConfig).validateAndAdjustSinkURI\n\tgithub.com/pingcap/tiflow/pkg/config/sink.go:722\ngithub.com/pingcap/tiflow/pkg/config.(*SinkConfig).validateAndAdjust\n\tgithub.com/pingcap/tiflow/pkg/config/sink.go:574\ngithub.com/pingcap/tiflow/pkg/config.(*ReplicaConfig).ValidateAndAdjust\n\tgithub.com/pingcap/tiflow/pkg/config/replica_config.go:198\ngithub.com/pingcap/tiflow/cdc/api/v2.APIV2HelpersImpl.verifyCreateChangefeedConfig\n\tgithub.com/pingcap/tiflow/cdc/api/v2/api_helpers.go:204\ngithub.com/pingcap/tiflow/cdc/api/v2.(*OpenAPIV2).createChangefeed\n\tgithub.com/pingcap/tiflow/cdc/api/v2/changefeed.go:105\ngithub.com/gin-gonic/gin.(*Context).Next\n\tgithub.com/gin-gonic/gin@v1.8.1/context.go:173\ngithub.com/pingcap/tiflow/cdc/api/v2.RegisterOpenAPIV2Routes.ForwardToControllerMiddleware.func4\n\tgithub.com/pingcap/tiflow/cdc/api/middleware/middleware.go:96\ngithub.com/gin-gonic/gin.(*Context).Next\n\tgithub.com/gin-gonic/gin@v1.8.1/context.go:173\ngithub.com/pingcap/tiflow/cdc/api/v2.RegisterOpenAPIV2Routes.ErrorHandleMiddleware.func3\n\tgithub.com/pingcap/tiflow/cdc/api/middleware/middleware.go:65\ngithub.com/gin-gonic/gin.(*Context).Next\n\tgithub.com/gin-gonic/gin@v1.8.1/context.go:173\ngithub.com/pingcap/tiflow/cdc/api/v2.RegisterOpenAPIV2Routes.LogMiddleware.func2\n\tgithub.com/pingcap/tiflow/cdc/api/middleware/middleware.go:39\ngithub.com/gin-gonic/gin.(*Context).Next\n\tgithub.com/gin-gonic/gin@v1.8.1/context.go:173\ngithub.com/pingcap/tiflow/cdc/api/v2.RegisterOpenAPIV2Routes.CheckServerReadyMiddleware.func1\n\tgithub.com/pingcap/tiflow/cdc/api/middleware/middleware.go:179\ngithub.com/gin-gonic/gin.(*Context).Next\n\tgithub.com/gin-gonic/gin@v1.8.1/context.go:173\ngithub.com/gin-gonic/gin.CustomRecoveryWithWriter.func1\n\tgithub.com/gin-gonic/gin@v1.8.1/recovery.go:101\ngithub.com/gin-gonic/gin.(*Context).Next\n\tgithub.com/gin-gonic/gin@v1.8.1/context.go:173\ngithub.com/gin-gonic/gin.(*Engine).handleHTTPRequest\n\tgithub.com/gin-gonic/gin@v1.8.1/gin.go:616\ngithub.com/gin-gonic/gin.(*Engine).ServeHTTP\n\tgithub.com/gin-gonic/gin@v1.8.1/gin.go:572\nnet/http.serverHandler.ServeHTTP\n\tnet/http/server.go:2938\nnet/http.(*conn).serve\n\tnet/http/server.go:2009\nruntime.goexit\n\truntime/asm_arm64.s:1197”] [duration=38.072219ms]
bdr-mode = true
[filter]
rules = [‘sbtest.*’]
[mounter]
worker-num = 24
The current CDC client you are using is version 6.6.0, which does not match the server version.
It is recommended to upgrade to the corresponding server version and try again.
I was able to reproduce this issue using v6.6.0 CDC and v7.4.0 TiDB. The combination of v7.4.0 CDC and v7.4.0 TiDB is OK.
Are there any significant differences between these two versions? Although there are two versions between 7.1 and 7.4, this isn’t a special command for a new version, so shouldn’t compatibility be maintained?
The compatibility between CDC and TiDB is such that a higher CDC version, like CDC 7.4, is supported with TiDB 7.1. However, the reverse is not guaranteed.
What exactly needs to be done?
Please create a new post and describe the specific situation of the problem more clearly.
This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.