xintongsong commented on a change in pull request #9910: [FLINK-14405][runtime]
Align ResourceProfile/ResourceSpec fields with the new TaskExecutor memory
setups.
URL: https://github.com/apache/flink/pull/9910#discussion_r335798903
##########
File path:
flink-core/src/main/java/org/apache/flink/api/common/operators/ResourceSpec.java
##########
@@ -310,50 +327,73 @@ private Object readResolve() {
// builder
//
------------------------------------------------------------------------
- public static Builder newBuilder() {
- return new Builder();
+ public static Builder newBuilder(double cpuCores, MemorySize
taskHeapMemory) {
+ return new Builder(cpuCores, taskHeapMemory);
+ }
+
+ public static Builder newBuilder(double cpuCores, int taskHeapMemoryMB)
{
Review comment:
I don't quite understand which are the "unrelated changes" that you are
talking about? Do you mean the `Builder` class, or the `Builder#newBuilder`
factory method, or the setters with 'MB' suffix?
If you mean the `Builder` class, I don't understand how changes to it is
unrelated to the changes of `ResourceSpec` that the builder builds.
If you mean the `Builder#newBuilder` factory method, the purpose of them is
to make sure `ResourceSpec` is always constructed with explicit cpu cores and
task heap memory, which is required by FLIP-49.
If you mean the setters with 'MB' suffix, I think it also makes sense that
we remove them and keep those with `MemorySize` arguments only.
----------------------------------------------------------------
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:
[email protected]
With regards,
Apache Git Services