syncFeature method

void syncFeature(
  1. String featureKey, {
  2. bool force = false,
})

Start background sync for a specific feature. Respects concurrency limits, priority ordering, and dependencies.

Implementation

void syncFeature(String featureKey, {bool force = false}) {
  if (_disposed) return;
  if (!_featureConfigs.containsKey(featureKey)) return;

  // Force push even if running or completed
  if (force ||
      (!_runningSync.contains(featureKey) &&
          !_completedSync.contains(featureKey))) {
    _pendingQueue.add(featureKey);
  }

  _processPending();
}