Using DocumentDB for a mobile GIS app

Category: azure documentdb


dwmontgo on Sun, 18 Sep 2016 18:59:03

I am wondering if using DocumentDB would be appropriate for a mobile GIS app. To better explain my needs, here is a quick breakdown of my app:

  • Android app that uses the Google Maps Android API to allow users to view and submit blocked bike lane incidents in Philadelphia
  • Users will be able to submit incidents to a cloud database, as well as view incidents submitted by other users. Each incident includes info on location, date/time, as well as a photo that will be stored in the database
  • The app is part of a master's thesis project, and funding is limited

I have received suggestions from Azure support to use Parse Server on Managed Azure Services with DocumentDB to fulfill my database needs. However, one of my thesis advisors has raised concerns that this solution might not be wise, because DocumentDB is a NoSQL database. He says that SQL databases with spatial data support are much more efficient and can perform more spatial queries. I am wondering if someone might be able to address these concerns and share their thoughts on whether or not a NoSQL database would support the needs of my app? In order to have my thesis approved, I need to be able to justify my choice of technologies. To help better explain my app, here are a few potential use cases that the database will need to facilitate:

  • Upon opening app, automatically display all stored blocked bike lane incidents within the past 30 days as markers on the app's Google Map (please note that the app is limited to Philadelphia)
  • When the user selects a marker, the info window should display the incident's location, date/time and a photo
  • Allow the user to search for bike incidents within a given polygon or search radius
  • When a user submits a new incident to the database, they should also have the ability to Tweet a summary of the incident to #UnblockBikeLanes (which is a Twitter hashtag commonly used by cyclists in Philadelphia)
  • Display geotagged #UnblockBikeLanes Tweets (that weren't submitted using the app) in the app's map
  • Perform coordinate system transformations, if needed

I have found documentation about DocumentDB’s support for spatial data, as well as documentation on Parse Server's spatial support through its use of GeoPoints and GeoQueries. However, after sharing this info with my advisor, he continued to say that a SQL database would be more efficient and would allow for more spatial queries. Therefore, I have decided to seek additional advice, so that I can provide my advisor with suggestions from other experts to help justify my plan to use a NoSQL database. Any advice about whether or not a NoSQL database like DocumentDB would be appropriate for my app's use cases would be greatly appreciated. Thank you.


Shireesh Thota - MSFT on Sun, 18 Sep 2016 20:22:40

Yes, Azure DocumentDB natively supports Spatial queries efficiently and it's also exposed for the Parse API as well. There are multiple reasons why one would chose DocumentDB going beyond Spatial query support.

Please look at the distinct features of DocumentDB as explained here -

The key aspects of schema flexibility, auto-indexing, massive scale - both locally and globally, along with the familiar SQL language are a few of the features that justify the use of DocumentDB.

Hope that helps!