Open ghost opened 6 years ago
+1
You do understand this will kill through battery and still be super NOT reliable?
Well it is still worlds better than NO notifications. Riot (F-Droid version) for example works quite well even with 20 sec checks. The app places a notification icon and it worked for me on Android 6 and 8.1. It was reliable. Now i'm not arguing in some setups this could create issues, but you could take a look how Riot works, it seems quite all right.
I used riot in the passed and there was not that big battery drain same with signal what I'm still using with for example 21mAh over the last 8 h.
I do know that it is probably not that reliable as gcm/fcm but I think for people who live completely without google it is not the biggest downside.
For example signal gives a warning to the user when it is set up without gcm.
I would be really happy if this could be done because then I could drop signal
Kind regards
Maybe in addition the question if there is a technical debt which makes an implementation similar to riot, signal, telegram ... impossible?
@nr458h I used the fdroid Riot for a half a year or so and it was very stable. I used even a faster, 20 sec refresh time. The overall battery time improved only marginally after i installed the google play version.
Maybe one last post to convince you :)
It came to my mind that NC advertises metadata-free communication, so on nextcloud.com/talk it says:
"
Nextcloud Talk goes further than other encrypted communication technologies by keeping metadata private.
While public solutions like Whatsapp or Telegram might encrypt content, they and whomever monitors them still can see who you communicate with and when. With Nextcloud Talk meta data never leaves your server."
With this in mind it could also be an option for the gplay version!
Not metadata-free, just that it's all on your server. Push is the only way to wake up a device. All content in a push message is encrypted with YOUR OWN DEVICE-SPECIFIC KEY which can be verified.
@mario I think people realise the downsides of not using GCM, but as gradinaruvasile said, it's still better than not getting notifications at all (or being forced to install MicroG for one app). And other apps have been doing this for quite a while now. Not as the primary or ideal way of delivering notifications, but as an alternative method for app versions delivered outside of the Playstore and for people using custom ROMs without Gapps.
If that's not a priority for you right now, it's totally fine, but people know what they're asking for.
+1, @DudleyDursley summarized it perfectly.
A little repetition for newcomers (original link): the only thing I wish I knew is how WhatsApp does it as it works perfectly and shows no "permanent notification" at all (maybe a hidden notification? I know the icon can be hidden but whole notification?) without any noticeable battery drain. Facebook Messenger works the same at least for calls (I receive calls immediately, messages often slip by without notification..). I am running LineageOS 14.1 (Android 7.1.2) without any Google licensed apps.
Edit: added original link and also a correction: today even the Messenger works great for message notifications
+1, @DudleyDursley summarized it perfectly.
Only workaround with f-droid I know is using something like the https://delta.chat Email-Messenger, to ask each other to call back.
The situation could be improved of course:
And there are at least two ways to solve the push issue properly:
In case you haven't seen it: Battery consumption in deltachat is down to 1% (seems less than what gcm would use if it were installed) and reliability is good since v0.18.2
@testbird, it's fine! Is there any overhead of IMAP-push notifications compared to GCM?
Don't have any comparison, but the Email-chat spec that deltachat uses sure leaves room for some Email-notify spec that could minimize the overhead.
+1
I think they should have been upfront about the fdroid version not having notofications, I have been trying to solve the problem since a month... This is how Telegram F-droid seems to solve it:
The app is kinda useless without notification.
We are VERY upfront about not supporting notifications if you install from F-Droid, in addition to me responding to queries and issues on all possible mediums (twitter, forums, github).
You're free to implement another service which the app will connect to, Nextcloud connector and a patch for the Android app which I'm happy to review and merge if it's good enough. But like the above post says (from Telegram) it's nowhere near anything I'd call good UX.
Thanks for the info mate. Notification support is written on the NCTalk page on F-Droid, I find it misleading...
@Bubu can you pls check why was F-Droid README not updated despite me updating the fastline files? Do we maybe need one stable release before it happens?
Do we maybe need one stable release before it happens?
Yes. Not sure if that's intended behaviour on f-droid side but that's what the code currently does :woman_shrugging: .
Not wanting to add oil to the fire, but adding a +1. My hope was that nextcloud talk could replace telegram for some of my use cases but now that it doesn't have notifications for my setup I think i need to be a little more patient / implement it myself. 🙂 I like the way telegram handles notifications, sad that Google blocked that in 8.
This bothers me.
The Nextcloud ecosystem should not have any Google dependencies whatsoever.
If you are going to depend on features from the Google ecosystem then might as well not bother using Nextcloud at all in the first place.
So really the trichotomy is:
I think there's no reason to not implement notifications without GCM. (except maybe it's "easier" to just give up and use the google libraries)
Conversations (XMPP) does it, K-9 Mail (IMAP) does it. Yes, I exclude them from the battery optimization, however they use almost no battery, especially when compared to the google bloatware,
Long lived connections with no traffic don't really drain the battery, so it should be simple to just implement a notification based on websocket.
https://en.wikipedia.org/wiki/WebSocket https://stackoverflow.com/questions/12054412/are-websockets-adapted-to-very-long-lived-connections
@hoellen - wow
Sorry people, but I've written quite a few times why it's not as easy as you make it out to be.
I have personally invested both my own free time and time of Nextcloud (the company) to make Nc Talk available on F-Droid and so have the guys behind F-Droid (thanks @Bubu, a lot!!!). I would be the first one to implement notifications there if it was technically possible.
Sure, there are workarounds, but not in cases we need - near real-time call notification.
@mario I've tested the F-Droid version again and at least the text chat seems to be able to poll the server for new messages. Would it be possible to do that on a semi-regular interval and produce a notification?
@mario, first a big thanks to you and everyone making it possible to have nc talk available in F-Droid.
While I would agree that it is not as easy as just including the google libraries (google likes to make it easy for developers to say "screw it" and to just use their closed-source stuff), and that it might require more work than is currently available (after all, the focus might not be on those pesky f-droid users), I have to strongly disagree on you that it would be not technically possible. As mentioned earlier, all it would require is a long-lived connection (be it websockets or something else) through which the notification can be sent. BTW, the same channel could also be used to get notified on file changes, not only on mobile but also on the desktop which would be a lot better than the 30 second polling that it currently used.
"All it would require" is a very bold statement given that Google and/or various OEM implementations would kill the background service doing this relatively often, even if you ignore battery optimisations (which is bad UX anyway).
(Btw. I'm one of the pesky F-Droid users :P)
@mario, basically google is trying to shit on all apps not using their libraries by saying it is in the name of battery optimization. These attacks on the open nature of AOSP were starting early: https://arstechnica.com/gadgets/2018/07/googles-iron-grip-on-android-controlling-open-source-by-any-means-necessary/
At the moment it is still possible to do though (see K-9 mail, see conversations). And regarding bad UX, having a small dialog pop up asking you to disable optimizations with an OK button just like conversations does shouldn't be too complicated for the average F-Droid users (Normal users will just use the playstore version anyways) Yes, I know about some OEM implementation that are doing even more crap regarding killing background apps, but as mentioned there are two valid options
Hm as nextcloud clients always have their own server (obviously) it might be legit to use it directly. ;-) I mean even without putting the code into a shared library to collaborate on something quite useful like https://gitlab.com/foss-push/planning
See in this article https://f-droid.org/en/2018/09/03/replacing-gcm-in-tutanota.html that "tutanota" already implemented (stand-alone) an extension for the server side events (SSE) of the HTTP spec, to allow pushing events for multiple accounts over one connection.
SSE => https://en.wikipedia.org/wiki/Server-sent_events https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events
@mpfau @charlag @bedhub A note concerning the tutanota gcm article:
Wikipedia points to this PHP library for Server Side Event support: https://github.com/hoaproject/Eventsource
Docs: https://hoa-project.net/En/Literature/Hack/Eventsource.html
EDIT: comparison of SSE, websockets, and webpush: https://www.fastly.com/blog/server-sent-events-fastly
@mario Do the recent Websocket-related commits have something to do with this?
No, sorry.
On Wed, 17 Oct 2018, 15:29 Laszlo Kertesz, notifications@github.com wrote:
@mario https://github.com/mario Do the recent Websocket-related commits have something to do with this?
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/nextcloud/talk-android/issues/257#issuecomment-430628527, or mute the thread https://github.com/notifications/unsubscribe-auth/AAAWshRG59GbuPhbx6bAPfdCQBMHPg7-ks5ulzDFgaJpZM4VcfIC .
If you run Signal without Google Play Services installed, then Signal defaults to a "constant connection" and the device still receives timely notifications.
I believe this is a good example of an app which works both with and without Google Play Services.
I am commenting on this issue to point that out, as well as to express that this is heavily desired by fans and serious users of Nextcloud. For instance, in my association, we set out to self-host an F-Droid repo with the Nextcloud apps that we all use, but we have a hard policy of not distributing any closed software, which means we only are distributing the F-Droid build of Nextcloud Talk. Until we can receive notifications, this build of the app is all but useless to us. We are reduced to just using it for scheduled group meetings.
Another reason for google-independent notification
Sorry people, but I've written quite a few times why it's not as easy as you make it out to be.
What are the specific hurdles to overcome?
I don't know, if not collaborating with others to create a shared mobile push client (https://gitlab.com/foss-push/planning), existing server-side-events libraries for php/java/c and exiting code examples (see posts above) may ease integrating fully fledged push messaging in the nextcloud server, and the clients.
But maybe the current client-server connection can work as it is, even if it is not optimized for idling? At least in the beginning for experimenting?
The android client would need to emit a permanent notification with display-off events (and remove it with display-on events), to keep the app running permanently in the background (only listening on the idle connection), even when the phone is in the doze state. (Allows incoming calls to wake up the phone.) For a working code example for that look in this pull request: https://github.com/deltachat/deltachat-android/pull/389
Adding the permanent running option should be independent from whether in the end the SSE http extension may be the better protocol for maintaining and reestablishing mobile connections on the fly.
Would it be a lot of effort to create a F-Droid repository for the Play Store version of Nextcloud Talk? Then I could get that version from F-Droid and use microG for notifications.
@qoheniac that I can look into eventually, but soon there won't be a need for that as Google is Open sourcing the Firebase library. :)
@qoheniac that I can look into eventually, but soon there won't be a need for that as Google is Open sourcing the Firebase library. :)
And this means that we will have to install the push server and an option in Nextcloud to use it?
I guess it means that including Firebase wouldn't hurt F-Droid's rules anymore so that you could then use FCM with the version downloaded from F-Droid just like now with the Play Store version. You would still rely on microG Service Core (or Google Play Services).
@gradinaruvasile no, what this means is that FDroid will be able to build a regular flavour of the Talk app and those with MicroG will have Push functionality even when app was installed from FDroid.
So @qoheniac was right :)
It is absolutely not easy to implement a GCM free solution but there are also success stories, see this report :
@cron0mat this was already mentioned by @testbird above in https://github.com/nextcloud/talk-android/issues/257#issuecomment-423903883 :)
Another issue apart from missing notifications is also apparently that after ~10 minutes, you are dropped from an ongoing call. It just happened to me twice directly after another.
@mario I know that this is extra work – Signal, Riot and Telegram all support this via a permanent notification. We are at a stage where we need all these early adopters and people from the free & open source software community, where we come from. :) Also, Nextcloud’s main premise is to provide a great alternative to Google services, so we shouldn’t rely on them.
Another issue apart from missing notifications is also apparently that after ~10 minutes, you are dropped from an ongoing call. It just happened to me twice directly after another.
That doesn't really sound like it's related to the no-push support. At least it really shouldn't be.
In #58 it was asked to release an version to F-droid , thanks that this happend. Also there were a huge discussion related to #75, why not to use gcm/fcm. To summarize, there are users which have concerns to use Google- infrastructer in anyway.
75 was closed because of the relation to #58.
But now we do have a gcm/fcm free version of talk so I would like to ask to support notifications in this version. My proposal would be to handle it like every other open source messenger like telegram, signal or riot by keeping it in foreground through a notification.
Thanks in advance! And please keep up the great work.