News for hackers. Stuff that matters.
Re:SQLite and Android N (2016) by izacus on Friday January 27, 2017 @06:43AM (#13499174)
Ugh, if you were linking against system sqlite you had problems RIGHT NOW before Android N.

sqlite.so isn't part of public Android API surface, which means the OEMs will regularly replace it, break it, compile it with strange options and deal a lot of pain to you and your users.

So if you weren't shipping your own native SQLite in NDK/Xamarin you already had problems, you just maybe didn't notice them.

Android N is now actually actively preventing linking against system libraries which aren't part of public API surface, which is good - it'll result in less developers doing dumb things which break on minor updates.

Re:SQLite and Android N (2016) by pawadu on Friday January 27, 2017 @10:08AM (#13500181)
> it'll result in less developers doing dumb things which break on minor updates.

You can never stop the Facebook developers doing dumb things on Android.

Google have tried for years, but Facebook always manages to find new ways to fuck up.

Re:SQLite and Android N (2016) by oblio on Friday January 27, 2017 @10:30AM (#13500323)
They're not dumb, they're challenges! Preferably challenges solved by creating new VMs, compilers and other interesting development projects ;)
Re:SQLite and Android N (2016) by pawadu on Friday January 27, 2017 @11:04AM (#13500544)
Yeah, challenges Facebook themselves created by writing the most bloat app ever written

https://www.facebook.com/notes/facebook-engineering/under-th...

Re:SQLite and Android N (2016) by iainmerrick on Friday January 27, 2017 @11:11AM (#13500576)
Facebook is one of the most feature-rich apps available for Android. With features like push notifications, news feed, and an embedded version of Facebook Messenger (a complete app in its own right) all working together in real-time, the complexity and volume of code creates technical challenges that few, if any, other Android developers face

I've never understood why the Facebook client is so heavy. That isn't a long list of features! It seems like the requirements could be written on the back of an envelope.

Obviously part of the reason is that they move fast and have a lot of developers, so there's much more pressure to add code than to keep it trimmed down. But the client still doesn't do all that much. Surely, surely most of the logic is handled on the server.

Re:SQLite and Android N (2016) by lxgr on Friday January 27, 2017 @11:52AM (#13500871)
I've noticed they are now doing a similar thing now for push notifications.

Instead of using the platform-provided, battery efficient GCM (now FCM), they insist on using their own MQTT push solution.

Not only does this require a constantly running background service and a TCP socket which has to be reopened on every connectivity change (e.g. a switch from wi-fi to mobile data): They do it for every single one of their apps.

My phone has at least three of them (Instagram, Facebook, Messsenger), and I'm pretty sure that this is a major reason for battery life problems on Android.

Re:SQLite and Android N (2016) by yegle on Friday January 27, 2017 @12:08PM (#13500985)
You can at least uninstall Facebook.app: use m.facebook.com in chrome, you can even get push notification via Chrome.
Re:SQLite and Android N (2016) by j_s on Friday January 27, 2017 @12:23PM (#13501100)
Re:SQLite and Android N (2016) by NoGravitas on Friday January 27, 2017 @01:49PM (#13501668)
The Facebook mobile web page has been going through so much churn lately, I feel like they are working to make it less desirable relative to the app. Disabling access to messages was one of the big ones, but they also regularly change how the sharing links work (to where you can or cannot share from a given action). One of the most recent and enjoyable changes is that the unread count badge on notifications updates in the background, but the actual notification drop down doesn't. You have to go to the notifications page (see all notifications) to see what the new notification actually is.
Re:SQLite and Android N (2016) by parthdesai on Friday January 27, 2017 @03:52PM (#13502566)
And can use firefox to access messenger.
Re:SQLite and Android N (2016) by lultimouomo on Friday January 27, 2017 @10:57AM (#13500496)
But the point is that you ship your own copy of SQLite you still have a problem. You need to make sure that a database is never accessed both through the android wrapper and you own sqlite copy, or you will face corruption. Seems trivial, but when you take into consideration things like Xamarin and third party libraries, it's not so clear-cut.
Re:SQLite and Android N (2016) by izacus on Friday January 27, 2017 @11:48AM (#13500836)
Hmm, I dunno, I kinda thought that not mixing sqlite versions would be a pretty obvious thing.

Xamarin, Cordova and others are pretty much a cesspool of catastrophically poor libraries so I'm not sure why Google has to take the blame for that.