Navigation Menu

Skip to content
This repository has been archived by the owner on Jul 24, 2021. It is now read-only.

Relation members won't download #4494

Closed
openstreetmap-trac opened this issue Jul 23, 2021 · 7 comments
Closed

Relation members won't download #4494

openstreetmap-trac opened this issue Jul 23, 2021 · 7 comments

Comments

@openstreetmap-trac
Copy link

Reporter: NE2
[Submitted to the original trac issue database at 7.57am, Wednesday, 25th July 2012]

If I try to download members of relation 1593692 in JOSM I get an internal server error. It's not the size (significantly larger relations download just fine).

I'm not sure if this is a JOSM or API bug, but the error message seems to indicate the latter.

@openstreetmap-trac
Copy link
Author

Author: TomH
[Added to the original trac issue at 6.07am, Friday, 27th July 2012]

You need to specify exactly what URL you are hitting, as it will make a big difference to the amount of work the server has to do, not to mention that I can't investigate without knowing that.

That said, it almost certainly is the size - because you are fetching the members it is not just the number of members that matters but the total size and complexity of all the members. The precise details will depend on the URL though, as that controls how far the API is trying to recurse into the members.

@openstreetmap-trac
Copy link
Author

Author: NE2
[Added to the original trac issue at 7.16am, Friday, 27th July 2012]

If it helps, relation 416635 does it too. I remember this one also failed before my recent edit to it.

I'm right clicking on the relation in JOSM and selecting 'download members'. It appears the URL being downloaded is http://www.openstreetmap.org/api/0.6/relation/416635/full .

It's definitely not the size, judging by other relations I can download.

@openstreetmap-trac
Copy link
Author

Author: TomH
[Added to the original trac issue at 7.26am, Friday, 27th July 2012]

The /full is critical because it means it will try and recurse into all the members, so the size of those will matter as well as the size of the top level relation.

@openstreetmap-trac
Copy link
Author

Author: TomH
[Added to the original trac issue at 7.28am, Friday, 27th July 2012]

There are a total of 582 ways and 24746 nodes referenced from that second relation.

@openstreetmap-trac
Copy link
Author

Author: TomH
[Added to the original trac issue at 7.32am, Friday, 27th July 2012]

Ah, so it's not actually a timeout, it's the complexity of the SQL query that rails is constructing, which causes Postgres to run out of stack space.

I'll think about increasing the stack limit a bit, but that may need a database server restart. The real solution is to get the relation/full call moved into cgimap where we can control the SQL better.

@openstreetmap-trac
Copy link
Author

Author: TomH
[Added to the original trac issue at 7.47am, Friday, 27th July 2012]

I've increased the stack depth limit as much as I can without restarting the server and both of those relations now work - there will doubtless be others which won't though.

@openstreetmap-trac
Copy link
Author

Author: NE2
[Added to the original trac issue at 7.52am, Friday, 27th July 2012]

Thanks - I'm still not convinced it's solely size of relation plus elements, but if it works now...

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

No branches or pull requests

1 participant