mirror of
https://github.com/logos-storage/nim-json-rpc.git
synced 2026-01-05 23:23:12 +00:00
Switch to json_serialition.JsonString to facilitate Chronicles logging
This commit is contained in:
parent
f53e0b960b
commit
6fbaeb61ca
@ -1,14 +1,17 @@
|
||||
import
|
||||
json, tables, chronos, jsonmarshal, strutils, macros,
|
||||
chronicles, options
|
||||
export chronos, json, jsonmarshal
|
||||
json, tables, strutils, macros, options,
|
||||
chronicles, chronos, json_serialization/writer,
|
||||
jsonmarshal
|
||||
|
||||
export
|
||||
chronos, json, jsonmarshal
|
||||
|
||||
type
|
||||
RpcJsonError* = enum
|
||||
rjeInvalidJson, rjeVersionError, rjeNoMethod, rjeNoId, rjeNoParams, rjeNoJObject
|
||||
RpcJsonErrorContainer* = tuple[err: RpcJsonError, msg: string]
|
||||
|
||||
StringOfJson* = distinct string
|
||||
StringOfJson* = JsonString
|
||||
|
||||
# Procedure signature accepted as an RPC call by server
|
||||
RpcProc* = proc(input: JsonNode): Future[StringOfJson] {.gcsafe.}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user