FTS incorrectly uses the alternate addresses set for a node for DCP streams.
This means in the worst (and common) case where the alternate address is not reachable within the cluster (e.g. it's in Kubernetes and it's a Load Balancer for an individual pod, a fairly common deployment scenario), FTS is completely broken, while indexes can be created they are never built and cannot be searched.
In the best case where the cluster is not deployed in Kubernetes but is using Alternate Addresses for things like XDCR, the DCP traffic is being incorrectly routed out over the public internet rather than the private network as it should be.
This is a regression, FTS works fine in this environment on 6.6.x.
- Spin up the latest RC (I used Docker here):
- Setup the cluster with FTS enabled. Ensure that you set the hostname of the node to its IP and NOT 127.0.0.1 at this step. I also enabled node-to-node encryption, not sure if this is required for reproduction.
- Set an alternate address for your node, you can set this to any URL that will resolve but will not be accessible, I just used a Couchbase Cloud public hostname:
- Restart the cbft process
- Create an Index in the UI
- Try to search the Index
The index search completes successfully
Logs show that FTS is trying to use the external address:
Note that 220.127.116.11 is what cb-0001.76aad0f6-de8a-46d8-9794-47df1b10f91f.dataplane.nonprod-project-avengers.com resolves to:
Also strangely it's trying to use 11210, but node-to-node encryption is enabled, which I would have expected meant that it would try to use encrypted ports.
|For Gerrit Dashboard: MB-47457|
|157795,4||MB-47457: NetworkType:default for gocbcore Agent/DCPAgent configs||cheshire-cat||cbgt||Status: MERGED||+2||+1|
|158183,1||Merge remote-tracking branch 'couchbase/cheshire-cat' into master||master||cbgt||Status: MERGED||+2||+1|
|158600,3||MB-47678: NetworkType:default for gocbcore AgentConfig||master||n1fty||Status: MERGED||+2||+1|
|158601,1||MB-47678: [BP] NetworkType:default for gocbcore AgentConfig||mad-hatter||n1fty||Status: ABANDONED||+2||0|
|159057,2||MB-47457: [BP] NetworkType:default for gocbcore Agent/DCPAgent configs||7.0.0||cbgt||Status: MERGED||+2||+1|
|159201,2||MB-47457: [BP] NetworkType:default for gocbcore Agent/DCPAgent configs||7.0.1||cbgt||Status: MERGED||+2||+1|