-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
[Oracle Module] New sysmetric metricset #31462
[Oracle Module] New sysmetric metricset #31462
Conversation
You'll need to add a CHANGELOG entry for this. I'm not very familiar with this code. The commit history (https://github.com/elastic/beats/commits/main/x-pack/metricbeat/module/oracle) suggests @sayden would be a good reviewer here. |
…lastic/beats into oracle_sysmetric_metricset
This pull request is now in conflicts. Could you fix it? 🙏
|
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.
There are few nits from my side and there are few methods that can be explained a bit using comments. So others can easily understood the workflow.
Else LGTM!
Second part of the requirement is as below. Another problem with the queries used by the metricbeat module is that they don’t account for the rack installations. If there is a rack-installation, metricbeat is not going to provide correct results, because nobody knows whether the data reported is from the current node that you connected to or is an average across all nodes in the rack. How this requirement is met? |
We have covered all the points mentioned as a part of solution in the PRD. If we refer to the Do you have any ideas over it? |
This pull request is now in conflicts. Could you fix it? 🙏
|
You may check V$INSTANCE database view |
Hey @agithomas, we have made all the changes as per your suggestions and discussion over the sync. We are looking into the parameter CON_ID by doing some hands-on with the Oracle Database. We will get back to you with our analysis over the same soon and we can agree upon something after discussing with the team. Please feel free to review the rest of the PR and let us know if you have any other suggestions/feedback. Update (06/08/2022): @agithomas, this PR is ready for review. All the existing review comments have been addressed. Please take a second round of review for the PR at your convenience. |
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.
LGTM
Blocked because of the requested change. This however is addressed : Explnataion : As a part of this enhancement, we had to map the fields dynamically as mentioned in the PRD. Your point makes sense, we can add a function to transform the field names dynamically to snake case to follow the Elastic naming conventions. But because of the dynamic mapping, it does not seem feasible to group the fields.
* Add sysmetric metricset to Oracle Metricbeat Module * Format code and try to resolve lint errors * Resolve lint issue * Run make check * Update dashboard and visualizations * Run make update * Update dashboards and visualizations * Update unit tests for sysmetric_metric * Resolve review comments and update documentation * Sanitize e.patterns to avoid SQL injection * Update unit test and resolve linting failures * Update integration tests for sysmetric metricset * Run make update * Update date parsing * Update test case to handle new timestamp format * Updating dynamically naming the fields to follow Elastic naming conventions * Update unit test case to handle the naming convention of the field * Update data.json with update in naming convention * Update implementation to have multiple metrics per document * Update test case based on the document update * Update data collection to collect long-duration queried metrics only * Update unit test case as per updated query * Update visualizations as per dynamically mapped field names * Update docs and resolve nitpicks * Update fields as per the visualizations * Resolve review comments * Update unit test case as per dropped key * Remove extra CHANGELOG.next.asciidoc entry * Resolve review comments
What does this PR do?
Create a new sysmetric metricset to complement the current performance one.
Why is it important?
What Oracle DBAs usually do is actually pull the pre-calculated metrics from the V$SYSMETRIC table (called System View). DBAs usually need around 10 out of these 200+ metrics and Oracle will keep adding more metrics to this table in the future, so, there has to be a way to dynamically filter in or query only those that are suggested by the user with the help of a keyword or Regex.
Checklist
CHANGELOG.next.asciidoc
orCHANGELOG-developer.next.asciidoc
.Related issues
Screenshot