need help on SOLCLIENT_SUBCODE_COMMUNICATION_ERROR
im using the following
broker_props = { "solace.messaging.transport.host": os.environ.get('SOLACE_HOST') or "localhost", "solace.messaging.service.vpn-name": os.environ.get('SOLACE_VPN') or "default", "solace.messaging.authentication.scheme.basic.username": os.environ.get('SOLACE_USERNAME') or "default", "solace.messaging.authentication.scheme.basic.password": os.environ.get('SOLACE_PASSWORD') or "default" }
and running the docker instance using the following:
docker run -d -p 8080:8080 -p 55554:55555 -p 8008:8008 -p 1883:1883 -p 8000:8000 -p 5672:5672 -p 9000:9000 -p 2222:2222 --shm-size=2g --env username_admin_globalaccesslevel=admin --env username_admin_password=admin --name=solace solace/solace-pubsub-standard
i keep running into this error, and i cant find a fix.
raise PubSubPlusCoreClientError(message=core_exception_msg, sub_code=info_sub_code) solace.messaging.errors.pubsubplus_client_error.PubSubPlusCoreClientError: {'caller_description': 'do_connect', 'return_code': 'Not ready', 'sub_code': 'SOLCLIENT_SUBCODE_COMMUNICATION_ERROR', 'error_info_sub_code': 14, 'error_info_contents': 'TCP connection failure for fd 9, error = Connection refused (61)'}
here is my docker container:
856cee91e195 solace/solace-pubsub-standard "/usr/sbin/boot.sh" 2 hours ago Up 56 minutes 0.0.0.0:1883->1883/tcp, 0.0.0.0:2222->2222/tcp, 0.0.0.0:5672->5672/tcp, 0.0.0.0:8000->8000/tcp, 0.0.0.0:8008->8008/tcp, 0.0.0.0:8080->8080/tcp, 0.0.0.0:9000->9000/tcp, 0.0.0.0:55554->55555/tcp solace
i hope yall can help me. thanks!
Comments
-
I don't know if it's deliberate or a typo, but you have mapped port 55554 on the localhost to port 55555 on the broker. The default port is 55555, so you are getting connection refused because there is no listener on port 55555 on localhost.
You have two choices:
1. If it is a typo, fix the docker startup to use '-p 55555:55555'
2. If it is deliberate, then change your broker_props:"solace.messaging.transport.host": os.environ.get('SOLACE_HOST') or "localhost:55554"
2b. Alternatively, if you are using the environment variable SOLACE_HOST be sure it has the port number 55554 included.
1 -
thanks for the support @Ragnar. It was deliberately set to 55554 for MacOS users from the guide in https://solace.com/products/event-broker/software/getting-started/. however, your solution did work, the broker props had to be changed. thank you so much!
1