I am creating a disconnected checkout replica using CreateReplica on my PARENT Geodataserver, then Importing into a CHILD geodatabase. My customers will be replicating from my PARENT Geodatabase to locations worldwide and I was wondering if there is a more efficient way of doing this. I have went through every option available for CreateReplica and cannot find a more efficient way then this below. It seems to take forever for the import to happen. It takes me over a minute and I am located in the same space as the server itself. I have had one user timeout at ten minutes, so I thought I would take another look.
//Create the Replica on the Server
IGDSData gsdata = ParentGeoDataServer.CreateReplica("", ReplicaName.ToUpper(), gpReplicaDesc, replicaOptions, replicaExportOptions, esriGDSTransportType.esriGDSTransportTypeEmbedded);
//Import the Replica
Does anyone know how to perform this action in the Help for IGeoDataServer.CreateReplica Method. I have searched the ENTIRE internet trying to do this documentation here.
"For check-out replicas, you can also choose to replicate directly to a file geodatabase or personal geodatabase. Here the output is the replica geodatabase and therefore no import is required."
Then I could just skip the import if somehow I could cast the IGDSData object to my ChildGeoDataServer (File GDB) and not have to do that long import process.
use IGeoDataServer.CreateReplica(...) if you need to do replication in a "disconnected environment", where your parent database can make NO connection to your replica database.
If you want to replicate your data DIRECTLY into a replica (file) geodatabase you need to switch to a "connected environment". In that case you have to make use of the IReplicationAgent Interface from the ESRI.ArcGIS.GeoDatabaseDistributed module:
IGeoDataServer parentGeoDataServer = ...
IWorkspace myFileGdbWorkspace = ...
IGeoDataServer childGeoDataServer = ... // init from myFileGdbWorkspace ...
IReplicationAgent replicationAgent = new ReplicationAgentClass();
IGPReplicaOptions replicaOptions = ...
Hope that helps...
We originally did use the ReplicationAgent in the connected environment but ran into a number of issues with the connectivity and with the processes basically failing during transfer. We think the replication agent was also slower than the "disconnected download and import". I am downloading a Replica with about 14 feature classes.
Since I can't directly download to my Child File Geodatabase like I want, is there a way to do download and import each feauture class of the parent replica to my File Geodatabase individually instead of collectively. I have noticed that when I take a subset of my replica the speed is greatly improved. I feel that the Import function itself is taking so long to initiate the import. I say this because the ReplicaLog always shows the initial Feature class taking a very long time, and the subsequent Feature Classes of the Replica import rather quickly. Here is the first couple lines of my ReplicaLog
<ReplicaMsg time='4/14/2017 10:54:55 AM' type='LOG_MESSAGE_TYPE_INFO3' code='102010' elapsed='311.767000 seconds'</ReplicaMsg>
<ReplicaMsg time='4/14/2017 10:54:55 AM' type='LOG_MESSAGE_TYPE_INFO3' code='102011' elapsed='0.022000 seconds'</ReplicaMsg>
<ReplicaMsg time='4/14/2017 10:54:56 AM' type='LOG_MESSAGE_TYPE_INFO3' code='102010' elapsed='0.691000 seconds'</ReplicaMsg>
Any advice would be great. We are starting up my Addin in some worldwide locations and I feel the import speed could be a problem for us. I don't know if there is any ESRI TCP/IP Recommendations that our network guys might be able to employ for this GEODataServiceURL.