Networks for Android

We implement an architecture with several clients, and some of the client applications must work in the Android OS. The first idea that came to mind was to use java RMI, but the RMI api is clearly not implemented for android.

So 1) Is there a way to use java RMI api in an Android application? Can I just import it from the java standard library? 2) What are the possible RMI replacements that will work for both Android and desktop applications?

Thanks.

+6
java android networking rmi
source share
2 answers

RMI is a bad solution for everything that is not stuck on the same subnet. It is scary to recover from failures and with roaming clients.

There are many possible solutions, not limited to

  • HTTP REST style with XML or JSON data
  • JSONRPC / XMLRPC
  • SOAP (not the best for performance)
  • Protocol buffers over sockets (TLS / SSL, please). Consider WebSockets.
+5
source share

If using JAVA / RMI Android with lightweight is possible for your specific scenario, you can see the links below:

+3
source share

All Articles