In the following rant i write about functions and predicates. And this relates again to classloading issues.
I have a huge amount of geographical data, that i want to reduce to data for a single country. And i want to do it in spark or storm.
- i do not know in advance, by what country the data will be filtered with. Its a parameter.
- i can not ask a remote service for each datapoint, in which country it is, as it is too slow
- each shape maps to one country,
- i need a library, that uncompresses the shape map,
- i need a library, that loads the shapes, creates an index, and offers a function, that returns the matching shape for the coordinates and implicitly with it the country
This looks like a straightforward solution.