Why is the "direct database connection" paradigm not welcomed by the Android platform?

When I say “direct database connection”, I wanted to use a JDBC-like driver to invoke and run a query on a remote database in the context of an action, just like using a SQLite database to store local parameters.

Until I realized that I could hardly find any textbooks or documents on the Internet regarding this method of connecting to the database, I thought, regardless of the fact that the unstable Wi-Fi / 3G network, which most if not all Android devices, to connect to the database should be done like this.

Even the Android SDK only supports local database access (aka android.database.sqlite). And he stated in the java.sql description of the API that your own JDBC driver must provide in order to use this API.

Then I began to realize that if I intend to directly connect the database, this is primarily wrong in the Android field.

I have read many books, wikis, and forums, including numerous answers to Stack Overflow. It seems to me that many people are focused on doing something, and discussions began with "How can I create a RESTful web service for my Android device?" However, I need a deep understanding! And I also need authoritative quotes from the original Android developers.

+3
source share
2

( ):

  • : Android JDBC-.

  • : , :

    . ( ) . /, , .

    . , . .

  • : , ( ), HTTP/HTTPS. , () .

  • -: (Android, iPhone ..), - . , JDBC, - , . , DRY ( ), unit test.

+9

, , Wi-Fi/3G , Android, , .

. . JDBC , . , , , , .

+3

Source: https://habr.com/ru/post/1788424/


All Articles