The read-meta handler hardcodes port 3000, which is incorrect when running the server on another port. This causes the Python client to throw a connection refused exception after connecting to a server on another port:
from azure.cosmos import CosmosClient
cosmos = CosmosClient("https://localhost:32797", credential="fake")
list(cosmos.list_databases())
This throws the exception:
<urllib3.connection.HTTPSConnection object at 0x7fd48863dfd0>: Failed to establish a new connection: [Errno 111] Connection refused
due to the client trying to communicate with port 3000, because of the hard coded values.
This can be solved by passing server options to handlers, so that the port can be dynamically generated; this would be a lot of code changes so perhaps there's an easier way to avoid this?
The read-meta handler hardcodes port 3000, which is incorrect when running the server on another port. This causes the Python client to throw a connection refused exception after connecting to a server on another port:
This throws the exception:
due to the client trying to communicate with port 3000, because of the hard coded values.
This can be solved by passing server options to handlers, so that the port can be dynamically generated; this would be a lot of code changes so perhaps there's an easier way to avoid this?