<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>idea Collector Replica Management in ArcServer in ArcGIS Enterprise Ideas</title>
    <link>https://community.esri.com/t5/arcgis-enterprise-ideas/collector-replica-management-in-arcserver/idi-p/923166</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Having now been running collector within our organisation for the last 4 years I have come across several issues with managing the ever increasing replicas generated from substantial use. One of our databases has over 400 replicas due to the volume of users and number of maps downloaded.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There are several scenarios in which orphaned replicas can be created in the offline workflows:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Device Lost, Damaged&lt;/LI&gt;&lt;LI&gt;Device Hard Reset&lt;/LI&gt;&lt;LI&gt;App Uninstalled&lt;/LI&gt;&lt;LI&gt;Network dropout during initial download&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Recently I had a scenario in which a database had blown out substantially in size, after detailed investigation there were several replicas which had been orphaned for some time and were storing a large amount of changes.&amp;nbsp;Currently the tools are problematic to identify which replicas we can safely remove and which need to be kept.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;doing this manually is very time consuming and has dangers due to the interface in which you can remove a replica is not able to have a filter applied, and crashes when you sort the table more than once.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can access using python the last sent and last received dates for a replica but you can't access when a replica was created? Neither can you un-register a replica using python, although I suspect this is a good thing as this has large disaster potential. We do need a better way to mange this potential mine field of performance and storage liability better.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Personally I would like a means to use the properties you can get from&amp;nbsp;&lt;SPAN class="" style="color: #4d4d4d;"&gt;arcpy&lt;/SPAN&gt;&lt;SPAN class="" style="color: #4d4d4d;"&gt;.&lt;/SPAN&gt;&lt;SPAN class="" style="color: #4d4d4d;"&gt;da&lt;/SPAN&gt;&lt;SPAN class="" style="color: #4d4d4d;"&gt;.&lt;/SPAN&gt;&lt;SPAN class="" style="color: #4d4d4d;"&gt;ListReplicas to include the created date and be able to use the Replica Class properties in other tools or as a means to filter the replicas in a more stable dialog window. Potentially an ability to "TAG" a replica with the results of a python script would be incredibly helpful.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Add extra Column and sort and filter buttons" class="image-1 jive-image j-img-original" src="https://community.esri.com/legacyfs/online/432726_Replica_Manager.PNG" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This BUG with the Replica Manager button has been consistent since 10.3 when I first found it. Still waiting for a fix other than don;t click on the column title more than once.&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Give it a try happens every time" class="image-2 jive-image j-img-original" src="/legacyfs/online/432727_Sort twice in Replica Manager.PNG" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 08 Jan 2019 08:22:12 GMT</pubDate>
    <dc:creator>MPC_KineticGIS_Department</dc:creator>
    <dc:date>2019-01-08T08:22:12Z</dc:date>
    <item>
      <title>Collector Replica Management in ArcServer</title>
      <link>https://community.esri.com/t5/arcgis-enterprise-ideas/collector-replica-management-in-arcserver/idi-p/923166</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Having now been running collector within our organisation for the last 4 years I have come across several issues with managing the ever increasing replicas generated from substantial use. One of our databases has over 400 replicas due to the volume of users and number of maps downloaded.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There are several scenarios in which orphaned replicas can be created in the offline workflows:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Device Lost, Damaged&lt;/LI&gt;&lt;LI&gt;Device Hard Reset&lt;/LI&gt;&lt;LI&gt;App Uninstalled&lt;/LI&gt;&lt;LI&gt;Network dropout during initial download&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Recently I had a scenario in which a database had blown out substantially in size, after detailed investigation there were several replicas which had been orphaned for some time and were storing a large amount of changes.&amp;nbsp;Currently the tools are problematic to identify which replicas we can safely remove and which need to be kept.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;doing this manually is very time consuming and has dangers due to the interface in which you can remove a replica is not able to have a filter applied, and crashes when you sort the table more than once.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can access using python the last sent and last received dates for a replica but you can't access when a replica was created? Neither can you un-register a replica using python, although I suspect this is a good thing as this has large disaster potential. We do need a better way to mange this potential mine field of performance and storage liability better.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Personally I would like a means to use the properties you can get from&amp;nbsp;&lt;SPAN class="" style="color: #4d4d4d;"&gt;arcpy&lt;/SPAN&gt;&lt;SPAN class="" style="color: #4d4d4d;"&gt;.&lt;/SPAN&gt;&lt;SPAN class="" style="color: #4d4d4d;"&gt;da&lt;/SPAN&gt;&lt;SPAN class="" style="color: #4d4d4d;"&gt;.&lt;/SPAN&gt;&lt;SPAN class="" style="color: #4d4d4d;"&gt;ListReplicas to include the created date and be able to use the Replica Class properties in other tools or as a means to filter the replicas in a more stable dialog window. Potentially an ability to "TAG" a replica with the results of a python script would be incredibly helpful.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Add extra Column and sort and filter buttons" class="image-1 jive-image j-img-original" src="https://community.esri.com/legacyfs/online/432726_Replica_Manager.PNG" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This BUG with the Replica Manager button has been consistent since 10.3 when I first found it. Still waiting for a fix other than don;t click on the column title more than once.&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Give it a try happens every time" class="image-2 jive-image j-img-original" src="/legacyfs/online/432727_Sort twice in Replica Manager.PNG" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 08 Jan 2019 08:22:12 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-enterprise-ideas/collector-replica-management-in-arcserver/idi-p/923166</guid>
      <dc:creator>MPC_KineticGIS_Department</dc:creator>
      <dc:date>2019-01-08T08:22:12Z</dc:date>
    </item>
    <item>
      <title>Re: Collector Replica Management in ArcServer</title>
      <link>https://community.esri.com/t5/arcgis-enterprise-ideas/collector-replica-management-in-arcserver/idc-p/923167#M132</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;So with complete frustration with the processes available I have managed to scrape together info from multiple sources to build this simple script that outputs the main info you need about your replicas.&lt;/P&gt;&lt;P&gt;Runs infinitely faster than the embedded arcpy.da.ListReplicas module and gives you better more useful information.&lt;/P&gt;&lt;P&gt;Just need to filter the list based on your criteria and feed into the API backend of ArcServer to remove the ones you need.&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;&lt;SPAN class="keyword token"&gt;import&lt;/SPAN&gt; pyodbc
&lt;SPAN class="keyword token"&gt;import&lt;/SPAN&gt; datetime

&lt;SPAN class="keyword token"&gt;print&lt;/SPAN&gt; datetime&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;datetime&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;now&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
conn_str &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; r&lt;SPAN class="string token"&gt;'Driver={SQL Server};'&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; r&lt;SPAN class="string token"&gt;'Server=SERVER\INSTANCE;'&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; r&lt;SPAN class="string token"&gt;'Database=DATABASENAME;'&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; r&lt;SPAN class="string token"&gt;'Trusted_Connection=yes;'&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
cnxn &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; pyodbc&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;connect&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;conn_str&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;

cursor &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; cnxn&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;cursor&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
query &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;"""WITH 
&amp;nbsp; cteReplicaLog(ReplicaID, MaxLogDate)
&amp;nbsp; AS 
&amp;nbsp; (
&amp;nbsp;&amp;nbsp;&amp;nbsp; SELECT ReplicaID, MAX(LogDate)
&amp;nbsp;&amp;nbsp;&amp;nbsp; FROM&amp;nbsp;&amp;nbsp; sde.GDB_REPLICALOG
&amp;nbsp;&amp;nbsp;&amp;nbsp; GROUP&amp;nbsp; BY ReplicaID
&amp;nbsp; )
SELECT 
&amp;nbsp;&amp;nbsp;&amp;nbsp; ITEMS.UUID,
&amp;nbsp;&amp;nbsp;&amp;nbsp; ITEMS.Definition .value( '(/GPReplica/ID)[1]', 'nvarchar(max)') AS "ID" ,
&amp;nbsp;&amp;nbsp;&amp;nbsp; ITEMS.Definition .value( '(/GPReplica/Name)[1]', 'nvarchar(max)') AS "Replica Name" ,
&amp;nbsp;&amp;nbsp;&amp;nbsp; ITEMS.Definition .value( '(/GPReplica/ReplicaVersion)[1]', 'nvarchar(max)') AS "Replica Version" ,
&amp;nbsp;&amp;nbsp;&amp;nbsp; ITEMS.Definition .value( '(/GPReplica/CreationDate)[1]', 'smalldatetime') AS "Creation Date",
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ISNULL(CAST(replicalog.MaxLogDate AS smalldatetime), NULL) AS 'Sync Time'
FROM&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; sde.GDB_ITEMS AS items
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; INNER JOIN sde.GDB_ITEMTYPES AS itemtypes
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ON items.Type = itemtypes.UUID
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; LEFT JOIN cteReplicaLog AS replicalog
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ON items.ObjectID = replicalog.ReplicaID
WHERE
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; itemtypes.Name = 'Replica'
ORDER&amp;nbsp; BY 'Replica Name', 'Sync Time' ;
"""&lt;/SPAN&gt;
cursor&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;execute&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;query&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
replicas_data &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;[&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;]&lt;/SPAN&gt;
&lt;SPAN class="keyword token"&gt;while&lt;/SPAN&gt; &lt;SPAN class="number token"&gt;1&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;:&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; row &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; cursor&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;fetchone&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="keyword token"&gt;if&lt;/SPAN&gt; &lt;SPAN class="operator token"&gt;not&lt;/SPAN&gt; row&lt;SPAN class="punctuation token"&gt;:&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="keyword token"&gt;print&lt;/SPAN&gt; replicas_data
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="keyword token"&gt;break&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; replicas_data&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;append&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;row&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
cnxn&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;close&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 11:51:19 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-enterprise-ideas/collector-replica-management-in-arcserver/idc-p/923167#M132</guid>
      <dc:creator>MPC_KineticGIS_Department</dc:creator>
      <dc:date>2021-12-12T11:51:19Z</dc:date>
    </item>
  </channel>
</rss>

