websocket meet 404 when create producer in standalone mode
See original GitHub issueDescribe the bug This issue is split from issue #5979, which reported by @jeffgrunewald
I am attempting to build and run pulsar locally for development mode but I receive a 404 whenever attempting to connect to the websocket to create a producer due to a missing “serviceUrl” param. I have set this value to my local host/port in the conf/websocket.conf file but the result is the same. Is there somewhere else this should be set or an undocumented requirement for connecting from the websocket client?
I have not experienced this issue when using the standard Pulsar docker image (apache/pulsar:latest) and running the command bin/pulsar standalone as the CMD directive.
Just to be clear, I am attempting this off a clone of the tip of the master branch, not the latest release tarball. I do see in the logs the ConsumerStatsRecorderImpl
Pulsar client config is listing the serviceUrl as "serviceUrl" : "pulsar://127.0.0.1:6650"
. Are the current websocket client connection instructions accurate for the latest unreleased version?
For further context, I am writing a pulsar client library for the Elixir language based on the websocket api. My producer and consumer is connecting to the endpoint ws://localhost:8080/ws/v2/producer/persistent...
where localhost is dynamically supplied as part of the client configuration and my dockerized pulsar for development purposes is mapping the default service port 8080 from the container to the host.
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:6 (4 by maintainers)
Top GitHub Comments
Having the same issue with 2.5.0 standalone.
WS receives unexpected server response: 400 on connect.
Param serviceUrl must not be blank.
This is a complete blocker for anyone using WS. So reverting back to 2.4.2 is working.
@bwalendz 2.5.0 has a regression about initializing websocket introduced from #5486. I am working on a fix.