Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

[NFR]: Decouple collectors from framework event names (bridge + canonical signals)

Aperta
#15 0 commenti 0 reazioni 1 assegnatario Vedi su GitHub

I maintainer di solito rispondono entro 3 giorni

@niden ci sta già lavorando.

Dal 22/7/2026.

Valutazione

Questa issue non è ancora stata valutata.

Descrizione

enhancement
Summary

Collectors gather data by subscribing to MVC-specific event names, so nothing collects under ADR or any non-MVC stack. Introduce a neutral seam - a canonical debug-bar signal set, a per-framework bridge, and a direct push API - so collectors receive data regardless of the host application's event vocabulary, or the absence of one.

Current coupling

Collectors call subscribe(ManagerInterface $eventsManager) and attach to framework event names:

  • DatabaseCollector → db:beforeQuery, db:afterQuery
  • ViewCollector → view:beforeRenderView, view:afterRenderView
  • RouteCollector → router:matchedRoute
  • ExceptionsCollector → dispatch:beforeException
  • CacheCollector → cache events

These names are emitted by the MVC stack. ADR fires a different vocabulary (APPLICATION_*, ADR_*, PIPELINE_*), and some hosts have no events manager at all.

Proposed direction (three layers)
  1. Canonical signal set owned by the bar - a small, stable vocabulary (query, view.rendered, route.matched, request.received, response.sending). Collectors subscribe only to these.
  2. Per-framework bridge that maps native signals to canonical ones. The MVC bridge listens to db:afterQuery / view:* / router:matchedRoute and re-emits canonical signals (current behavior, refactored behind the bridge). The ADR bridge listens to PIPELINE_* / APPLICATION_*, or instruments directly where no matching event exists.
  3. Direct push API on collectors (e.g. record(...)) for hosts with no events manager - the bridge pushes directly.

The events manager becomes an implementation detail of the active bridge, not a hard dependency of the collectors.

Acceptance
  • A collector receives data through the canonical signals with no reference to a framework-specific event name.
  • The MVC bridge preserves current behavior (as used by phalcon/vokuro), verified by the existing tests.
  • A collector can be fed with no events manager present (push API).
Lingua principale
PHP
Stelle
6
Fork
3
Merge medio
1g 17h
PR unite (30g)
3

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di phalcon/debugbar

Tutte le issue di phalcon/debugbar

Issue simili

Altre issue su PHP

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.