Unable to create replica or to export fGDB

932
6
03-19-2018 12:01 PM
Trippetoe
Occasional Contributor III

Hello.

We are no longer able to use the esri python API to create a replica on our survey's hosted feature layer. The error message we get looks like this:

03/14/2018 00:01:20 DEBUG arcgis._impl.connection RESPONSE: https://services2.arcgis.com/McQ0OlIABe29rJJy/arcgis/rest/services/service_<super-secret-code>/FeatureServer/createReplica, {"error":{"code":500,"message":"Unable to create replica. Please check your parameters.","details":["Error in creating runtime geodatabase."]}}
03/14/2018 00:01:20 ERROR arcgis._impl.connection Unable to create replica. Please check your parameters.
03/14/2018 00:01:20 ERROR arcgis._impl.connection Error in creating runtime geodatabase. 

Additionally, we are not able to export the hosted feature layer as a file geodatabase.

We are able to export the hosted feature layer as a feature collection, geoJson, and shapefile.  

The hosted feature service does contain attachments (signatures and images).

Perhaps co-incidentally (or not), this behavior started when we added the esri parameter: 'allowUpdates' to our repeats.  Prior to setting that value we would run the 'create replica' routine nightly without error.

Any thoughts?

Thanks,

Tom

0 Kudos
6 Replies
JamesTedrick
Esri Esteemed Contributor

Hi Tom,

I think the allowUpdates option is coincidental, as that has no relation to the feature service.  I would make sure that sync capabilities are enabled; if they are and you are having this issue, I would being it up to Esri Support noting it as an issue with the feature service.

Trippetoe
Occasional Contributor III

Hi James.

Thanks for your reply.

Yes -  sync capabilities are enabled.  I'll contact Tech Support. I'll update the thread if i learn anything interesting about this.

0 Kudos
JamieTill1
New Contributor III

We struck a similar issue recently, we found that a new domain had been added to the feature service, however it didn't have a name (it was added through the ArcGIS Solutions add in which is in ArcGI Pro) it allowed the user to add a new domain but naming the domain was optional. We had a script to download the feature class every hour and it started failing with the messages above. We found the domain in question, gave it a name and we were able to to download again. Might be related to your issue, as James says above I don't think it would be related to allowUpdates, but within the feature service itself.

Trippetoe
Occasional Contributor III

Hi Jamie.

Thanks for the tip. It appears that something was amiss with our domain definitions in one related table, but we could never pinpoint exactly what the problem was. Fortunately we have a "QA" version of the hosted feature service so we copied the 'fields' JSON definition from the QA version of the table and pasted it over the PROD version. Once we did that, we were able to export the feature service as a file Geodatabase

James Tedrick‌ - Esri Tech support recommended contacting the Survey123 team about the officially supported method for updating the domain values for a field in a hosted feature service that supports a survey, i.e. when updating the choices for survey question. Any thoughts?

0 Kudos
JamesTedrick
Esri Esteemed Contributor

Hi Tom,

I would suggest either ArcGIS Pro GP tools or the process documented in Updating Hosted Feature Services in ArcGIS Online | ArcGIS Blog  - the former would be as official as possible, the latter should work reliably (though care should be made to ensure correct syntax).

MJBiazar
Esri Contributor

Hi all, 

It seems like this post has not been active for a while but I wanted to share another cause for similar issues like this for reference here. 

Export data as filegeodatabase fails if you have a domain with codes that don't match the field type. For instance, if you have an integer field that has sting codes in domain list. On of the ways that this could happen is publishing a survey from Connect with a select_one question with integer/double type while the choices on the choice list contain string. 

In that case, not only the export fails, but also the strings that are being passed to a non-string field will be dropped during submission which is expected due to the error design that causes mismatch between the field type and domain.

 

Best,

MJ 

0 Kudos