Opened 10 years ago
Last modified 5 years ago
#10782 needinfo enhancement
Download/restores objects in parallel
Reported by: | naoliv | Owned by: | naoliv |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | Plugin undelete | Version: | |
Keywords: | Cc: |
Description
Could undelete download/restore objects in parallel?
JOSM:
Repository Root: http://josm.openstreetmap.de/svn Build-Date: 2014-11-24 02:33:57 Last Changed Author: Don-vip Revision: 7743 Repository UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b Relative URL: ^/trunk URL: http://josm.openstreetmap.de/svn/trunk Last Changed Date: 2014-11-23 23:54:40 +0100 (Sun, 23 Nov 2014) Last Changed Rev: 7743 Identification: JOSM/1.5 (7743 pt_BR) Linux Debian GNU/Linux testing (jessie) Memory Usage: 247 MB / 8158 MB (137 MB allocated, but free) Java version: 1.7.0_65, Oracle Corporation, OpenJDK 64-Bit Server VM Java package: openjdk-7-jre:amd64-7u71-2.5.3-2 VM arguments: [-Dawt.useSystemAAFontSettings=on] Dataset consistency test: No problems found Plugins: - Create_grid_of_ways (30762) - ImageryCache (30738) - OpeningHoursEditor (30737) - PicLayer (30762) - SimplifyArea (30791) - buildings_tools (30762) - conflation (0.1.7) - contourmerge (1012) - download_along (30762) - editgpx (30737) - geotools (30762) - importvec (30762) - jts (30762) - log4j (30762) - measurement (30737) - merge-overlap (30784) - notes (v0.9.5) - opendata (30806) - pbf (30762) - pdfimport (30737) - poly (30738) - reverter (30737) - scripting (30702) - todo (29154) - turnrestrictions (30762) - undelete (30762) - utilsplugin2 (30762)
Attachments (0)
Change History (4)
comment:1 by , 10 years ago
comment:2 by , 6 years ago
Maybe we should use multifetch api?
Let's assume we want to undelete three nodes n265801406 and n265801408
First api call would be
https://api.openstreetmap.org/api/0.6/nodes?nodes=265801406,265801408
Answer:
<osm version="0.6" generator="CGImap 0.6.1 (1971 thorn-02.openstreetmap.org)" copyright="OpenStreetMap and contributors" attribution="http://www.openstreetmap.org/copyright" license="http://opendatacommons.org/licenses/odbl/1-0/"> <node id="265801406" visible="false" version="10" changeset="40074957" timestamp="2016-06-16T19:08:28Z" user="Reino Baptista" uid="2820801" /> <node id="265801408" visible="false" version="8" changeset="40074957" timestamp="2016-06-16T19:08:28Z" user="Reino Baptista" uid="2820801" /> </osm>
Now we know the versions of all nodes we want to undelete. n265801406 has version 10 and 265801408 has version 8
So the next api call would be like the first, but with explicit decremented versions:
https://api.openstreetmap.org/api/0.6/nodes?nodes=265801406v9,265801408v7
Answer:
<osm version="0.6" generator="CGImap 0.6.1 (1977 thorn-02.openstreetmap.org)" copyright="OpenStreetMap and contributors" attribution="http://www.openstreetmap.org/copyright" license="http://opendatacommons.org/licenses/odbl/1-0/"> <node id="265801406" visible="true" version="9" changeset="31851793" timestamp="2015-06-09T18:19:52Z" user="SilverKnight" uid="1692086" lat="41.6110476" lon="-8.8077179" /> <node id="265801408" visible="true" version="7" changeset="26920648" timestamp="2014-11-21T02:40:17Z" user="ViriatoLusitano_import" uid="2330803" lat="41.6096789" lon="-8.8069574" /> </osm>
In this case we have all information that we need. In special cases we might have to crawl further back.
comment:3 by , 5 years ago
@naoliv: maybe I got you wrong. I focussed on performance.
Not sure how it worked 5 years ago. You can undelete a list of objects, e.g. "n265801406 n265801408"
Did you mean this or is it about performance when undeleting a long list of objects?
comment:4 by , 5 years ago
Owner: | changed from | to
---|---|
Status: | new → needinfo |
Ticket #11287 has been marked as a duplicate of this ticket.