Closed rblaine95 closed 1 month ago
Omitting the cluster
config if replicaCount < 2
results in Jetstream successfully starting up:
[1] [INF] Using configuration file: /opt/bitnami/nats/conf/nats-server.conf
[1] [INF] Starting http monitor on 0.0.0.0:8222
[1] [INF] Starting JetStream
[1] [INF] _ ___ _____ ___ _____ ___ ___ _ __ __
[1] [INF] _ | | __|_ _/ __|_ _| _ \ __| /_\ | \/ |
[1] [INF] | || | _| | | \__ \ | | | / _| / _ \| |\/| |
[1] [INF] \__/|___| |_| |___/ |_| |_|_\___/_/ \_\_| |_|
[1] [INF]
[1] [INF] https://docs.nats.io/jetstream
[1] [INF]
[1] [INF] ---------------- JETSTREAM ----------------
[1] [INF] Max Memory: 122.07 MB
[1] [INF] Max Storage: 10.00 GB
[1] [INF] Store Directory: "/data/jetstream/jetstream"
[1] [INF] -------------------------------------------
[1] [INF] Listening for client connections on 0.0.0.0:4222
[1] [INF] Server is ready
Hi!
Thank you so much for the PR! The team will take a look
Name and Version
bitnami/nats 8.3.5
What architecture are you using?
None
What steps will reproduce the bug?
The
nats-0
pod will start up without issue, but Jetstream will never succeed in starting up, constantly warning about waiting for routes to be established:Are you using any custom parameters or values?
What is the expected behavior?
Jetstream should start up without issue
What do you see instead?
Jetstream never starts up unless
replicaCount
is greater than 1.Additional information
Currently, the chart's behavior regarding clustering, replica count, and Jetstream isn't clearly defined. I propose the following improvements:
Current behavior
cluster
config is present, Jetstream requires a minimum of 2 replicas.cluster
config allowsreplicaCount=1
andjetstream.enabled=true
.Proposed changes
Enable clustering if EITHER of these conditions is true:
Implement this logic using the following Helm template condition:
Otherwise, keep it simple and just
{{- if gt (int .Values.replicaCount) 1 }}