Skip to content

Conversation

@keelerm84
Copy link
Member

@keelerm84 keelerm84 commented Oct 23, 2025

Note

Adds persistent data store (read-only/read-write) support to FDv2 with status monitoring, configuration hooks, and comprehensive tests.

  • FDv2 / Data System:
    • Integrates optional persistent FeatureStore with read-only/read-write modes via FeatureStoreClientWrapper; wires DataStoreStatusProvider and availability monitoring; exposes data_store_status_provider.
    • Improves logging (replace prints with log).
  • Config / Builder:
    • Extends DataSystemConfig with data_store_mode and data_store; primary_synchronizer now optional.
    • ConfigBuilder adds data_store(...), relaxes build rule (secondary requires primary), and provides daemon(...) and persistent_store(...) helpers.
  • Status & Interfaces:
    • Adds DataStoreMode enum; implements DataStoreStatusProviderImpl and DataStoreStatus.__eq__.
    • DataStoreStatusProvider.is_monitoring_enabled() support and propagation from stores.
  • Store:
    • Dual-mode in-memory/persistent behavior; persists full and delta updates when writable; adds error logging.
  • Tests:
    • Adds extensive persistence and status tests (test_fdv2_persistence.py) and updates config builder tests.

Written by Cursor Bugbot for commit 4e44909. This will update automatically on new commits. Configure here.

@keelerm84 keelerm84 requested a review from a team as a code owner October 23, 2025 16:46
@cursor
Copy link

cursor bot commented Oct 23, 2025

Bug: Deadlock Risk in FeatureStoreClientWrapper

In FeatureStoreClientWrapper.__update_availability, the lock acquired before self.__poller.start() isn't released if start() raises an exception. This missing try/finally block can lead to a deadlock, contrasting with other lock usages in the method.

Additional Locations (1)

Fix in Cursor Fix in Web

self.__lock.unlock()

if modified:
self.__listeners.notify(status)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is the threading situation like for this dispatch? Is the caller thread always the same thread?

"""
update_status is called from the data store to push a status update.
"""
self.__lock.lock()
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a reason this has to use lock/unlock vs with?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants