nats-operator icon indicating copy to clipboard operation
nats-operator copied to clipboard

ClusterConfig: writeDeadline does not work because only write_deadline is recognized

Open Jank1310 opened this issue 3 years ago • 2 comments

It seems that in the PR #137 the writeDeadline option was not converted to camel case. Maybe intentional? https://github.com/nats-io/nats-operator/blob/a2c3c7104f12160bb5ca1032057b1efdc283337b/pkg/apis/nats/v1alpha2/cluster.go#L165 it should be

WriteDeadline`    string `json:"writeDeadline,omitempty"`

The nats-operator crds have also still write_deadline defined:

https://github.com/nats-io/k8s/blob/b55687a97a5fd55485e1af302fbdbe43d2d3b968/helm/charts/nats-operator/crds/customresourcedefinition.yaml#L42

The problem is a) the inconsistency in naming and b) the wrong example config(s) e.g. https://github.com/nats-io/nats-operator/blob/a2c3c7104f12160bb5ca1032057b1efdc283337b/example/example-nats-custom-config.yaml#L15

Jank1310 avatar Jan 08 '21 13:01 Jank1310

Thanks for the report, we have to make it consistent to be in camel case as in others.

wallyqs avatar Jan 08 '21 17:01 wallyqs

We've just hit this issue as well. It'd be great if this could be fixed - or if the example config could be adjusted to show the value as snake case if fixing the actual issue is too low priority.

JackRhodes avatar Dec 16 '21 10:12 JackRhodes