Jzjsnow opened a new pull request, #3409:
URL: https://github.com/apache/amoro/pull/3409
<!--
Thanks for sending a pull request!
Here are some tips for you:
1. If this is your first time, please read our contributor guidelines:
https://amoro.apache.org/how-to-contribute/
2. If the PR is related to an issue in
https://github.com/apache/amoro/issues, add '[AMORO-XXXX]' in your PR title,
e.g., '[AMORO-XXXX] Your PR title ...'.
3. If the PR is unfinished, add '[WIP]' in your PR title, e.g.,
'[WIP][AMORO-XXXX] Your PR title ...'.
-->
## Why are the changes needed?
Currently, when we use flink optimizer groups, the memory parameters
`flink-conf.jobmanager.memory.process.size` and
`flink-conf.taskmanager.memory.process.size` only support plain numeric strings
or strings with `m/g` suffix. If we configure them with mb/gb suffix, we'll get
wrong parsed results. And the default unit for plain numbers is mb. The default
unit for plain numeric strings is `mb`, which is inconsistent with the default
unit of byte in the flink native parameter and may cause inconvenience for
users familiar with flink when using this parameter.
Close #3329.
## Brief change log
<!--
Clearly describe the changes made in modules, classes, methods, etc.
-->
- Add a new class `MemorySize` to the `amoro-common` module for parsing
flink's memory parameters, consistent with flink's native parsing logic.
- Update the values in the column `properties` of ams metadata tables
`resource_group` and `resource` to automatically add the `MB` suffix to the
flink jm and tm memory parameters that have been set and saved as plain numeric
strings
## How was this patch tested?
- [ ] Add some test cases that check the changes thoroughly including
negative and positive cases if possible
- [ ] Add screenshots for manual tests if appropriate
- [ ] Run test locally before making a pull request
## Documentation
- Does this pull request introduce a new feature? (yes / no)
- If yes, how is the feature documented? (not applicable / docs / JavaDocs /
not documented)
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]