Skip to content

Commit

Permalink
Ensure only primary stores the case sensitivity state (#7820)
Browse files Browse the repository at this point in the history
* Ensure only primary stores the case sensitivity state

* Update the check
  • Loading branch information
vishalnayak committed Nov 8, 2019
1 parent 583be49 commit c27a1c1
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions vault/identity_store.go
Expand Up @@ -112,6 +112,11 @@ func (i *IdentityStore) paths() []*framework.Path {
}

func (i *IdentityStore) initialize(ctx context.Context, req *logical.InitializationRequest) error {
// Only primary should write the status
if i.System().ReplicationState().HasState(consts.ReplicationPerformanceSecondary | consts.ReplicationPerformanceStandby | consts.ReplicationDRSecondary) {
return nil
}

entry, err := logical.StorageEntryJSON(caseSensitivityKey, &casesensitivity{
DisableLowerCasedNames: i.disableLowerCasedNames,
})
Expand Down

0 comments on commit c27a1c1

Please sign in to comment.