mirror of
https://github.com/kemko/nomad.git
synced 2026-01-07 19:05:42 +03:00
enterprise specific state store objects
This commit is contained in:
@@ -80,6 +80,12 @@ func NewStateStore(config *StateStoreConfig) (*StateStore, error) {
|
||||
config: config,
|
||||
abandonCh: make(chan struct{}),
|
||||
}
|
||||
|
||||
// Initialize the state store with required enterprise objects
|
||||
if err := s.enterpriseInit(); err != nil {
|
||||
return nil, fmt.Errorf("enterprise state store initialization failed: %v", err)
|
||||
}
|
||||
|
||||
return s, nil
|
||||
}
|
||||
|
||||
|
||||
@@ -7,6 +7,12 @@ import (
|
||||
"github.com/hashicorp/nomad/nomad/structs"
|
||||
)
|
||||
|
||||
// enterpriseInit is used to initialize the state store with enterprise
|
||||
// objects.
|
||||
func (s *StateStore) enterpriseInit() error {
|
||||
return nil
|
||||
}
|
||||
|
||||
// namespaceExists returns whether a namespace exists
|
||||
func (s *StateStore) namespaceExists(txn *memdb.Txn, namespace string) (bool, error) {
|
||||
return namespace == structs.DefaultNamespace, nil
|
||||
|
||||
Reference in New Issue
Block a user