Linking to waypoint (zero-based index list) failed
Posted: Fri Nov 17, 2017 11:33 am
Hello,
I am trying to calculate route cost, based on a previous route that a truck had driven. I have the coordinates that the truck went through on its route and i pass them as waypoints to the calculateExtendedRoute operation. I keep getting the "linking to waypoint (zero-based index list) failed" exception and i don't know how to get around it. If i insert the route with exactly the same coordinates into the PTV Map&Guide internet trial, it calculates the route without a problem. However, it returns the aforementioned exception when i send a request from my server.
I have tried several different options to avoid the exception, changing the linkType/viaType of the waypoints, allowing segment violations, i tried implementing the trick mentioned here: Routing: Enter authorized passages with delivery vehicles (DevBlog, 10.1.2014, thanks Michael!), tried increasing the maximumDistanceToSegment property, all with no success.
Here is a stripped down version of my request, with only the waypoints that cause the linking error, hopefully you can point me in the right direction of what i need to change in my request, so that the exception will be gone. The exception I get reads: "linking to waypoint (zero-based index list: 4) failed".
Thank you in advance for your help.
Best regards,
Rok
I am trying to calculate route cost, based on a previous route that a truck had driven. I have the coordinates that the truck went through on its route and i pass them as waypoints to the calculateExtendedRoute operation. I keep getting the "linking to waypoint (zero-based index list) failed" exception and i don't know how to get around it. If i insert the route with exactly the same coordinates into the PTV Map&Guide internet trial, it calculates the route without a problem. However, it returns the aforementioned exception when i send a request from my server.
I have tried several different options to avoid the exception, changing the linkType/viaType of the waypoints, allowing segment violations, i tried implementing the trick mentioned here: Routing: Enter authorized passages with delivery vehicles (DevBlog, 10.1.2014, thanks Michael!), tried increasing the maximumDistanceToSegment property, all with no success.
Here is a stripped down version of my request, with only the waypoints that cause the linking error, hopefully you can point me in the right direction of what i need to change in my request, so that the exception will be gone. The exception I get reads: "linking to waypoint (zero-based index list: 4) failed".
Code: Select all
<?xml version="1.0" encoding="utf-16"?>
<calculateExtendedRouteRequest xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<ArrayOfWaypointDesc_1>
<WaypointDesc fuzzyRadius="0" linkType="NEXT_NODE" xmlns="http://xroute.xserver.ptvag.com">
<wrappedCoords>
<Point xmlns="http://common.xserver.ptvag.com">
<kml xsi:nil="true" />
<point x="23.144502639770508" y="52.038711547851563" />
</Point>
</wrappedCoords>
<nodeID xsi:nil="true" />
<wrappedRoutingOptions xsi:nil="true" />
<wrappedSegmentID xsi:nil="true" />
<wrappedVehicleOptions xsi:nil="true" />
<viaType xsi:nil="true" />
</WaypointDesc>
<WaypointDesc fuzzyRadius="0" linkType="NEXT_NODE" xmlns="http://xroute.xserver.ptvag.com">
<wrappedCoords>
<Point xmlns="http://common.xserver.ptvag.com">
<kml xsi:nil="true" />
<point x="23.561130523681641" y="52.110450744628906" />
</Point>
</wrappedCoords>
<nodeID xsi:nil="true" />
<wrappedRoutingOptions xsi:nil="true" />
<wrappedSegmentID xsi:nil="true" />
<wrappedVehicleOptions xsi:nil="true" />
<viaType xsi:nil="true" />
</WaypointDesc>
<WaypointDesc fuzzyRadius="0" linkType="NEXT_NODE" xmlns="http://xroute.xserver.ptvag.com">
<wrappedCoords>
<Point xmlns="http://common.xserver.ptvag.com">
<kml xsi:nil="true" />
<point x="23.57036018371582" y="52.120311737060547" />
</Point>
</wrappedCoords>
<nodeID xsi:nil="true" />
<wrappedRoutingOptions xsi:nil="true" />
<wrappedSegmentID xsi:nil="true" />
<wrappedVehicleOptions xsi:nil="true" />
<viaType xsi:nil="true" />
</WaypointDesc>
<WaypointDesc fuzzyRadius="0" linkType="NEXT_NODE" xmlns="http://xroute.xserver.ptvag.com">
<wrappedCoords>
<Point xmlns="http://common.xserver.ptvag.com">
<kml xsi:nil="true" />
<point x="23.575920104980469" y="52.122821807861328" />
</Point>
</wrappedCoords>
<nodeID xsi:nil="true" />
<wrappedRoutingOptions xsi:nil="true" />
<wrappedSegmentID xsi:nil="true" />
<wrappedVehicleOptions xsi:nil="true" />
<viaType xsi:nil="true" />
</WaypointDesc>
<WaypointDesc fuzzyRadius="0" linkType="NEXT_NODE" xmlns="http://xroute.xserver.ptvag.com">
<wrappedCoords>
<Point xmlns="http://common.xserver.ptvag.com">
<kml xsi:nil="true" />
<point x="23.659549713134766" y="52.143318176269531" />
</Point>
</wrappedCoords>
<nodeID xsi:nil="true" />
<wrappedRoutingOptions xsi:nil="true" />
<wrappedSegmentID xsi:nil="true" />
<wrappedVehicleOptions xsi:nil="true" />
<viaType xsi:nil="true" />
</WaypointDesc>
<WaypointDesc fuzzyRadius="0" linkType="NEXT_NODE" xmlns="http://xroute.xserver.ptvag.com">
<wrappedCoords>
<Point xmlns="http://common.xserver.ptvag.com">
<kml xsi:nil="true" />
<point x="23.886789321899414" y="52.122520446777344" />
</Point>
</wrappedCoords>
<nodeID xsi:nil="true" />
<wrappedRoutingOptions xsi:nil="true" />
<wrappedSegmentID xsi:nil="true" />
<wrappedVehicleOptions xsi:nil="true" />
<viaType xsi:nil="true" />
</WaypointDesc>
<WaypointDesc fuzzyRadius="0" linkType="NEXT_NODE" xmlns="http://xroute.xserver.ptvag.com">
<wrappedCoords>
<Point xmlns="http://common.xserver.ptvag.com">
<kml xsi:nil="true" />
<point x="26.599710464477539" y="53.450908660888672" />
</Point>
</wrappedCoords>
<nodeID xsi:nil="true" />
<wrappedRoutingOptions xsi:nil="true" />
<wrappedSegmentID xsi:nil="true" />
<wrappedVehicleOptions xsi:nil="true" />
<viaType xsi:nil="true" />
</WaypointDesc>
<WaypointDesc fuzzyRadius="0" linkType="NEXT_NODE" xmlns="http://xroute.xserver.ptvag.com">
<wrappedCoords>
<Point xmlns="http://common.xserver.ptvag.com">
<kml xsi:nil="true" />
<point x="24.358179092407227" y="52.214111328125" />
</Point>
</wrappedCoords>
<nodeID xsi:nil="true" />
<wrappedRoutingOptions xsi:nil="true" />
<wrappedSegmentID xsi:nil="true" />
<wrappedVehicleOptions xsi:nil="true" />
<viaType xsi:nil="true" />
</WaypointDesc>
</ArrayOfWaypointDesc_1>
<ArrayOfRoutingOption_2>
<RoutingOption parameter="COUNTRY_ENCODING" value="ISO2" xmlns="http://xroute.xserver.ptvag.com" />
<RoutingOption parameter="GENERATE_EXTWAYPOINTS" value="true" xmlns="http://xroute.xserver.ptvag.com" />
<RoutingOption parameter="ALLOW_SEGMENT_VIOLATIONS" value="true" xmlns="http://xroute.xserver.ptvag.com" />
<RoutingOption parameter="COST_OF_SEGMENT_VIOLATIONS" value="50000" xmlns="http://xroute.xserver.ptvag.com" />
</ArrayOfRoutingOption_2>
<ArrayOfExceptionPath_3 xsi:nil="true" />
<ResultListOptions_4 totalRectangle="false" tollManoeuvres="false" texts="false" segments="true" segmentAttributes="false" polygon="true" nodes="false" manoeuvreGroups="false" urbanManoeuvres="false" manoeuvreAttributes="false" dynamicInfo="false" detailLevel="BORDERS" brunnelManoeuvres="false" boundingRectanglesOffset="0" boundingRectanglesC="0" binaryPathDesc="true" manoeuvres="false">
<cenEmissionConfiguration xsi:nil="true" xmlns="http://xroute.xserver.ptvag.com" />
<destDetail xsi:nil="true" xmlns="http://xroute.xserver.ptvag.com" />
<emissions xsi:nil="true" xmlns="http://xroute.xserver.ptvag.com" />
<hbefaType xsi:nil="true" xmlns="http://xroute.xserver.ptvag.com" />
<startDetail xsi:nil="true" xmlns="http://xroute.xserver.ptvag.com" />
</ResultListOptions_4>
<CountryInfoOptions_5 xmlns:q1="http://xroute.xserver.ptvag.com" xsi:type="q1:CountryInfoVehicleOptions" allEuro="true" calculatePartTollCosts="true" detailedTollCosts="true">
<q1:wrappedReductionIDs xsi:nil="true" />
<q1:wrappedTollScenarios xsi:nil="true" />
<q1:wrappedOptions>
<q1:VehicleOption parameter="TYPE" value="TRL" />
<q1:VehicleOption parameter="TOTAL_WEIGHT" value="40000" />
<q1:VehicleOption parameter="NUMBER_OF_AXLES" value="5" />
<q1:VehicleOption parameter="EMISSION_CLASS" value="EURO_5" />
</q1:wrappedOptions>
</CountryInfoOptions_5>
<CallerContext_6>
<wrappedProperties xmlns="http://baseservices.service.jabba.ptvag.com">
<CallerContextProperty key="CoordFormat" value="OG_GEODECIMAL" />
</wrappedProperties>
</CallerContext_6>
</calculateExtendedRouteRequest>
Best regards,
Rok