flant / addon-operator

A system to manage additional components for Kubernetes cluster in a simple, consistent and automated way.
https://flant.github.io/addon-operator/
Apache License 2.0
483 stars 27 forks source link

fix camelCase to kebab-case conversion #464

Closed miklezzzz closed 6 months ago

miklezzzz commented 6 months ago

Overview

The camelCase to kebab-case string conversion function is updated to use "github.com/ettle/strcase" package instead of local implementation. It should allow converting module names containing digits more correctly.

What this PR does / why we need it

It updates the way we convert camelCased strings to kebab-cased. At now, if we have something like 'l2-load-balancer' in kebab-case, after converting to camelCase and back it ends up with 'l-2-load-balancer'.

Special notes for your reviewer

miklezzzz commented 6 months ago

here is a diff output between values before and after the changes image

miklezzzz commented 6 months ago

I think I can't comprehend all possible consequences of these changes, need you to spend a couple of minutes thinking through a possible worst case scenario :) @nabokihms @yalosev