You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@pulsar.apache.org by Apache Pulsar Slack <ap...@gmail.com> on 2018/12/31 09:11:02 UTC
Slack digest for #general - 2018-12-31
2018-12-30 18:01:46 UTC - Facundo Rodriguez: If I want to build a consumer via websocket I have to produce via websocket? Because I build a producer using Pulsa client when I a consumer user the Pulsar client works perfectly but when I want to consume from a ReactJS componen via websocket the handshake returns 400 instead of 101
----
2018-12-30 21:09:27 UTC - Sijie Guo: > If I want to build a consumer via websocket I have to produce via websocket?
no. you don’t need to produce via websocket.
> the handshake returns 400 instead of 101
make sure you are using the right topic name
----
2018-12-31 00:37:20 UTC - Facundo Rodriguez: this is mi producer `producer = client.create_producer('<persistent://public/default/orderbook/pair>')`
and this is my consumer
```
TOPIC = '<ws://localhost:8080/ws/v2/consumer/persistent/public/default/orderbook/pair/suscription-1>'
async def orderbook_consumer():
async with websockets.connect(TOPIC) as websocket:
data = await websocket.recv()
print(f"< {data}")
```
----
2018-12-31 00:40:33 UTC - Sijie Guo: @Facundo Rodriguez ah it might be related encoding regarding “ordering/pair”.
can you try ‘<persistent://public/default/orderbook_pair>’ (let try not use ‘/’ in the topic name)
----
2018-12-31 01:00:28 UTC - Facundo Rodriguez: It works! Thank you so much!!
----
2018-12-31 01:00:33 UTC - Facundo Rodriguez: An happy new year!
----
2018-12-31 01:00:48 UTC - Sijie Guo: Happy new year!
----
2018-12-31 07:09:41 UTC - Samuel Sun: Hi , one simple question, if there are two clusters under one namespace, and create a topic under this namespace, this topic will be in which cluster ?
----