connecting to PostGIS database connecting to PostGIS database postgresql postgresql

connecting to PostGIS database


Having Android clients connect directly to your database is not a good idea. Creating a web service (such as a REST service) as you mention in your comment is the way to go.

There are several reasons to take this approach:

  • Exposing your database to the internet is bad from a security perspective
  • Tightly coupling your app to the database is bad from a design perspective. With a separate service layer you can:
    • Make changes to the data layer without having to update the app
    • Add caching
    • Add capacity at each layer as needed