server: add OSS stubs supporting validation of source namespaces in service-intentions config entries (#9527)
This commit is contained in:
parent
9f4c52612c
commit
e3f5a77ade
|
@ -0,0 +1,3 @@
|
|||
```release-note:improvement
|
||||
server: **(Enterprise Only)** Validate source namespaces in service-intentions config entries.
|
||||
```
|
|
@ -567,6 +567,10 @@ func (e *ServiceIntentionsConfigEntry) validate(legacyWrite bool) error {
|
|||
return fmt.Errorf("Sources[%d].%v", i, err)
|
||||
}
|
||||
|
||||
if err := validateSourceIntentionEnterpriseMeta(&src.EnterpriseMeta); err != nil {
|
||||
return fmt.Errorf("Sources[%d].%v", i, err)
|
||||
}
|
||||
|
||||
// Length of opaque values
|
||||
if len(src.Description) > metaValueMaxLength {
|
||||
return fmt.Errorf(
|
||||
|
|
|
@ -0,0 +1,7 @@
|
|||
// +build !consulent
|
||||
|
||||
package structs
|
||||
|
||||
func validateSourceIntentionEnterpriseMeta(_ *EnterpriseMeta) error {
|
||||
return nil
|
||||
}
|
Loading…
Reference in New Issue