replace Redis with an embedded SQLite string->string KV store (group commit, in-tx events, SQL search)
Build and Push Docker Image / build (push) Successful in 2m44s
Build and Push Docker Image / build (push) Successful in 2m44s
This commit is contained in:
+3
-3
@@ -7,7 +7,7 @@ package api
|
||||
// meta-watch's local op-log. Records arrive already signed (and, for
|
||||
// private-tier keys, already encrypted) as opaque base64 CBOR blobs; meta-core
|
||||
// version-gates and indexes them but never inspects the crypto. See
|
||||
// internal/storage/udl.go for the Redis model.
|
||||
// internal/storage/udl.go for the key model.
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
@@ -65,7 +65,7 @@ type UDLPutBatchResponse struct {
|
||||
Results []UDLPutBatchResult `json:"results"`
|
||||
}
|
||||
|
||||
// maxUDLBatch bounds one batch. Each record is a Redis round trip while the
|
||||
// maxUDLBatch bounds one batch. Each record is a store write while the
|
||||
// request is held open; sized to match the sign batch on the other side of the
|
||||
// same operation (see maxSignBatch).
|
||||
const maxUDLBatch = 1000
|
||||
@@ -126,7 +126,7 @@ func (s *Server) handleUDLRecordGet(w http.ResponseWriter, r *http.Request) {
|
||||
Exists: exists,
|
||||
}
|
||||
// json.Valid guards the encoder: a malformed `value` hash field (hand-edited
|
||||
// Redis, a future writer bug) would otherwise fail mid-encode and emit a
|
||||
// the store, a future writer bug) would otherwise fail mid-encode and emit a
|
||||
// truncated body instead of a readable error.
|
||||
if exists && cell.HasValue && json.Valid([]byte(cell.Value)) {
|
||||
raw := json.RawMessage(cell.Value)
|
||||
|
||||
Reference in New Issue
Block a user