<?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>topic Re: AGSGeodatabaseSyncTask: unregisterGeodatabase methods are not working in ArcGIS Runtime SDK for iOS Questions</title>
    <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/agsgeodatabasesynctask-unregistergeodatabase/m-p/1323530#M7655</link>
    <description>&lt;P&gt;Hi, I'd like to know a bit more info before I create a repro case. Can you confirm that you hold the&amp;nbsp;&lt;SPAN&gt;&lt;EM&gt;agsGdbSyncTask&lt;/EM&gt; as an instance property while the unregister method is called?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;EM&gt;AGSGeodatabaseSyncTask&lt;/EM&gt;, as a subclass to the&amp;nbsp;&lt;A href="https://developers.arcgis.com/ios/api-reference/interface_a_g_s_loadable_remote_resource_base.html" target="_self"&gt;&lt;EM&gt;AGSLoadableRemoteResourceBase&lt;/EM&gt;&lt;/A&gt;, needs to have at least 1 reference being held by another type, so it doesn't get deallocated while the syncing is happening in the background. The simplest way is to hold it as an instance property, &lt;A href="https://github.com/Esri/arcgis-runtime-samples-ios/blob/main/arcgis-ios-sdk-samples/Features/Generate%20geodatabase%20replica%20from%20feature%20service/GenerateGeodatabaseViewController.swift#L24" target="_self"&gt;as shown in this sample&lt;/A&gt;.&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Tue, 29 Aug 2023 16:03:27 GMT</pubDate>
    <dc:creator>Ting</dc:creator>
    <dc:date>2023-08-29T16:03:27Z</dc:date>
    <item>
      <title>AGSGeodatabaseSyncTask: unregisterGeodatabase methods are not working</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/agsgeodatabasesynctask-unregistergeodatabase/m-p/1323303#M7654</link>
      <description>&lt;P&gt;Hi there,&lt;/P&gt;&lt;P&gt;In our app we are trying to clean up the replica registry on our ArcGIS Servers whenever a downloaded offline geodatabase is deleted or overwritten by a new one.&lt;/P&gt;&lt;P&gt;We are using the methods&amp;nbsp;&lt;SPAN&gt;unregisterGeodatabase(_ : AGSGeodatabase, completion: (&lt;/SPAN&gt;&lt;STRONG&gt;(Error?) -&amp;gt; Void)&lt;/STRONG&gt;&lt;SPAN&gt;) and&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;unregisterGeodatabase(withSyncID: &lt;/SPAN&gt;&lt;SPAN&gt;UUID&lt;/SPAN&gt;&lt;SPAN&gt;, completion: &lt;/SPAN&gt;&lt;STRONG&gt;((Error?) -&amp;gt; Void)&lt;/STRONG&gt;&lt;SPAN&gt;)&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;on AGSGeodatabaseSyncTask to unregister the replicas. We found both methods are not working and the completion closures are never invoked.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Here are the steps we are using the methods:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;1. Create an instance (agsGdbSyncTask) of AGSGeodatabaseSyncTask with the feature service URL.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;2. Set the agsGdbSyncTask.credential as our services are secured.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;3. Load the task: agsGdbSyncTask.load() { error in ...}. The load completion closure is invoked and the error is nil.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;4. Run the above unregister methods in the completion closure of the agsGdbSyncTask.load()&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;5. Found both unregister methonds do not work and their completion closures are never called.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I'm using Xcode 14.3 and ArcGIS Runtime SDK for iOS 100.15.2. Has anybody come across this or got any idea please?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Shimin&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 29 Aug 2023 04:57:07 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/agsgeodatabasesynctask-unregistergeodatabase/m-p/1323303#M7654</guid>
      <dc:creator>ShiminCai</dc:creator>
      <dc:date>2023-08-29T04:57:07Z</dc:date>
    </item>
    <item>
      <title>Re: AGSGeodatabaseSyncTask: unregisterGeodatabase methods are not working</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/agsgeodatabasesynctask-unregistergeodatabase/m-p/1323530#M7655</link>
      <description>&lt;P&gt;Hi, I'd like to know a bit more info before I create a repro case. Can you confirm that you hold the&amp;nbsp;&lt;SPAN&gt;&lt;EM&gt;agsGdbSyncTask&lt;/EM&gt; as an instance property while the unregister method is called?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;EM&gt;AGSGeodatabaseSyncTask&lt;/EM&gt;, as a subclass to the&amp;nbsp;&lt;A href="https://developers.arcgis.com/ios/api-reference/interface_a_g_s_loadable_remote_resource_base.html" target="_self"&gt;&lt;EM&gt;AGSLoadableRemoteResourceBase&lt;/EM&gt;&lt;/A&gt;, needs to have at least 1 reference being held by another type, so it doesn't get deallocated while the syncing is happening in the background. The simplest way is to hold it as an instance property, &lt;A href="https://github.com/Esri/arcgis-runtime-samples-ios/blob/main/arcgis-ios-sdk-samples/Features/Generate%20geodatabase%20replica%20from%20feature%20service/GenerateGeodatabaseViewController.swift#L24" target="_self"&gt;as shown in this sample&lt;/A&gt;.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 29 Aug 2023 16:03:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/agsgeodatabasesynctask-unregistergeodatabase/m-p/1323530#M7655</guid>
      <dc:creator>Ting</dc:creator>
      <dc:date>2023-08-29T16:03:27Z</dc:date>
    </item>
    <item>
      <title>Re: AGSGeodatabaseSyncTask: unregisterGeodatabase methods are not working</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/agsgeodatabasesynctask-unregistergeodatabase/m-p/1323719#M7656</link>
      <description>&lt;P&gt;Thanks&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/440371"&gt;@Ting&lt;/a&gt;. Once the reference is held by a type outside of the sync scope, both unregister methods are working and the completion closures are called. Thank you so much for your help Ting. Cheers, Shimin &amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Aug 2023 00:21:24 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/agsgeodatabasesynctask-unregistergeodatabase/m-p/1323719#M7656</guid>
      <dc:creator>ShiminCai</dc:creator>
      <dc:date>2023-08-30T00:21:24Z</dc:date>
    </item>
    <item>
      <title>Re: AGSGeodatabaseSyncTask: unregisterGeodatabase methods are not working</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/agsgeodatabasesynctask-unregistergeodatabase/m-p/1340398#M7668</link>
      <description>&lt;P&gt;This saved me so much time, thank you!&lt;/P&gt;</description>
      <pubDate>Mon, 23 Oct 2023 07:47:32 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/agsgeodatabasesynctask-unregistergeodatabase/m-p/1340398#M7668</guid>
      <dc:creator>natefunk406</dc:creator>
      <dc:date>2023-10-23T07:47:32Z</dc:date>
    </item>
  </channel>
</rss>

