-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathnats.conf
More file actions
17 lines (17 loc) · 835 Bytes
/
Copy pathnats.conf
File metadata and controls
17 lines (17 loc) · 835 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# NATS server config for local dev. max_payload is NOT a CLI flag in
# nats-server (it is config-file-only), so the 16 MiB cap that a traffic_event
# with a large prompt/response body needs must be set here. Matches the AMI
# nats max_payload and the Hub ConnectRPC 16MB frame cap.
port: 4222
http_port: 8222
max_payload: 16777216
jetstream {
store_dir: "/data"
# Audit / traffic_event data is async and NOT latency-critical, and bounded
# loss is already tolerated (the gateway drops under backpressure by design).
# Batch the fsync-to-disk so JetStream coalesces writes instead of flushing
# near-every batch — the dominant NATS CPU/IO cost under write-heavy audit
# load. Crash loses at most sync_interval of un-fsynced audit, acceptable for
# this stream. Mirror this in the AMI nats.conf.
sync_interval: "30s"
}