Dominevo
ReferenceDevice capabilities

resync

resync — a device whose derived spec can be re-aligned on demand with its upstream source (#459, Q6).

resync — a device whose derived spec can be re-aligned on demand with its upstream source (#459, Q6). Registered by the containers an integration adopted; DeviceFeature.Resyncable (the generic Re-sync button) is derived from it being bound with resync implemented.

The work itself stays where it is: the owning addon's device-adoption provider, reached through deviceManager.adoptionResync (which also owns the "resync from zero" child purge). A provider answers this method by asking for exactly that — see resyncThroughAdoption.

At a glance

Capabilityresync
Provided byThe device's own driver provides it: each device registers its own provider.
Active providers per deviceone
Device typescontainer, workload, weather-station
Sourcepackages/types/src/capabilities/resync.cap.ts

Methods

Every method takes the device id (deviceId) to address the device; the input tables below list the other fields.

MethodKindRequired of a providerAccess
resyncmutationyesadmin

resync

mutation

Input

FieldTypeRequiredDescription
resetToSourcebooleanno"Resync from zero": purge the accessory children before re-deriving.

Output

FieldTypeRequiredDescription
changedbooleanyesTrue when the persisted spec actually changed (children may have been rebuilt).
rebuiltChildrennumberyesNumber of child devices rebuilt into a new class by this re-sync.
removedChildrennumbernoNumber of accessory children torn down by a resetToSource purge before the provider re-derived the device. 0/absent for a normal incremental re-sync.