Investigate Failures and Dead Letter Messages
A message failure could occur when you perform an action on your design or the action itself initiates another workflow event. Typically, a failure results in a “dead letter” message, which means the message that was in-process could not finish.
Please see the previous topic on how to use the Design tab interface. The topics below describe investigating common errors and how to understand the exception messages.
Types of Errors
-
ArcGIS Server Errors
An exception message that contains “SE.ArcGIS.Driver.ArcGISException” typically came from ArcGIS Server, which can encounter errors while handling the ApplyEdits Request. In the same exception message, you are most likely to see Error Code 400 or Error Code 500.
-
Error Code 400: This means the request reached the service, but it failed to process. You can investigate further by looking at the ArcGIS Server Logs and the ArcFM Server Event Logs (described below).
-
Error Code 500: This means the feature service was unreachable. Check to see that ArcGIS Server is running and that the feature service is running. If they are running, then check that the Edge Service has connectivity to the feature service machine.
-
-
Task Canceled Errors
These errors usually indicate a timeout has occurred. Processing a message took too long, so the Edge Service stopped waiting for a response and issued this error. Sometimes, this does not ultimately end in a failure. For example, if an ArcGIS Server request takes too long, the Edge Service stops waiting and issues the error. However, ArcGIS Server continues to process the request until finished (or until it reaches its own internal timeout threshold). Thus, the process might have ultimately finished after the error was issued. It is recommended to look at designs bearing a “task canceled” error to see if they are actually in an expected state or if the process truly failed.
ArcGIS Server Logs
ArcGIS Server Logs can be voluminous. To help steer the conversation, this section uses the following exception message as its starting point:
The message above includes Error Code 400, which means the request reached the service, but it failed to process. With that in mind, you need to look at the ArcGIS Server Logs.
In the Logs interface, use the filters to your advantage to locate the exception.
As seen in the image below, the logs include more information about the exception. In this case, the two helpful pieces of information include the layer number in the published service (34) and that there is a mismatch between an attribute data value and a field data type within the field RECLOSEROBJECTID.
The next step is to look at which layer or table is failing (in this case, it is 34). The quickest way to see the layers and tables included in the published service is to:
-
Click on Services.
-
Click on the map service name.
-
Click Capabilities.
-
Click Feature Access.
-
Click the Rest URL.
-
Locate the layer or table that matches the number referenced in the ArcGIS Server Log (again, in this case it is 34).
If you recall from above, there is a data type mismatch for the RECLOSEROBJECTID field, and now we know it occurred within the RECLOSERUNIT table. The quickest way to see the data type for this field is to click the layer/table name. This opens a separate browser tab to view all the information about the RECLOSERUNIT table, including the field data types. As you can see in the image below, the RECLOSEROBJECTID field is set to integer.
Knowing there was a data mismatch between an attribute data type and a field data type within the Recloser Unit table might be enough to know what went wrong. However, you can dig further to see exactly what the attribute was that caused the problem by viewing the ApplyEdits request.
The ApplyEdits Request
The ApplyEdits Request details can be seen in the Edge Service Logs or the ArcGIS Server Logs (if ArcGIS Server Logs are set to a log level of Debug, which is found in the Log Settings).
-
The Edge Service Logs are located on the server hosting the service, in the directory C:\Program Files\Schneider Electric\Designer Edge Service\logs.
-
The ArcGIS Server Logs are located on the server hosting the service, in the directory C:\arcgisserver\logs.
To view the relevant ApplyEdits Request, follow these steps:
-
Locate the log that corresponds with the day of the error.
-
Use the timestamps in the log to find your entry, or search for the design name that failed.
-
Copy the relevant text from the log (it is in JSON format), and paste into a text editor that has a JSON Viewer option, such as Notepad ++. This helps format the text and make it readable. Continuing the example above, the formatted request looks like the following:
{ "id": 34, "adds": { { "attributes": { "RELATEDRECLOSERNDID:": "{089d890e-4j2j-8aa9-90c9-d89a310f1fe1}", "RECLOSEROBJECTID": "{089D890E-4F2F-8AA9-90C9-D89A310F1FE1}", "PHASEDESIGNATION": 4, "MODEL": "W-SERIES", etc.
Looking at the request above, a GUID was sent for the RECLOSEROBJECTID. However, from the published service, this field is set to Integer. Thus, it failed.
ArcFM Server Event Logs
In order to view the ArcFM Server Event Logs, first remote into the machine hosting ArcFM Sever (and ArcGIS Server). Once on that machine, search for Event Viewer in the task bar. Then, browse to Applications and Services Logs > Miner.
Then, look for errors associated with ArcFM Server near the timestamp of your exception.
The most typical reason for an ArcFM Server error is an auto-updater (AU) failure. With Schneider Electric Support help, you might need to either change the AU or the data framework that drives the AU for the design to be pushed successfully to the GIS.