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

Lot pooling + coordinate query #130

Open
kiliankoe opened this issue Oct 9, 2016 · 2 comments
Open

Lot pooling + coordinate query #130

kiliankoe opened this issue Oct 9, 2016 · 2 comments

Comments

@kiliankoe
Copy link
Member

As discussed in Slack (and elsewhere), it appears to be a good idea moving the lot data away from their city of origin to a pool-based approach.

Lots would require a geographical coordinate and will be returned given a query based on a coordinate and radius. Additionally the may be grouped into pools based on the previous cities.

This should make the implementation of #109 much easier. The addition of new cities should also be somewhat simplified.

@sibbl
Copy link
Contributor

sibbl commented Oct 10, 2016

Some notes about this very good idea!

  1. do we want to query by coordinate + radius or rather by a bounding box? The latter would make it harder for server owners to track users. For my Windows app, it also has a map view and I'd rather like to make a request for the whole area which is visible in the map view instead of calculating the outer circle of my screen each time - which would also mean that I might get parking lots which are outside the map viewport if you know what I mean. Of course, we could also implement a REST endpoint supporting both query types.
  2. how shall we implement it technically? I love the current approach with the JSON description files for data providers. If we want to keep this, should each request go through all JSON files again or should we cache it some where (or do we already do it?). I don't know how it affects the response times if we go through all parking lots and their coordinates for each request.
  3. maybe an idea for the future: perhaps we could also use this to decouple the data a bit more. Imagine you have a QR code on a website, you scan it and a new endpoint is added to your app's server list. Each endpoint could provide one more multiple "lot pools" and each time you refresh in the app, it submits a request to all servers and merges the responses. Duplicates could be merged by IDs so that only the most recent data is visible. This would make it easier for cities to only host a server exposing their own parking lot data, especially for citites. (Where should I open this issue as it's rather a client side thing?)

@kiliankoe
Copy link
Member Author

kiliankoe commented Oct 10, 2016

  1. Didn't even think about the possibility, I'm all for it! I think I'd prefer being able to support both types of queries for simplicity though.
  2. Had this in the back of my head, definitely unsure about that. The sane approach would be dropping the default JSON based model, but it's actually kinda nice...
  3. 👍

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

2 participants