1 // Package server provides a shared gRPC database server implementation.
2 package server
3 4 import "time"
5 6 // Config holds configuration for the database gRPC server.
7 type Config struct {
8 // Listen is the gRPC server listen address
9 Listen string
10 11 // LogLevel is the logging level
12 LogLevel string
13 14 // StreamBatchSize is the number of events per stream batch
15 StreamBatchSize int
16 17 // MaxConcurrentQueries is the max concurrent queries
18 MaxConcurrentQueries int
19 }
20 21 // DatabaseConfig holds Badger-specific configuration.
22 type DatabaseConfig struct {
23 DataDir string
24 LogLevel string
25 BlockCacheMB int
26 IndexCacheMB int
27 ZSTDLevel int
28 QueryCacheSizeMB int
29 QueryCacheMaxAge time.Duration
30 QueryCacheDisabled bool
31 SerialCachePubkeys int
32 SerialCacheEventIds int
33 }
34