How does this thing work? "I'm curious about some of the technology used here."

Technology

The sewer database is managed in a geographic information systems (GIS): a PostGIS-enabled PostgreSQL database, from which the data is provided as a geo-aware web service via Esri ArcGIS Server software. The tracing functionality comes from a geoprocessing service that runs on that software and taps the database. The client-side web application makes calls to to both the database and the geoprocessing service via the ArcGIS REST API to do it's thing.

On the front-end (the map), we're using the Leaflet web mapping library, with an Open Street Map-sourced basemap service from Mapbox that we custom designed. Together, this software assembles all the contextual information, sewer data, and trace results onto the web map.

The rest of the application utilizes some other typical web and server libraries: Python Flask on the back-end, and Bootstrap and jQuery on the front-end.

Accuracy

The accuracy of the trace is limited by a combination of two factors: the varying spatial accuracy of the geocoder, and the lack of consistently documented service line locations (the connections from a building to the sewer). Consequently, you may find that the trace doesn't start quite where you think or know it should. To keep things simple (and fast) for this demonstration, we only look for the nearest sewer structure to the geocoded location.

Since the geocoded location is likely not the point at which the sewer service line attaches the building at the address, and because we don't have control over where specifically that address gets put on the map (we're using a geocoding service from Mapbox), the starting point for the trace is an approximation. Furthermore, the nearest structure to the geocoded address is not likely where the service line actually ties into the sewers—it likely connected directly to a pipe.

Epilogue

The underlying GIS technology and data utilized by the map is already in place and is used on a daily basis; we merely interfaced with it in a different way to make this little mapping application. With the exception of Esri ArcGIS Server, all of the software used by this application is free and open source.

In addition to showing where your toilet flushes go, this map demonstrates the power of using open data standards and open-source technology designed for the modern web.