threema-web icon indicating copy to clipboard operation
threema-web copied to clipboard

Let the app reconnect to the server when not using FCM

Open ghost opened this issue 6 years ago • 7 comments

Expected Behavior

Threema Web session restarting needs to work over polling / non-GCM, without me manually picking up my phone to restart the session. It loses the connection all the time (I don't have any such issue ever with any other IM, by the way), and on top of all things it tells me "well we can't do this for you without push, you gotta open up your phone".

Current Behavior

I need to manually fiddle with my phone to restart the session. Not acceptable for regular every day use.

Possible Solution

I might be wrong, but to me as a user the message sounds like "we were too lazy to implement this correctly without GCM". You poll for messages anyway, shouldn't it be trivial to automatically poll for this thing too? And before you say "but then we need to wait for the phone to poll before the session gets restarted", I suggest you add a longer timeout for the session to get thrown out and ask the phone earlier when a session looks about to become stale? If this is truly not possible with your current design, then maybe you should rethink your protocol design.

Steps to Reproduce (for bugs)

  1. Use threema web in combination with a phone without google services installed
  2. Get thrown out (happens all the time, just have some patience)
  3. Get upset because it's handled so poorly and requires manually picking up the phone all the time

Your Environment

  • Threema Web version: 1.8.2
  • Threema for Android version: 3.41.413
  • Threema for Android source: threema website / store
  • Browser name and version: firefox 61.0a1 (2018-03-28) (64-bit)
  • Operating system and version: fedora 27 (gnu/linux)

ghost avatar Mar 30 '18 16:03 ghost

There's some relevant discussion in #483.

dbrgn avatar Mar 31 '18 12:03 dbrgn

What I don't understand, from my tests (of course I can't test this well as someone without developer insight into this app, so take this with a grain of salt) even a very short interruption of a few seconds won't be recovered from. E.g. wifi -> mobile data will often throw me out, or if there's some other small hiccup. Wouldn't this be trivial to implement, and without even requiring this to work over polling or anything? The phone app could just use a timer after a disconnect to retry automatically for 1-2 times before it gives up and requires me to manually press the button.

ghost avatar Apr 15 '18 20:04 ghost

It wouldn't be trivial, but it would be doable without too much hassle. I'll try to have a look sometime, although the main priority right now is iOS.

dbrgn avatar Apr 15 '18 20:04 dbrgn

Thanks! It would make a huge difference if at least those small hiccups wouldn't happen, those simply add up over time and it does become a bit exhausting.

I know microG would solve this, but since it requires a custom OS build (I'm on LineageOS where it doesn't seem to be supported on the standard builds) and it still appears to rely on google infrastructure stuff, it makes me wary :frowning: so it'd be cool if this worked better without it.

ghost avatar Apr 15 '18 21:04 ghost

I know microG would solve this, but since it requires a custom OS build (I'm on LineageOS where it doesn't seem to be supported on the standard builds)

What about https://lineage.microg.org/? :smiley:

rugk avatar Apr 15 '18 21:04 rugk

@rugk that's what I said, isn't it? It's a custom build, a fork of sorts if you will. Android is already splintered enough with LineageOS seemingly sometimes taking a while to get improvements to all devices (not that I'm complaining, that's just the reality of it), I'm not sure I want to move to an even more niche build...

Edit: sorry, realizing custom build sounds like self-built. I meant it's another unofficial build of LineageOS.

ghost avatar Apr 15 '18 21:04 ghost

Indeed, but it is really only a small "fork". It's rather a automatic build system, which applies a small patch and compiles all LineageOS stuff. You usually get the same updates as with original LineageOS. Maybe 1 or 2 days later, but that's acceptable IMHO.

rugk avatar Apr 16 '18 15:04 rugk