Skip to content

Node.js: local mode that runs the embedded engine #73

Done

Description

@jmmana

Objetivo

Use the embedded engine from Node.js with the same API as remote mode.

Criterios de aceptación

  • await SqlGuard.local({ policy | policyPath, role }) next to the existing new SqlGuard({ url }); check, enforce and explain and their result types are the same in both modes
  • Child-process lifecycle: lazy start, hello version check, concurrent calls multiplexed by request id, per-call timeout, close() and Symbol.asyncDispose, the engine is killed when the process exits
  • If the engine crashes, pending and new calls fail closed (allowed: false) and it restarts with backoff
  • TypeScript types for policies, results and protocol messages generated from schema/; CI fails when they are stale
  • ESM and CommonJS; Node 18, 20 and 22; Bun best effort; Deno, browsers and edge runtimes documented as remote mode only
  • CI matrix Linux, macOS and Windows runs the unit tests and the whole conformance corpus (plus fuzz and red-team regressions) in local mode

Archivos relevantes

  • clients/node/src/
  • clients/node/test/
  • .github/workflows/node-client.yml

Tamaño

L (three to five days)

Notas

Activity

  1. added
    type:feature
    size:l
    lang:node
    on Nov 26, 2026
  2. jmmana commented on Nov 27, 2026

    @jmmana
    OwnerAuthor

    /warcodex proveedor=claude cuenta="Warlock"

  3. jmmana commented on Nov 27, 2026

    @jmmana
    OwnerAuthor

    WarCodex: esperará a que terminen #68, #72 antes de empezar.

  4. added
    warcodex:necesita-info
    on Nov 27, 2026
  5. jmmana commented on Nov 27, 2026

    @jmmana
    OwnerAuthor

    WarCodex no puede empezar todavía: falta información en el issue.

    • ¿Cuál es el objetivo? Describe el cambio y su motivo en pocas líneas (un solo resultado).
    • ¿Cómo sabremos que terminó? Añade criterios de aceptación como casillas - [ ] ..., cada una verificable con un comando o una prueba.
    • ¿En qué archivos relevantes hay que trabajar y qué pruebas deben seguir pasando?

    Edita el issue (usa la plantilla de WarCodex) y lo reviso de nuevo automáticamente.

  6. added
    p1
    and removed
    warcodex:necesita-info
    on Nov 27, 2026
  7. 8 remaining items

  8. removed
    warcodex:en-progreso
    on Nov 27, 2026
  9. jmmana commented on Nov 27, 2026

    @jmmana
    OwnerAuthor

    WarCodex: PR abierto: #117

  10. added
    warcodex:en-progreso
    and removed
    warcodex:revision
    on Nov 27, 2026
  11. jmmana commented on Nov 27, 2026

    @jmmana
    OwnerAuthor

    WarCodex: empezó a trabajar en este issue (intento 2).

  12. added
    warcodex:revision
    on Nov 27, 2026
  13. jmmana commented on Nov 27, 2026

    @jmmana
    OwnerAuthor

    WarCodex actualizó el PR #117 con los cambios pedidos (intento #2, vuelta de revisión 1): pendiente de revisión.

    Base: main · rama: warcodex/issue-73

  14. removed
    warcodex:en-progreso
    on Nov 27, 2026
  15. jmmana commented on Nov 27, 2026

    @jmmana
    OwnerAuthor

    WarCodex: PR abierto: #117

  16. added
    warcodex:listo
    and removed
    warcodex:revision
    on Nov 27, 2026
  17. jmmana commented on Nov 27, 2026

    @jmmana
    OwnerAuthor

    WarCodex: listo, PR fusionado: #117

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    lang:nodep1size:ltype:featurewarcodex:listo

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions