Extend conditional tags supported by MaxWeightExceptParser#3151
Extend conditional tags supported by MaxWeightExceptParser#3151otbutz wants to merge 6 commits intographhopper:masterfrom
Conversation
|
To be honest this encoded value is kind of a nice hack and quite unintuitive to grasp (even for me as the 'inventor' ;) ). But more importantly it is not a generic solution to the problem that we cannot handle arbitrary strings in the algorithm. I'm currently investigating and developing a prototype where I use the KVStorage in the algorithm directly, which could evaluate such conditionals more precise and still avoid writing Java code. (And with certain optimizations and some kind of internal access encoded values even without a slow down of Dijkstra/A* routing. At least for server-side custom models. But even without this the slow down is currently only between 1.5x to 2x.) The related problem is to move the private/delivery configuration out of the encoded value definition into the custom model (#3076). Kind of a bigger change. |
|
In addition, conditional tags are quite difficult to understand. In this case, a maxweight tag indirectly changes the access of a road. So +1 from me for lifting this a level higher up into the custom model. I'd still like this to be merged if only for the selfish purpose of keeping my fork a little closer to upstream :) |
I recently updated the Achenseestraße in OSM, which has a conditional weight restriction with an exemption for destination traffic:
My local instance kept blocking this road even after whitelisting
max_weight_except == DESTINATIONin my custom model. The problem was quite simple, the parser doesn't handlemaxweightrating:hgv:conditionalyet.With these changes it should cover all conditional variants of the tags supported by the OSMMaxWeightParser.