feat(platform-core): Capability → Event Bus bridge runtime wiring (W4)#75
Merged
Merged
Conversation
Mevcut CapabilityEventBridge foundation'i (PR #54) ILK kez gercek capabilityRegistry singleton'ina ve W3'un TEK aktif appEventBus'ina baglar (W4C'nin Vehicle HAL esleniği). Zincir: capabilityRegistry → CapabilityEventBridge → getAppEventBus(). Salt-okunur analiz: appEventBus sahipligi (PR #66) ve HAL→bus bridge (W4C/#70) ZATEN vardi; tek bosluk Capability→bus bridge idi (SystemBoot'ta capabilityEventBridge kaydi yoktu). Bu PR yalniz o boslugu kapatir. SystemBoot Wave 2'de Capability Registry wiring'inden SONRA additive _reg kaydi (LIFO: bridge once, registry/bus sonra dispose; savunmaci try/catch fail-soft). Event'ler: capability.record.registered/changed/removed + capability.snapshot.changed (RETAINED, kucuk payload {revision,sayimlar,changedIds} — full registry TASINMAZ). Imza-dedup; domain=capability, source=capability_registry. IKINCI bus YARATILMAZ (getAppEventBus tuketilir). Deep Scan/Driver DNA/Prediction/Assistant Context/Kernel/ tuketici migrasyonu YOK; abone YOK; timer/polling/throttle YOK (capability degisimleri NADIR → Mali-400 hot-path riski YOK); import yan etkisiz; tek-instance guard; Registry+Bus PAYLASILAN → cleanup dispose ETMEZ. Test: 36 yeni test (yasam dongusu/event akisi/dedup/duplicate/fail-soft/bounded status/ privacy/kapsam-siniri/SystemBoot sira kilidi). Tam suite 3639 yesil (203 dosya), tsc temiz, lint 0 error, build OK. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0141GKY1eQru4Ap1PWN4VVst
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Amaç (Roadmap FAZ 2 · W4 — Platform Event Bus Runtime Wiring)
Mevcut CapabilityEventBridge foundation'ını (PR #54) İLK kez gerçek
capabilityRegistrysingleton'ına ve W3'ün TEK aktif
appEventBus'ına bağlar. Bu, W4C'nin (Vehicle HAL → Busbridge) capability eşleniğidir — birebir aynı desen.
Salt-okunur analiz (varsayım yok) — 10 soru
platformCoreEventBusWiring.ts(PR #66), tekappEventBussahibigetAppEventBus()accessorplatformCoreVehicleHalBridgeWiring(W4C/#70), SystemBoot:548vehicle.signal.changed(transient)+connection/ignition/identity.changed(retained) · Cap:capability.record.registered/changed/removed+capability.snapshot.changed(retained)vehicle.signal.changedtransient/history dışı?transient:true(vehicleHalEventBridge:186-195)capability.snapshot.changedretained?retained:true(capabilityEventBridge:231-239)Sonuç: appEventBus sahipliği + HAL bridge ZATEN vardı; yeniden yazılmadı. Tek boşluk = Capability→bus bridge.
Değişen dosyalar
platformCoreCapabilityBridgeWiring.tscapabilityRegistry → CapabilityEventBridge → getAppEventBus()SystemBoot.ts_regplatformCoreCapabilityBridgeWiring.test.tsDEVICE_VALIDATION_LEDGER.mdSahiplik & sıra
İKİNCİ bus YARATILMAZ (
getAppEventBus()tüketilir). Bridge Registry/Bus sahibi DEĞİL →cleanup yalnız bridge'i dispose eder. SystemBoot LIFO: bridge önce dispose (registry/bus ayakta).
Event davranışı
capability.snapshot.changedretained, küçük payload (revision+sayımlar+bounded changedIds) —full registry TAŞINMAZ. İmza-dedup → aynı record değişimi event üretmez. domain=
capability,source=
capability_registry. HALvehicle.signal.changedtransient davranışı korunur (W4C).Performans / Mali-400
timer/polling/throttle YOK · O(1) dedup · hot-path JSON.stringify/clone YOK · pasifken sıfır yük ·
capability değişimleri nadir → event CPU bütçesi ihmal edilebilir (HAL sinyal frekansından bağımsız).
Fail-soft / observability
Bus/Registry subscribe hatası boot'u çökertmez · publish hatası kaynağı etkilemez →
droppedCount·public API throw etmez · cleanup idempotent ·
getCapabilityBridgeStatus()bounded (payload/telemetri yok).Doğrulama
36 yeni test · tam suite 3639 yeşil (203 dosya) ·
tsc -btemiz · lint 0 error · build OK.Ledger #59 🔴 — cihaz doğrulaması bekliyor (tek bus, tek başlatma, retained snapshot, Mali-400 <%2 CPU).
Not
Repoda
MASTER_ROADMAP.md/PROJECT_STATUS.mdyok (yalnızROADMAP.md); atomikliği korumak içinbu PR'da roadmap dosyasına dokunulmadı.
🤖 Generated with Claude Code