Skip to content
This repository has been archived by the owner on Jun 1, 2023. It is now read-only.

Commit

Permalink
fix: set the default value of user's session_timeout_ms
Browse files Browse the repository at this point in the history
BREAKING CHANGE: change session_timeout_ms's computed to false
  • Loading branch information
suzuki-shunsuke committed Aug 19, 2020
1 parent f96c449 commit 7db1aa3
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion docs/resources/user.md
Expand Up @@ -21,7 +21,7 @@ password | string | sensitive
permissions | string set | computed
roles | [] | string set |
timezone | "" | string | computed
session_timeout_ms | | int | computed
session_timeout_ms | 3600000 | int |

## Attrs Reference

Expand Down
2 changes: 1 addition & 1 deletion graylog/graylog/user.go
Expand Up @@ -91,7 +91,7 @@ func (user *User) NewUpdateParams() *UserUpdateParams {
// SetDefaultValues sets default values.
func (user *User) SetDefaultValues() {
if user.SessionTimeoutMs == 0 {
user.SessionTimeoutMs = 28800000
user.SessionTimeoutMs = 3600000
}
if user.Timezone == "" {
user.Timezone = "UTC"
Expand Down
2 changes: 1 addition & 1 deletion graylog/terraform/resource_user.go
Expand Up @@ -63,7 +63,7 @@ func resourceUser() *schema.Resource {
"session_timeout_ms": {
Type: schema.TypeInt,
Optional: true,
Computed: true,
Default: 3600000, //nolint:gomnd
},

"user_id": {
Expand Down

0 comments on commit 7db1aa3

Please sign in to comment.