-
Notifications
You must be signed in to change notification settings - Fork 214
fixes #2505 adds central configuration with events #2792
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
andrewpmartinez
commented
Feb 12, 2025
- uses dynamic JSON protobuf struct marshalling to avoid having to declare every setting in protobuf
- uses dynamic JSON protobuf struct marshalling to avoid having to declare every setting in protobuf
| store.settingControllerListeners[setting][id] = append(store.settingControllerListeners[setting][id], listener) | ||
| } | ||
| } | ||
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not clear why you're deleting the listener if the controller specific settings are removed. Isn't the listener still going to want to react to changes to the global config?
| type controllerSettingStoreImpl struct { | ||
| *baseStore[*ControllerSetting] | ||
| indexName boltz.ReadIndex | ||
| symbolEnrollments boltz.EntitySetSymbol |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The map is likely being accessed/mutated across goroutines, should probably be protected
| func (ae *AppEnv) GetPeerSigners() []*x509.Certificate { | ||
| return ae.HostController.GetPeerSigners() | ||
| } | ||
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We already have GetId(). That's return the token id from the cert, AFAIK, so this should hopefully not be needed.
| if err != nil { | ||
| return nil, fmt.Errorf("could not marshal entity: %w", err) | ||
| } | ||
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm doing some json in protobuf as well for inspect stuff. I'll look at this and see if it makes sense to use there.
| "github.com/openziti/ziti/controller/models" | ||
| "go.etcd.io/bbolt" | ||
| ) | ||
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is TrustDomainSettings used?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall looks good, couple of smaller things