Couchbase API Port is 8092 but the config examples put <ip>:8091 addresses. why?
Hi there
I have Couchbase 2.0 running on a remote server under Ubuntu. (2 Servers)
To be able to access the data for API read/write we have opened the following ports in the firewall:
(according to this documentation: http://www.couchbase.com/docs/couchbase-manual-2.0/couchbase-network-por...)
8092 (Couchbase API Port)
11209 (Internal Cluster Port)
11210 (Internal Cluster Port)
The same documentation reads as if the Port 8091 ist the "Web Administration Port" and must only be open for Administration. (Not for client Access)
Which is good. So we don't have to open that port. (security)
But to my surprise, all .NET client documentation suggest the following web.config:
<?xml version="1.0"?>
<configuration>
<configSections>
<section name="couchbase" type="Couchbase.Configuration.CouchbaseClientSection, Couchbase"/>
</configSections>
<couchbase>
<servers bucket="default" bucketPassword="">
<add uri="http://192.168.0.2:8091/pools"/>
<add uri="http://192.168.0.3:8091/pools"/>
</servers>
</couchbase>
</configuration>(see documentation here: http://www.couchbase.com/docs/couchbase-sdk-net-1.2/configuration.html)
SO MY QUESTION IS:
Why should I use Port 8091 for client access to Couchbase?? When the documentation clearly states otherwise?
Why doesn't it have to be:
...
<servers bucket="default" bucketPassword="">
<add uri="http://192.168.0.2:8092/pools"/>
<add uri="http://192.168.0.3:8092/pools"/>
</servers>
...Could anybody in the know please enlighten me here?
Many thanks!
Jimmy
Hi Jimmy,
As this doc mentions: http://www.couchbase.com/docs/couchbase-manual-2.0/couchbase-network-por..., while 8091 is the port used for the web admin console, it is also used for cluster administration as well.
Since the Couchbase clients are topology aware, they need to be able to connect to port 8091 of any of the nodes in the cluster and get the cluster topology map.
This is done using the REST API (http://www.couchbase.com/docs/couchbase-manual-1.8/restspi-bootstrapping...)
This is how the client knows which node a document lives on and can directly access the document that that node.