mirror of
https://github.com/binwiederhier/ntfy.git
synced 2026-05-09 08:26:00 +02:00
[GH-ISSUE #23] Android, Feature Request: allow subscribing to multiple topics #21
Labels
No labels
ai-generated
android-app
android-app
android-app
🪲 bug
build
build
dependencies
docs
enhancement
enhancement
🔥 HOT
in-progress 🏃
ios
prio:low
prio:low
pull-request
question
🔒 security
server
server
unified-push
web-app
website
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/ntfy#21
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @aslmx on GitHub (Nov 25, 2021).
Original GitHub issue: https://github.com/binwiederhier/ntfy/issues/23
The Web and curl allow for subscribing to multiple topics, like this:
That does not work in the app currently, but would make "following" multiple topics easier.
@binwiederhier commented on GitHub (Nov 26, 2021):
So you can obviously subscribe to multiple topics in the app by clicking the + button. So are you talking about
A. Subscribing to multiple topics in the same add dialog box? So that you'd enter a comma separated list and you'd only see one entry in the main view?
B. Or just a more convenient way to add multiple topics at once?
I think it would help if you described your preferred screen flow and text boxes. Sorry I'm just not quite grasping what's missing.
@aslmx commented on GitHub (Nov 26, 2021):
Yeah, valid question - sorry, could have given more details!
Actually i thought about usecase A, having multiple topic subscriptions under one entry that can be added at once (and of course later be changed).
I'm not sure how you handle the long running http connection.
I'm not competent to check the source of the app and evaluate it myself, hence asking: would there a be a difference of listening to two topics in one http request (so letting the server decide to send you posts two either of the topic) or querying multiple topcis with it's own separate subscription?
If there is no difference, you might as well just allow adding two topics by comma separation and after the user clicked "Add" separate it into two individual subscriptions.
If it doesn't make any performance difference then I think it is up to you to decide.
Could as well add more UI complexity by asking the user. But i thought the simplest solution is to just copy what you support via WebUi and cURL, which is usecase A.
@binwiederhier commented on GitHub (Nov 26, 2021):
I made the comma-separated multi-topic subscription especially for the Android app. The app only keeps one connection per host to avoid using double the battery.
Example: If you subscribe to
topic1, it'll listen tohttps://ntfy.sh/topic1/json. If you then addtopic2, it'll break the first connection and restart it ashttps://ntfy.sh/topic1,topic2/json. There is a little bit of UI-trickery to avoid showing that we're reconnecting, but that's what's happening.I can absolutely do that, though the "Subscribe to topic" dialog is already too crowded, so I fear another sentence a la "You may enter a comma-separated list to subscribe to multiple topics" is gonna be a little much. I'll experiment a bit. Though I am leaning towards not changing it.
If you're mainly worried about the annoyance of having to re-enter your home-server IP/address, I just added an automatic auto-fill to avoid that (see https://github.com/binwiederhier/ntfy/issues/13). In this screenshot, the server address is auto-filled, because it's the server that you've already used before. If there's more than one, there's a drop-down too now (this is not released yet):