server/server library

Line-oriented JSON protocol server: each client connection accepts a stream of JSON requests, one per line, and replies with one JSON object per request.

Request: {"id": <any>, "sql": "SELECT ..."} or {"id": <any>, "ping": true} Response: {"id": <same>, "ok": true, "columns": [...], "rows": [...], "affected": N, "message": "..."} {"id": <same>, "ok": false, "error": "..."}

Classes

DbServer