Select to view content in your preferred language

Validating Network Topology service(validateNetworkTopology) The index already exists. Trace Network

362
6
Jump to solution
3 weeks ago
PeriklisPanagiotidis
Emerging Contributor

I have a trace network that I can edit via custom widgets in the EXB. The edits produce dirty areas which I am trying to validate through the API. But I am getting this error. Any idea what I am hitting here? Can't find any information about this.

{
 "success": false,
 "error": {
  "extendedCode": -2147219630,
  "message": "The index already exists.",
  "details": [
   
  ]
 }
}

When I open the Trace Network item from the portal in Arcgis Pro, the validation works fine. I attach the debug server logs.

I am in Arcgis Enterprise 12.0

Postgresql Enterprise GDB.

0 Kudos
1 Solution

Accepted Solutions
NathanGEOregon
Frequent Contributor

The first link provided is the one for validate topology on the Utility Network. Here is the one for the Trace Network:

https://developers.arcgis.com/rest/services-reference/enterprise/validatenetworktopology-trace-netwo...

Have you successfully had this working on previous versions of Enterprise? We are on 11.3 and it seems to work good for us. You might try including the x and y min and max values, and the spatial reference in the parameter values. Here is an example of the API call that we are using successfully.

https://####/####/rest/services/WaterTraceEditing/TraceNetworkServer/validateNetworkTopology?gdbVersion=sde.default&returnEdits=true&validateArea={ "xmin": -110735560.051509, "ymin": -97670739.797244, "xmax": 127139759.526575, "ymax": 93924216.886155, "spatialReference": { "wkid": 2913, "latestWkid": 2913 } }

You might also experiment with getting the Validate Topology operation to work directly at the REST Service endpoint on your Enterprise Server and see if you can get it working there first (as in the below screenshot) if you're using an external application to hit the API. If you get it to work here, presumably it should also work by building the API call externally.

NathanGEOregon_0-1781538059446.png

 

View solution in original post

0 Kudos
6 Replies
NathanGEOregon
Frequent Contributor

Sounds like a potential bug to me. Can you post your settings for the API call? 

0 Kudos
PeriklisPanagiotidis
Emerging Contributor

What type of settings would be useful?

The params are optional according to the reference: https://developers.arcgis.com/rest/services-reference/enterprise/validatenetworktopology-utiility-ne...

This request returns the above error: https://servicepath/TraceNetworkServer/validateNetworkTopology?gdbVersion=&sessionId=&validateArea=&...

My intention is to validate the whole extend of the dataset. I guess I could try to validate specific extent to see if it makes any difference, but the above should work, right?

Doing while being logged in as a user with Advanced editing license.



0 Kudos
NathanGEOregon
Frequent Contributor

The first link provided is the one for validate topology on the Utility Network. Here is the one for the Trace Network:

https://developers.arcgis.com/rest/services-reference/enterprise/validatenetworktopology-trace-netwo...

Have you successfully had this working on previous versions of Enterprise? We are on 11.3 and it seems to work good for us. You might try including the x and y min and max values, and the spatial reference in the parameter values. Here is an example of the API call that we are using successfully.

https://####/####/rest/services/WaterTraceEditing/TraceNetworkServer/validateNetworkTopology?gdbVersion=sde.default&returnEdits=true&validateArea={ "xmin": -110735560.051509, "ymin": -97670739.797244, "xmax": 127139759.526575, "ymax": 93924216.886155, "spatialReference": { "wkid": 2913, "latestWkid": 2913 } }

You might also experiment with getting the Validate Topology operation to work directly at the REST Service endpoint on your Enterprise Server and see if you can get it working there first (as in the below screenshot) if you're using an external application to hit the API. If you get it to work here, presumably it should also work by building the API call externally.

NathanGEOregon_0-1781538059446.png

 

0 Kudos
PeriklisPanagiotidis
Emerging Contributor

Yes, you are right, I linked the Utility network reference, but the call is almost the same.
Also, it seems that the validateArea parameter does make a difference. I manage to get it running by specifying it. 

So I guess the parameter is either not optional or it is a bit buggy when omitted.

Thanks for the help.

 

0 Kudos
NathanGEOregon
Frequent Contributor

Glad to help. Would you mind marking my response as the accepted solution if it resolved your question? Thanks

0 Kudos
PeriklisPanagiotidis
Emerging Contributor

Sure, even though I still think the service does not behave as it should.

0 Kudos