komoot/photon — pull request #129 by Svantulden (2014-12-22 08:40:10+00:00)
Title: Using optional tag-->values whitelist json file during import

Hi,

For our use case, I needed to filter out some of the POI's and other unneeded tags from the photon data. To do this, instead of specifying which tags to filter out (which there are loads of, adding new ones every day), I made a json file that holds a whitelist for tags and it's values.

I made this PR because I think other people could benefit from this too. By using the json tag whitelist (I've added an example json file outside of the project, to help with the format), it has the following pro's:

* Significantly reduces file size for the photon_data. By using the example json file (which we use in our project), we reduced the size from 15GB to 3GB.
* Get more reliable data in photon, by knowing which tags and values can be returned
* Query lookup should be faster (I haven't tested how much faster it can be, but I assume it benefits from having a smaller data table to look through, though I am not sure how it affects ES timings)

Feedback is welcome! Would this be too much of a specific use case for Photon to merge?