t0il3ts0ap opened a new pull request #4741: URL: https://github.com/apache/hudi/pull/4741
…rics ## *Tips* - *Thank you very much for contributing to Apache Hudi.* - *Please review https://hudi.apache.org/contribute/how-to-contribute before opening a pull request.* ## What is the purpose of the pull request As of now all metrics created by hudi has table name prefixed by default. This pr aims to put that behavior behind a configuration and allows the user to disable it. For example lets say we have 2 hudi tabls customers and loan_accounts. Right now the metrics in prometheus will come like this ``` customers_TimelineService_TOTAL_HANDLE_TIME{instance="",job="customers"} 589 loan_accounts_TimelineService_TOTAL_HANDLE_TIME{instance="",job="loan_accounts"} 642 ``` Its conventional in prometheus to have consistent metric name with differences in labels. After the changes in this pr, metrics will come like this which is much simpler to plot across lets say 100s of hudi tables with each having 100s of metrics. ``` TimelineService_TOTAL_HANDLE_TIME{job="customers"} 589 TimelineService_TOTAL_HANDLE_TIME{job="loan_accounts"} 642 ``` ## Brief change log Added configuration `hoodie.metrics.common_prefix.enable` This configuration is true by default and which doesnt change any behavior for existing users. ## Verify this pull request *(Please pick either of the following options)* This pull request is a trivial rework / code cleanup without any test coverage. *(or)* This pull request is already covered by existing tests, such as *(please describe tests)*. (or) This change added tests and can be verified as follows: *(example:)* - *Added integration tests for end-to-end.* - *Added HoodieClientWriteTest to verify the change.* - *Manually verified the change by running a job locally.* ## Committer checklist - [ ] Has a corresponding JIRA in PR title & commit - [ ] Commit message is descriptive of the change - [ ] CI is green - [ ] Necessary doc changes done or have another open PR - [ ] For large changes, please consider breaking it into sub-tasks under an umbrella JIRA. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@hudi.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org