You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by GitBox <gi...@apache.org> on 2019/11/08 13:19:35 UTC
[GitHub] [flink] faaronzheng commented on a change in pull request #10090: [FLINK-14560] [runtime] The value of taskmanager.memory.size in flink…
faaronzheng commented on a change in pull request #10090: [FLINK-14560] [runtime] The value of taskmanager.memory.size in flink…
URL: https://github.com/apache/flink/pull/10090#discussion_r344169155
##########
File path: flink-runtime/src/main/java/org/apache/flink/runtime/util/ConfigurationParserUtils.java
##########
@@ -42,26 +43,9 @@
* @return managed memory size (in megabytes)
*/
public static long getManagedMemorySize(Configuration configuration) {
- long managedMemorySize;
- String managedMemorySizeDefaultVal = TaskManagerOptions.MANAGED_MEMORY_SIZE.defaultValue();
- if (!configuration.getString(TaskManagerOptions.MANAGED_MEMORY_SIZE).equals(managedMemorySizeDefaultVal)) {
- try {
- managedMemorySize = MemorySize.parse(
- configuration.getString(TaskManagerOptions.MANAGED_MEMORY_SIZE), MEGA_BYTES).getMebiBytes();
- } catch (IllegalArgumentException e) {
- throw new IllegalConfigurationException("Could not read " + TaskManagerOptions.MANAGED_MEMORY_SIZE.key(), e);
- }
- } else {
- managedMemorySize = Long.valueOf(managedMemorySizeDefaultVal);
- }
-
- checkConfigParameter(configuration.getString(
Review comment:
If this check is necessary, TaskExecutorResourceUtils.getManagedMemorySize() should also check it.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services