Channels are being created as groups

185 views
Skip to first unread message

Soy yo

unread,
Mar 13, 2021, 10:55:33 AM3/13/21
to Tinode General
Server version: v0.17.0-alpha1

I am trying to create a channel but Tinode creates a group. As you can see I send

topic:"nch993247 

but it creates topic:

grppZxz5K8umHo 

What I am doing wrong? 
 

I2021/03/13 15:31:39 grpc in: hi:<id:"387904" user_agent:"php/grpc" ver:"1" lang:"es-ES" >  s3soP3kCbNA
I2021/03/13 15:31:39 grpc in: login:<id:"782354" scheme:"token" secret:"\266\323\3202\336P\365\254\236\014_`\036\000\001\000\001\000\377_\320Ih\305\271\315\336\322\274qU\364\262\334\300\271\363.\035\266\267\315\220\024\312\351^\177\326\335" > auth_level:ROOT  s3soP3kCbNA
I2021/03/13 15:31:39 grpc in: sub:<id:"695493" topic:"nch993247" set_query:<desc:<public:"{\"fn\":\"canal\",\"photo\":{\"type\":\"jpeg\",\"data\":\"\\/9j\\/4AAQSkZJR......
I2021/03/13 15:31:39 in: '{"get":{"id":"108033","topic":"me","what":"sub","sub":{"topic":"grppZxz5K8umHo"}}}' sid='riCCOiSHzNY' uid='HGshCFWe5aI'

The same when I create a channel in the webapp on sandbox.tinode.co. I Create a topic, check the box to make it as a channel but Tinode creates a group and all subscribed users can post messages.

Thanks.

Gene

unread,
Mar 13, 2021, 11:56:44 AM3/13/21
to Tinode General
It's working as intended.
Channels are groups. The owner of a channel interacts with the channel in the same was as with the group. 

Soy yo

unread,
Mar 13, 2021, 12:02:29 PM3/13/21
to Tinode General
Yes, but why channel subscribers can send messages to the channel? If it's so, what is the difference between a group and a channel?

Gene

unread,
Mar 13, 2021, 12:05:14 PM3/13/21
to Tinode General
On Saturday, March 13, 2021 at 9:02:29 AM UTC-8 Soy yo wrote:
Yes, but why channel subscribers can send messages to the channel? If it's so, what is the difference between a group and a channel?

Probably because instead of being subscribed to a channel they are subscribed to a group.

Soy yo

unread,
Mar 13, 2021, 1:38:24 PM3/13/21
to Tinode General
There is some contradiction here.

Well, I crate a channel as described in Tinode's documentation:

Channel topic is created by sending {sub topic="nch"}  

I was thinking that if request comes with nch, Tinode will automatically create correct permissions for that topic - all permissions to the owner and only join, read, presence permissions for subscribers.

To create a channel I sent something like this: nch126534. And I was expecting to get the new topic ID something like this:  chnAbC123  but I got grpAbC123 . The same happened on sandbox.tinode.co, I tried it 2 times and both times checked the box "it's a channel".

Documentation says:

Sending {sub topic="chnAbC123"} will create a reader subscription to a channel. A non-channel topic will reject such subscription request.

this means that Tinode should know that a topic is a channel, not a group. But how user can send topic chnAbC123 if Tinode for a channel created grpAbC123?

Gene

unread,
Mar 13, 2021, 1:45:02 PM3/13/21
to Tinode General
On Saturday, March 13, 2021 at 10:38:24 AM UTC-8 Soy yo wrote:
There is some contradiction here.

Well, I crate a channel as described in Tinode's documentation:

Channel topic is created by sending {sub topic="nch"}  

I was thinking that if request comes with nch, Tinode will automatically create correct permissions for that topic - all permissions to the owner and only join, read, presence permissions for subscribers.

It does.
 

To create a channel I sent something like this: nch126534. And I was expecting to get the new topic ID something like this:  chnAbC123  but I got grpAbC123 . The same happened on sandbox.tinode.co, I tried it 2 times and both times checked the box "it's a channel".

Documentation says:

Sending {sub topic="chnAbC123"} will create a reader subscription to a channel. A non-channel topic will reject such subscription request.

this means that Tinode should know that a topic is a channel, not a group. But how user can send topic chnAbC123 if Tinode for a channel created grpAbC123?

Yes, it does know that it's a channel. I channel reader should send {sub topic="chnAbC123"} just like you said, if the user sending the request is not already subscribed to it as to a group.

You are doing something wrong. I cannot figure out from your explanations what exactly you are doing wrong. You may try to offer a step by step explanation of what you are doing, what you expect to get and what you are getting.

Soy yo

unread,
Mar 13, 2021, 2:04:13 PM3/13/21
to Tinode General
ok, I am explaining with screenshots from sandbox.tinode.co

Alise tries to create a channel so that only she can send messages but not anyone of the subscribers. Sunbscribers should have only READ permission, not WRITE

channel1.png


The channel is ready:

channel2.png


Alise subscribes bob to the channel:

channel3.png


After that Bob gets permissions like for a group, not for a channel. Bon also can send messages to the channel.

channel4.png

It is a channel. Why Tinode gave permissions to Bob to write to the channel? Of course. Alice can remove this permission but in reality she created a group, not a channel, even if checkbox "channel" was checked.

Gene Sokolov

unread,
Mar 13, 2021, 3:36:50 PM3/13/21
to tin...@googlegroups.com
Working as intended.

In your example Bob is a group subscriber, not a channel reader. Bob must subscribe himself to chn123 in order to become a reader.

--
You received this message because you are subscribed to the Google Groups "Tinode General" group.
To unsubscribe from this group and stop receiving emails from it, send an email to tinode+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/tinode/83b3a661-378d-49d0-a19e-b811be9c7719n%40googlegroups.com.

Soy yo

unread,
Mar 13, 2021, 5:44:38 PM3/13/21
to Tinode General
if it's working as intented, why Tinode allows to subscribe to a channel like to a group?

No, something is not working correctly.

1. Alice created a channel  and Tinode assigned this ID for created channel: grpyO8ReZ3ME1s
How people will know that if they want to subscribe to this channel, they have to replace grp to chn in the topics's  ID grpyO8ReZ3ME1s ? And this even doesn't work.

2. I just logged out fom alice's account and logged in as dave. Dave pasted in the browsers address bar the URL with alices's channel:
Dave immetiately got subscribed to alice's channel as a group reader with a possibility to send messages  to the channel:

channel5.png

It means that everyone who knows the channel ID, can enter it in the browser's address bar and get permission to send messages to the channel.

I logged in as alice again and here is a message from dave sent to the channel:

channel8.png

Morever, dave tried to enter in the browser's address bar:


instead of


It didn't work. Entered URL immediately was rewritten back to https://sandbox.tinode.co/#/grpyO8ReZ3ME1s  and dave got blocked:

channel9.png

something is wrong.

I was thinking that in case of a channel there can be only 1 person who can write messages and all other subscriber only can read. 
If it's not so, what is the difference between a group and a channel? Everyone can create a group and add members without writing permission and it will be like a channel.
I did read somewhere that groups can have a few hundred of members but number of subscribers of a channel is unlimited. Why is that so if a channel also can have many people who can post messages?

Gene

unread,
Mar 13, 2021, 8:12:21 PM3/13/21
to Tinode General
On Saturday, March 13, 2021 at 2:44:38 PM UTC-8 Soy yo wrote:
if it's working as intented, why Tinode allows to subscribe to a channel like to a group?

Because it's convenient to designate more that one user who can write to a channel. A channel is like a newspaper. A channel owner is like an editor with designated members as journalists.

No, something is not working correctly.

Yes, what you described below looks like a bug. I'll look into it.

Soy yo

unread,
Mar 15, 2021, 12:16:31 PM3/15/21
to Tinode General
webapp (I don't know about other clients) even can not find channels chnZhKEO9ZqNMw: It works only with grpZhKEO9ZqNMw, and user is subscribed with writing permission.

channel10.png
And I noticed one more thing. If an users is subscribed correctly to a channel, he doesn't get indicators (badges) when new messages arrive. Only on page reload in the webapp appear. This problem I saw some time ago with groups and it was resolved, but now it's the same with channels.

Gene

unread,
Mar 15, 2021, 7:52:47 PM3/15/21
to Tinode General
On Monday, March 15, 2021 at 9:16:31 AM UTC-7 Soy yo wrote:
webapp (I don't know about other clients) even can not find channels chnZhKEO9ZqNMw:

 
It works only with grpZhKEO9ZqNMw, and user is subscribed with writing permission.

channel10.png
And I noticed one more thing. If an users is subscribed correctly to a channel, he doesn't get indicators (badges) when new messages arrive.

It's not implemented for channels in the webapp yet. The notifications of new messages in channels are sent through FCM.

Soy yo

unread,
Mar 16, 2021, 2:06:35 PM3/16/21
to Tinode General
And user leaves a channel by sending topic ID stat starts with chn, not grp, right? One more thing is not working correctly.
If I send a GRPC request leave to unsubscribe some user form a channel, but this user is currently using the webapp, the channel does not disappear from the contacts list and user is being automatically subscribed again to that channel from the webapp. I have not tested in in other clients.

Ons Ta

unread,
Nov 16, 2022, 1:09:40 PM11/16/22
to Tinode General
Has something changed in the channels and now everyone can post? If not, there is a bug.

How to reproduce:

Alice creates a channel "created as channel" and adds dave to thisis channel. Dave also can post to the channel. There is a channel icon in the information but there is no channel icon in the contacts list.

Screenshot:


Gene

unread,
Nov 16, 2022, 1:25:40 PM11/16/22
to Tinode General
It's been always like that. You invite a new member to a group, not a channel. You can't add channel subscribers. They have to join the channel themselves.

Ons Ta

unread,
Nov 16, 2022, 1:48:38 PM11/16/22
to Tinode General
It's been always like that. You invite a new member to a group, not a channel. You can't add channel subscribers. They have to join the channel themselves.

I don't understand. A channel works like a group and a channel at the same time? I create a channel and as a owner can add members (or subscribers) and they can post. But if an user searches for a channel and subscribes to it, he can not post.


 

Gene

unread,
Nov 16, 2022, 2:01:34 PM11/16/22
to Tinode General
On Wednesday, November 16, 2022 at 10:48:38 AM UTC-8 Ons Ta wrote:
It's been always like that. You invite a new member to a group, not a channel. You can't add channel subscribers. They have to join the channel themselves.

I don't understand. A channel works like a group and a channel at the same time? I create a channel and as a owner can add members (or subscribers) and they can post. But if an user searches for a channel and subscribes to it, he can not post.

A channel is a group topic which permits a special type of subscriber - a reader. The members you invite to the channel are exactly like normal group members. They are intended to be your channel co-managers. Then the readers join the channel to read. They do so voluntarily.
 


 

Ons Ta

unread,
Nov 19, 2022, 4:10:26 AM11/19/22
to Tinode General
Thanks, it's clear now. Is there a way to allow subscribers to post while still being a subscriber?  Groups are resource intensive and it would be really great if anyone could post to channels without all the other resource consuming options that groups have.

Gene

unread,
Nov 19, 2022, 12:19:19 PM11/19/22
to Tinode General
On Saturday, November 19, 2022 at 1:10:26 AM UTC-8 Ons Ta wrote:
Thanks, it's clear now. Is there a way to allow subscribers to post while still being a subscriber?  Groups are resource intensive and it would be really great if anyone could post to channels without all the other resource consuming options that groups have.

What's the use case that you are envisioning? I can't see a case when, say a group has 10,000 subscribers and each can send messages.
 

Ons Ta

unread,
Dec 10, 2022, 7:45:50 AM12/10/22
to Tinode General
A use case would be groups without limits on the number of group members. Participating in a group where you are banned from posting is pointless in my opinion, because for a user who can't post, the group is actually a channel.

 In my use case, I don't see much value in being able to give different permissions to users, see who's online, etc., but at the same time worry about too many users in a group causing problems. If a user disturbs the group, they can simply be kicked out without having to grant different permissions. The same can be done in the channel if the user has the right to post, but posts inappropriate texts.

I haven't had experience with groups with say 10,000 members, but from what I can see in groups with say 1,000 members, only a small percentage post, the rest just remain readers, even though they have rights to publish. Therefore, I think that channels with the possibility to publish to everyone would be a useful alternative to groups, because if necessary, members could comment on the texts of other users, but at the same time the channel owner would not have to worry about the number of members being too large.

What would happen if everyone subscribed to a channel with 10 000 subscribers will have write permission (no other permissions), but only the channel creator could delete posts or kick users? These subscribers with write permission will become as normal group members and this channel will face the same problems as a group with too many users?

Gene

unread,
Dec 10, 2022, 11:13:12 AM12/10/22
to Tinode General
Well, if you feel strongly about this use case then please load test it. See what is the maximum number of subscribers a server can take, where the bottlenecks are. Change this value
to 100000 and load test a topic. Share your results here. Thanks.
Reply all
Reply to author
Forward
0 new messages