Live data from Hacker News

Android now forces apps to include proprietary code for push notifications

reddit.com

231–240 of 284 posts

Re: Android now forces apps to include proprietary code for push notifications

#231
post #174

Earlier quoted context omitted.

But Firebase is not a "kernel", "window system", it is just third-party proprietary library (not essential part of Android as I understand).

I personally would consider notifications and the ability to run in the background to be essential but there's a better test which is the reason that this exception exists in the first place. From copyleft.org: > The system library exception is designed to allow copylefted software to link with these libraries when prohibition of that linking would hurt software freedom more than it would hurt proprietary software. T…

That sort of wishy-washy legal foundation is why people are afraid of the GPL.

Re: Android now forces apps to include proprietary code for push notifications

#232
post #132

Earlier quoted context omitted.

> It doesn't matter how much money Google is going to have to pay in the future as a fine for this practice. The amount of money that they will get for kicking out the competition is going to be way higher. That is a learned lesson from Microsoft (and probably others before them). The competition in this case is Apples iOS, for which even HackerNews users love to harp over and over and over again how amazing it is an…

The difference is Apple has been the same from the beginning. There was no bait and switch. People who bought Apple products knew what Apple was and will be and what the terms were. With Google there is a bait and switch (and it doesn't really just apply to this particular story). They came to market defining themselves as the open alternative to Apple to get market share and developer interest (and evangelism), and…

Exactly. We see the same pattern with Chrome and the new course it's taking.

The reverse is also true: whatever sufficiently good product that doesn't generate money is basically doomed by them no matter how many users depend on it. (Reader, Inbox, Talk, ...)

Re: Android now forces apps to include proprietary code for push notifications

#233

Earlier quoted context omitted.

Tangent, but can I ask what made you choose 9.69.1? I spent hours trying out a bunch of versions and ended up choosing 9.42.3 as it started up fast and was the last version that didn't have the "explore the city" nonsense taking up half the screen on startup. Curious what sweet spot you found in 9.69.1!

When I updated Maps and found out the latest version requires Play Services to start, I just went to apkmirror and grabbed random old version. Or maybe I grabbed one I had in Titanium Backup backups - I don't remember precisely. I actually didn't know what you were talking about until I opened the app few seconds ago. I was just tapping the search bar as soon as the app started every time, and did not even notice som…

Oh I see. Yeah I recommend going back to that version if you don't have a particular reason to stick with the later one. Or maybe to 9.50.1 if you want the ability to add Favorites and Want To Go (as opposed to just Starred Locations). The later versions have way too much crap in them -- over fifty (!) notifications (and redundant ones at that, I'm guessing because people kept turning off the old ones) as of the latest version I tried, with the screen constantly trying to get you to look at it and tap stuff. They're trying to get your attention all the time like they're Facebook or something. They can't just show you a darn map and navigate you anymore. (Though even these versions aren't great, but they're usable.) They made the changes rather gradually though (sometimes even the same version behaves differently depending on whether you upgraded or not) so I'm guessing that's why you didn't notice.

Re: Android now forces apps to include proprietary code for push notifications

#234
post #193

Earlier quoted context omitted.

I agree, it isn't normal, and I was scratching my head at the time as to why FCM would deliver the messages near instantly on older android models . The delayed delivery happened on Oreo+ phones. Oddly, I also noticed Whatsapp not delivering messages in a timely fashion (even when I had it opted out of battery saving). Background notifications in general started acting odd for Oreo+ phones. > There's not enough conte…

Signal switched to FCM about 4 months ago and I've had constant delayed-notifications issues too, usually in the 20 minute range. I can see the problem in Signal itself, the "sent" and "delivered" timestamps will be 20 minutes apart despite be actively doing stuff on my phone -- so the internet connection is there and the phone isn't sleeping. When I actually re-open the Signal app all the notifications flood in at o…

Hey! Signal dev here. We've actually seen delayed notification both before and after the switch to FCM. My guess is that newer Android versions are just becoming more and more aggressive with their battery optimizations.

We send high-priority FCM messages, but the device will still bundle them together in order to deliver them in batches. Even worse, there are times we are delivered an FCM message but network access will be invisibly restricted, further delaying our ability to retrieve the actual message content (for obvious reasons, we can't include the message content in the FCM message itself). We're continuing to try new things, but it'd be nice if there was some official guidelines on how to avoid these FCM pitfalls.

Re: Android now forces apps to include proprietary code for push notifications

#235

Earlier quoted context omitted.

Often times even having configuration options creates surface for security issues. A good example of this is that there were scams that involved having people paste some script into their chrome devtools and steal data. This worked fairly effectively. Facebook ended up doing some magic to show a warning message in the devtools console to tell people that no, you really shouldn't paste random stuff here, it will do ba…

Is the solution to begin, to a degree, treating adults as children?

To answer the question shortly: Yes

But I actually think you are mis-portraying the situation is because I don't think the average adult has the ability to comprehend these things. It's not the difference between adults and children, but adults and expert adults.

Here are some analogies to other parts of society that we don't have a problem with:

Seat belt laws Hard hat required construction area Safety guideline in Handling of hazardous materials

We basically said society doesn't trust you to decide for yourself about your safety - you just have to follow the rule.

Re: Android now forces apps to include proprietary code for push notifications

#236
post #166
post #88

I was confused for a moment because I thought the Firebase SDK was open source. Interestingly, though, the Android version appears to be only partly open source. I did not find an explanation as to why some of the source is not available, it is mentioned on the Github repository but not explained. In any case, I don’t see the code for Cloud Messaging in there. It may not be that it is done out of secrecy, though. A c…

[Firebase team member here] Our goal is to open source all of our SDKs, and we have steadily open-sourced more of them over time. The SDKs you see on GitHub right now are all standalone, they don't require communicating with Google Play services running on the device. Our bar for moving an SDK to GitHub is that it has to be more than a source dump, it must be the source of truth for that team's development. Right now…

Even if the SDK's are open source, a lot of the problems we experience with FCM at Signal seem to be more of an issue with devices trying to optimize battery. Do you have any advice on how to avoid the system heavily delaying notifications? We've seen instances of high-priority notifications being delayed and batched together, even for users who have disabled battery optimizations.

Re: Android now forces apps to include proprietary code for push notifications

#237
post #235

Earlier quoted context omitted.

Is the solution to begin, to a degree, treating adults as children?

To answer the question shortly: Yes But I actually think you are mis-portraying the situation is because I don't think the average adult has the ability to comprehend these things. It's not the difference between adults and children, but adults and expert adults. Here are some analogies to other parts of society that we don't have a problem with: Seat belt laws Hard hat required construction area Safety guideline in…

Except a large portion of society thinks seat belt and hard hat laws are bullshit and shouldn't even be legal to enforce. Hazardous materials handling is completely different though.

Re: Android now forces apps to include proprietary code for push notifications

#238
post #53
post #51

So to summarize, to save battery all notifications on Android (since two versions ago) have to go through a single notification service (rather than each app having the option of continuously running in the background and maintaining a connection with its own notification service). Recently Google killed their GCM notifications service in favor of Firebase Cloud Messaging, which (unlike GCM) unfortunately doesn't hav…

> Are they saying that an application running continuously in the background uses the same amount of battery as an application that's not running at all? A single application running in the background probably uses only a small amount of extra power compared to the notification service alone. However, a couple dozen applications -- all running in the background in order to enable notifications -- probably consume a l…

I can tell you in the old android world. There was a not insignificant chance that 70-80% of apps that needed notifications or syncing did just that.

Re: Android now forces apps to include proprietary code for push notifications

#239

Earlier quoted context omitted.

That still requires cooperation from the SoC vendors. If they aren't interested then Treble will go nowhere.

Treble is required by the Vendor Test Suite for Android 8 and higher. https://source.android.com/devices/architecture

This is probably still in Google's best interest, since it greatly reduces the cost for OEMs to distribute updates (and updates are one area where Android severely lags behind iOS)

Re: Android now forces apps to include proprietary code for push notifications

#240

Earlier quoted context omitted.

Signal switched to FCM about 4 months ago and I've had constant delayed-notifications issues too, usually in the 20 minute range. I can see the problem in Signal itself, the "sent" and "delivered" timestamps will be 20 minutes apart despite be actively doing stuff on my phone -- so the internet connection is there and the phone isn't sleeping. When I actually re-open the Signal app all the notifications flood in at o…

Hey! Signal dev here. We've actually seen delayed notification both before and after the switch to FCM. My guess is that newer Android versions are just becoming more and more aggressive with their battery optimizations. We send high-priority FCM messages, but the device will still bundle them together in order to deliver them in batches. Even worse, there are times we are delivered an FCM message but network access…

Thank you for your work on Signal. Despite my griping, Signal is still my primary messaging app and I love it.

>there are times we are delivered an FCM message but network access will be invisibly restricted, further delaying our ability to retrieve the actual message content

This is new... If this is happening regularly, maybe you should display a generic "message available" notification? I assume actually opening the app un-restricts network access and everything works fine from there -- it'd be nice to know I have a message waiting in limbo.

Post reply on HN