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
Increase the default max buckets #2901
Conversation
} | ||
|
||
async function updateMaxBucketsSetting(isModified: boolean) { | ||
console.log("ENTRA AQUI 3") |
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.
Please remove this console.log
return !isModified && await GenericRequest.request( | ||
'POST', | ||
'/api/kibana/settings', | ||
{ "changes": { "timelion:max_buckets": JSON.stringify(WAZUH_MAX_BUCKETS_DEFAULT) } } |
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 WAZUH_MAX_BUCKETS_DEFAULT
is a number, you don't need to do:
JSON.stringify(WAZUH_MAX_BUCKETS_DEFAULT)
Simply, you could do:
{ "changes": { "timelion:max_buckets": WAZUH_MAX_BUCKETS_DEFAULT } }
} | ||
|
||
const maxBuckets = settings["timelion:max_buckets"].userValue; | ||
const maxBucketsObject = JSON.parse(maxBuckets); |
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.
Why use JSON.parse
here? It should be a number.
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 tested it, and everything seems ok, but you forgot to add the config in initial-wazuh-congit.ts
, please add it and add the changelog.
Good Job!
Hi team! This PR solved the problem that was caused when entering Statistics and executing a query greater than 1 day.
Closes #2765