Closed DavideXX92 closed 8 years ago
Hi Davide, What should be possible at the moment is that a public client can subscribe to a topic, say "test_topic":
public.cli1 $ subscribe test_topic all
Other tenant clients should then be able to publish into that topic, and public receive it:
a.cli1 $ publish public.test_topic hello public.cli1 Got PUB from "a.cli1" , message "hello"
So a.cli1 can publish in "public." topics, but a.cli1 cannot subscribe to a "public." topic. This is for security reasons, if we allowed it a.cli1 would receive messages from other tenants, say b.cli1, which we don't want. It is also not allowed for a public client to publish in tenant topics, e.g. neither of these are allowed:
a.cli1 $ subscribe public.test_topic <- should return Error or a.cli1 $ subscribe test_topic all public.cli1 $ publish a.test_topic hello <- should return Error
There is currently no way "a.cli1" can subscribe to a topic that "public.cli1" can publish into. I have been thinking of adding another reserved group-type maybe like "global." , that tenants can subscribe to (but not publish in) and only public clients publish in. Would this be useful for you? It would be like:
a.cli1 $ subscribe global.news all public.cli1 $ publish global.news "warning system shutdown" a.cli1 Got PUB from "public.cli1" , message "warning system shutdown"
Thank you for your answer, actually I am using only the first scenario you described (a.cli publish while public.cli subscribe) so this solved my problem (I did not find a "publish.topic" example anywhere).
The "global" subscription is interesting but I don't need it for the moment.
Hi, I am using c broker and python client. I ran both a "public" client (public.c1) and a "A" client (a.c2), the "A client" subscribe to "test_topic" and after that the public client publish a message to "test_topic" but the A one does not receive that message (I inverted the subscriber and publisher roles obtaining the same result). From what I read a public client should be seen from every single tenant, is it true?