@@ -12,7 +12,6 @@ import (
"bufio"
"bytes"
"crypto/md5"
- "encoding/json"
"flag"
"fmt"
"math"
@@ -23,6 +22,8 @@ import (
"strconv"
"strings"
"time"
+
+ "github.com/goccy/go-json"
)
const engineName = "pizzasql"
@@ -1,3 +1,5 @@
module github.com/danfragoso/pizzasql-next
go 1.24
+require github.com/goccy/go-json v0.10.6 // indirect
@@ -1,7 +1,6 @@
package httpserver
import (
"io"
"net/http"
@@ -9,6 +8,8 @@ import (
"sync/atomic"
"github.com/danfragoso/pizzasql-next/pkg/csvexport"
"github.com/danfragoso/pizzasql-next/pkg/csvimport"
"github.com/danfragoso/pizzasql-next/pkg/lexer"
@@ -1,9 +1,10 @@
"log"
// ColumnInfo represents column metadata.
@@ -82,11 +83,11 @@ func writeError(w http.ResponseWriter, status int, code, message string, details
Details: details,
},
}
-
// Log server errors (5xx status codes)
if status >= 500 {
log.Printf("ERROR [%d] %s: %s", status, code, message)
writeJSON(w, status, resp, false)
@@ -3,7 +3,6 @@ package httpserver
"compress/gzip"
"net/http/httptest"
@@ -11,6 +10,8 @@ import (
"testing"
"github.com/danfragoso/pizzasql-next/pkg/executor"
"github.com/danfragoso/pizzasql-next/pkg/storage"
package kvmanager
"net"
"os"
"syscall"
// KVInfo contains information about the running PizzaKV instance
@@ -1,12 +1,13 @@
package storage
"sync"
"github.com/danfragoso/pizzasql-next/pkg/analyzer"
@@ -1,10 +1,11 @@
// Row represents a database row.