I am wondering if I could share a singleton on the application context across multiple applications? Each application would be in its own APK but This might sound like bad
It should be possible, but you'll run into problem with the fact that you are still running two different APKs, each has its own ClassLoader. Since the same Class loaded by different ClassLoader are considered completely different from each other, you cannot create a Class from APK A and expect APK B to be able to access that same Class. However, one loophole is that Android system classes in the same process are always loaded by the same ClassLoader, therefore the solution is to store your data through Android system classes (e.g. System.set/getProperty). You can read an excellent article on this technique here.
As you wish to store data more complex than Java primitives and considering the above approach would severely limits the data structure you can store, it may still end up that AIDL is your best bet. But at least your data does not need to cross process boundaries if you put both APKs in the same process, so it should be reasonably efficient.
Yes, they can. You just need to assign same values to android:sharedUserId
and android:process
in both applications and sign them with same certificate.
Related Links: