godfreyhe commented on a change in pull request #11671: [FLINK-17052] [client] 
Introduce PlanGenerator
URL: https://github.com/apache/flink/pull/11671#discussion_r408067969
 
 

 ##########
 File path: 
flink-libraries/flink-gelly/src/test/java/org/apache/flink/graph/generator/TestUtils.java
 ##########
 @@ -91,8 +91,6 @@ private TestUtils() {}
         * @param expectedParallelism expected operator parallelism
         */
        public static void verifyParallelism(ExecutionEnvironment env, int 
expectedParallelism) {
-               env.setParallelism(2 * expectedParallelism);
 
 Review comment:
   yes. before this pr, `CollectionEnvironment` overrides `getParallelism` 
method, and always return 1.  `ExecutionEnvironment#createProgramPlan` gets 
parallelism through `ExecutionEnvironment#getParallelism`. Now, `PlanGenerator` 
get parallelism through `config.getParallelism()`.  When 
`CollectionEnvironment` is created in 
`ExecutionEnvironment#createCollectionsEnvironment` method, the parallelism in 
config will be set as 1, while after `env.setParallelism(2 * 
expectedParallelism);` is called, the parallelism in config was changed to 4. 
which is unexpected.

----------------------------------------------------------------
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

Reply via email to