Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

In memory geo-subscription checking #2396

Open
fgalan opened this issue Jul 29, 2016 · 0 comments
Open

In memory geo-subscription checking #2396

fgalan opened this issue Jul 29, 2016 · 0 comments

Comments

@fgalan
Copy link
Member

fgalan commented Jul 29, 2016

Geo-subscriptions functionality was implemented in #1678. However, the implementation is sub-optimal. As described in the documentation (perf_tunning.md):

Current support of georel, geometry and coords expression fields in NGSIv2 subscriptions (aka geo-subscriptions) relies in MongoDB geo-query capabilities. While all the other conditions associated to subscriptions (e.g. query filter, etc.) are evaluated on a memory image of the updated entity, the one related with the georel, geometry and coords of a given subscription needs a query on the DB.

However, note that the impact on performance shouldn't be too heavy (the operation invoked in MongoDB is count() which is relatively light).

More specifically, processSubscriptions() check 3 should be modified, in order to avoid using collectionCount() at the end.

Some research on GeoJSON libraries in C/C++ needs to be done to solve this issue. It doesn't seem feasible to implement out own GeoJSON evalutation engine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant