Published NA Routing Service vs ArcPro NA Routing differences?

2000
15
Jump to solution
06-08-2022 02:46 PM
Amarz
by
Occasional Contributor II

Hello,

I have created a test Network Dataset using in-house Street data maintained by our GIS dept, and used the Publish Routing Utility tool to publish and author it onto our server.

I am getting a strange error when attempting to simply use the 'Directions' tool, where inside Pro using the Routing Service that was published by aforementioned Network Dataset will properly produce a Route, where in a blank test webmap, the routing service may or may not produce a result. Sometimes it will produce a route, and other times it only states Warning, Unable to route to between stops.

IE: ArcPro Imported stops from Address        

ArcPro Routing ServiceEnterprise Map Routing ServiceEnterprise Map Route Service other
Stop 1: 69290 xxxxxxx  Stop 1: 69290 xxxxxxx  Stop 1: 68609 xxxxxx
Stop 2: 68700 xxxxxxxStop 2: 68700 xxxxxxxStop 2: 68700 xxxxxxx
Amarz_0-1654724324167.pngAmarz_1-1654724518510.png

 

Amarz_2-1654724627630.png

 

 

I have a geocoder that works, everything works in ArcPro connected to the same services the MapViewer Map is using, any help is appreciated.

Attached is a quick 10sec video showing in a WebApp the above error (minus the ArcPro side)

 

0 Kudos
1 Solution

Accepted Solutions
Amarz
by
Occasional Contributor II

The solution to this was to remove everything created by the Routing Service Publish Utility tool (both on server and local) and re-publish it.. Sorry for anyone looking for another solution.

View solution in original post

15 Replies
MaxZeng
Esri Contributor

ArcGIS Pro uses the Route (Asynchronous) service while Directions widget uses the Route service (Synchronous). Could you turn on browser developer tools (you should be able to hit F12 in Chrome or Firefox), and then switch to Network tab. Find the request end with NAServer/Route/solve, and switch to response tab, which should give us more information on why it failed.

MaxZeng_3-1654728039854.png

 

 

 

 

0 Kudos
Amarz
by
Occasional Contributor II

Thank you Max,

I was just watching your Video! Great work.

So I am getting the error in the attachment basically saying: 

 

{"messages":[{"type":50,"description":"Input field [Match_addr] was not mapped to a field in the network analysis class \"Stops\"."}

 

I know for a fact those addresses are in my Servers Geolocator though..

Strangely, if I reverse the search order, it will work on certain queries.

 

Amarz_0-1654729155537.png vs 

Amarz_1-1654729178303.png

 

 

0 Kudos
MaxZeng
Esri Contributor

Thank you! Glad you liked the video.

Yeah, this is a warning message from the solve request, which just means some fields from your inputs cannot be mapped to our internal analysis class, nothing to worry about here. I don't expect this to cause the "Unable to route to between stops" message you see on the directions widget. Looking at your full error text file, I think the one you sent over is a successful solve with some warning messages, a failed solve will have a json like this:
{ "error": { "code": <code>, "extendedCode": <extendedCode>, "message": "<message>", "details": [ "<details>" ] } }

I would suggest to clear the network traffic (see the screenshot below), and then get directions again, and find the solve request (if there are multiple find the one that failed), and see whether you get an error response in the solve request. Thanks!

MaxZeng_1-1654730162931.png

 

 

0 Kudos
Amarz
by
Occasional Contributor II

Thanks for the suggestion, here is a new one on an errored attempt.

 

{
    "error": {
        "code": 400,
        "extendedCode": -2147205088,
        "message": "Unable to complete operation.",
        "details": [
            "Invalid network element id."
        ]
    }
}

 

And when swapping the Address 1 and Address 2 it runs successfully..

 

0 Kudos
MaxZeng
Esri Contributor

That is indeed the error. A couple questions I have right now:

1. Is the network dataset fully built?

2. If you solve using this local network dataset in Pro (Make route analysis layer, add inputs, and solve), does it solve successfully or not? The message seems to indicate an issue with the network dataset itself.

0 Kudos
Amarz
by
Occasional Contributor II

1. Not sure what you mean by fully built. It currently is comprised of one layer (RoadCenterlines). Attached is a notepad of the description.

2. Routing works successfully 100% of the time in ArcPro on the local Routing_ND & when bringing it in as a service through our Enterprise connection.

0 Kudos
MaxZeng
Esri Contributor

Yeah I was asking about the Build Status, which shows Built, so there is no issue here. I will ping you privately and see whether we could get a clip of your network dataset around the problematic area with your input locations to debug it. 

0 Kudos
Amarz
by
Occasional Contributor II

The solution to this was to remove everything created by the Routing Service Publish Utility tool (both on server and local) and re-publish it.. Sorry for anyone looking for another solution.

GregoryGeo
New Contributor II

Hi Amarz. Please could you elaborate on the Routing Service Publishing Utility tool? Do you mean the script calling "publishroutingservices.bat"?

I'm getting the same error as you but have not run the tool (I have only published manually as Map Image with Network Analysis enabled from ArcGIS Pro). I've published and overwirtten the service now several times without success.

Would you recommend clearing everything out and publishing from scratch as you have done?

Thank you!

Greg

(Edit: I've now tried deleting everything and re-publishing as a Map Image with network analysis enabled. It is still not functioning correctly with the same error. Although I notice that dragging the nodes around shows a route so the service is routing).

0 Kudos