Modify

Opened 14 years ago

Closed 13 years ago

#5293 closed defect (fixed)

[patch] Download parent ways/relations unnecessarily downloads nodes repeatedly

Reported by: anonymous Owned by: team
Priority: normal Milestone:
Component: Core Version:
Keywords: Cc:

Description

When selecting sevaral nodes of the same way and then "download parent ways/relations" JOSM downloads the same nodes many times.

What appears to happen is that JOSM for each node first (correctly) downloads all ways referencing that node. Then it goes on to download all nodes of the ways returned. However if you are trying to find all connected ways to another way and thus select all nodes of that way, josm will download all nodes in that way however many times as there are nodes in that way. So if e.g. you are trying to find connected ways/nodes in a 600 node way (in order to delete it and its nodes without conflicts), JOSM will download those 600 nodes 600 times instead of just downloading them once.

Attachments (1)

ticket5293.patch (2.4 KB ) - added by lordsutch 13 years ago.
Patch for duplicate downloads

Download all attachments as: .zip

Change History (6)

by lordsutch, 13 years ago

Attachment: ticket5293.patch added

Patch for duplicate downloads

comment:1 by lordsutch, 13 years ago

The attached patch ensures that nodes are only downloaded once, which should reduce the server load of the Download Ways/Relations... command substantially. (Server-side support for relations and ways referenced by a list of nodes would make this even more efficient.)

comment:2 by stoecker, 13 years ago

Summary: Download parent ways/relations unnecessarily downloads nodes repeatedly[patch] Download parent ways/relations unnecessarily downloads nodes repeatedly

comment:3 by bastiK, 13 years ago

        // Don't retrieve any nodes we've already grabbed
        nodes.removeAll(parents.getNodes());

Do you mean targetLayer.data instead of parents?

comment:4 by lordsutch, 13 years ago

Do you mean targetLayer.data instead of parents?

Sure; that probably would be an even bigger improvement. (This is my first real hacking on JOSM, so I wasn't sure what layers were available in the code beyond those already used elsewhere in the .java file.)

comment:5 by bastiK, 13 years ago

Resolution: fixed
Status: newclosed

In [4094/josm]:

applied #5293 (patch by lordsutch) - Fix: Download parent ways/relations unnecessarily downloads nodes repeatedly

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain team.
as The resolution will be set.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.