omnata-plugin-runtime 0.4.2a96__py3-none-any.whl → 0.4.3__py3-none-any.whl

Sign up to get free protection for your applications and to get access to all the features.
@@ -1126,6 +1126,16 @@ class InboundSyncRequest(SyncRequest):
1126
1126
  Sets the record count for a stream, used to provide progress updates.
1127
1127
  """
1128
1128
  self._stream_record_counts[stream_name] = count
1129
+
1130
+ def set_stream_total_records_estimate(self, stream_name: str, count: int):
1131
+ """
1132
+ Sets the total record count for a stream, used to provide progress updates.
1133
+ This should be a best estimate of the number of changes which will be fetched from the source.
1134
+ In other words, as results are enqueued they should build toward reaching this number as the sync progresses.
1135
+ This does not have to be exact, it's just to give the user some feedback while the sync is running.
1136
+ Totals will always be replaced by the actual count when the stream is completed.
1137
+ """
1138
+ self._total_records_estimate[stream_name] = count
1129
1139
 
1130
1140
  def _enqueue_state(self, stream_name: str, new_state: Any):
1131
1141
  """
@@ -218,7 +218,9 @@ class PluginEntrypoint:
218
218
  inbound_sync_request.update_activity("Staging remaining records")
219
219
  logger.info("Calling apply_results_queue")
220
220
  inbound_sync_request.apply_results_queue()
221
+ logger.info("Calling apply_rate_limit_state")
221
222
  inbound_sync_request.apply_rate_limit_state()
223
+ logger.info("Calling apply_progress_updates")
222
224
  inbound_sync_request.apply_progress_updates()
223
225
  if inbound_sync_request.deadline_reached:
224
226
  # if we actually hit the deadline, this is flagged by the cancellation checking worker and the cancellation
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: omnata-plugin-runtime
3
- Version: 0.4.2a96
3
+ Version: 0.4.3
4
4
  Summary: Classes and common runtime components for building and running Omnata Plugins
5
5
  Author: James Weakley
6
6
  Author-email: james.weakley@omnata.com
@@ -0,0 +1,12 @@
1
+ omnata_plugin_runtime/__init__.py,sha256=MS9d1whnfT_B3-ThqZ7l63QeC_8OEKTuaYV5wTwRpBA,1576
2
+ omnata_plugin_runtime/api.py,sha256=W79CsAcl127Dzy-XVS9CzvzsbS3IigVH4QAhFFDkaXg,6270
3
+ omnata_plugin_runtime/configuration.py,sha256=7cMekoY8CeZAJHpASU6tCMidF55Hzfr7CD74jtebqIY,35742
4
+ omnata_plugin_runtime/forms.py,sha256=pw_aKVsXSz47EP8PFBI3VDwdSN5IjvZxp8JTjO1V130,18421
5
+ omnata_plugin_runtime/logging.py,sha256=bn7eKoNWvtuyTk7RTwBS9UARMtqkiICtgMtzq3KA2V0,3272
6
+ omnata_plugin_runtime/omnata_plugin.py,sha256=mCZ0904ONvYx6VFsoTHI45gA4dvUv30fYBO9DWIYDa0,107734
7
+ omnata_plugin_runtime/plugin_entrypoints.py,sha256=wco1QqubxxE-cMYQiu8D3pUZss3QeiAlrF2UFg5m0GM,28404
8
+ omnata_plugin_runtime/rate_limiting.py,sha256=29Hjsr0i1rE8jERVdIFGINfQfp_kI3PDft-IM_ZxvCA,21509
9
+ omnata_plugin_runtime-0.4.3.dist-info/LICENSE,sha256=IMF9i4xIpgCADf0U-V1cuf9HBmqWQd3qtI3FSuyW4zE,26526
10
+ omnata_plugin_runtime-0.4.3.dist-info/METADATA,sha256=z6mxU9qUCvgmi-ROy_B2Jibo_OVJqRF4c0Olo4-f-48,1638
11
+ omnata_plugin_runtime-0.4.3.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
12
+ omnata_plugin_runtime-0.4.3.dist-info/RECORD,,
@@ -1,12 +0,0 @@
1
- omnata_plugin_runtime/__init__.py,sha256=MS9d1whnfT_B3-ThqZ7l63QeC_8OEKTuaYV5wTwRpBA,1576
2
- omnata_plugin_runtime/api.py,sha256=W79CsAcl127Dzy-XVS9CzvzsbS3IigVH4QAhFFDkaXg,6270
3
- omnata_plugin_runtime/configuration.py,sha256=7cMekoY8CeZAJHpASU6tCMidF55Hzfr7CD74jtebqIY,35742
4
- omnata_plugin_runtime/forms.py,sha256=pw_aKVsXSz47EP8PFBI3VDwdSN5IjvZxp8JTjO1V130,18421
5
- omnata_plugin_runtime/logging.py,sha256=bn7eKoNWvtuyTk7RTwBS9UARMtqkiICtgMtzq3KA2V0,3272
6
- omnata_plugin_runtime/omnata_plugin.py,sha256=sh19I-l2xIc7aPxO83mv65rijMPfCIDqh5o6sguc1H4,107066
7
- omnata_plugin_runtime/plugin_entrypoints.py,sha256=D2f0Qih7KTJNXIDYkA-E55RTEK_7Jtv9ySqspWxERVA,28272
8
- omnata_plugin_runtime/rate_limiting.py,sha256=29Hjsr0i1rE8jERVdIFGINfQfp_kI3PDft-IM_ZxvCA,21509
9
- omnata_plugin_runtime-0.4.2a96.dist-info/LICENSE,sha256=IMF9i4xIpgCADf0U-V1cuf9HBmqWQd3qtI3FSuyW4zE,26526
10
- omnata_plugin_runtime-0.4.2a96.dist-info/METADATA,sha256=0Fqdchk6xwORzJ4qNwCgT881jVGLFKY9p_P9XtbxUv0,1641
11
- omnata_plugin_runtime-0.4.2a96.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
12
- omnata_plugin_runtime-0.4.2a96.dist-info/RECORD,,