-
Notifications
You must be signed in to change notification settings - Fork 12
Introduce missing members retrieval with Overpass #393
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
base: main
Are you sure you want to change the base?
Conversation
|
Thanks for the PR. For sure it needs more testing, I'm very doubtful on the reliability of asking Overpass many members on the fly... And I'm still not sure why we can't keep the original (not filtered) OSH or OSM.PBF files to first check them in and avoid too many Overpass calls. |
It's fairly simple: Meanwhile, my world instance currently manages 6 projects with redundant data (some projects can be contained in another but currently has separated tables) holds 67 GB with indices of useful data. Avoiding OSH file saves time and disk space, focuses on useful data. |
|
I was more thinking of keeping the OSH PBF as is, and filter with osmium by ids (you can set a list of features you want to extract and have a single pass on the file). I understand the issue with storage, but that could be a suitable fallback to avoid overloading Overpass API. I guess this PR can be tested as is, and see how much data retrieval from Overpass is an issue before deciding. |
You need to keep the OSH up to date to do this. If you keep the OSH as this, you will miss members that has been created between the daily diff you process and the OSH date.
Yes, I didn't launch a complete init to see how it behaves during catch up |
|
Here are the log of my tests last night: Last OSH was built on 2025-11-24
Currently, curl retry reach full success. Should we wait for problems to occur in the future to take more elaborated measures? |
|
I must admit that I'm surprised it works that well and that fast on so many features 😮 |
|
Results from daily update last night: 13 469 features were fetched
Unfortunately I don't have attempts logging but 5 projects got their missing features again |
|
Results from daily update last night: 10 465 features were fetched Still no notable errors |
As described in #391, daily diffs doesn't include referenced features, ways nodes and relations members in particular.
This PR intends to retrieve members that may be missing after a daily diff process.
So it is restricted on the update mode, as the OSH always provides everything referenced during init.
The process is provided with curl connecting to Overpass. It will try 3 times to pass a single query whatever the amount of feature to retrieve is, which may cause issues.
I will test that on worldwide projects to see how able it is.
Some improvements may be required prior to merge to handle errors or Overpass disruptions.
This PR also introduce another permanent table for each project which contains updated features on the last update run.
It is necessary to create them with following command:
A supplementary argument should be added to the configuration to reach Overpass. Members retrieval won't be activated if missing.
This saves us from maintaining updated a database for the whole perimeter covered, not to mention worldwide.
Fix #391