flink-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hung Chang (JIRA)" <j...@apache.org>
Subject [jira] [Comment Edited] (FLINK-1017) Add setParallelism() to Java API documentation
Date Mon, 11 Aug 2014 14:49:12 GMT

    [ https://issues.apache.org/jira/browse/FLINK-1017?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14092389#comment-14092389
] 

Hung Chang edited comment on FLINK-1017 at 8/11/14 2:47 PM:
------------------------------------------------------------

Thanks and cool! 
I tried the solutions mentioned above and get successfully 
(From Chesnay(Online Editing & Branch)) (From Robert(.sh command & Sublime))

Could I ask more understanding regarding setParallelism?

In wordCoundJob the usage is like following.

public getPlan(){		
int parallemlism = 2;
plan.setDefaultParallelism(parallelism);
}

public static void main(String[] args) throws Exception {
Plan toExecute = tut.getPlan(inputPath, outputPath, parallelism);
}

Does it work like multi-thread and one thread will work for one map function?
So, map function handles each (key, value) pair, and one thread will take care for one pair
In the above example the program handles 2 pair at the same time because 
parallemlism = 2 



was (Author: hungchang):
Thanks and cool! 
I tried the solutions mentioned above and get successfully 
(From Chesnay(Online Editing & Branch)) (From Robert(.sh command & Sublime))

Could I ask more understanding regarding setParallelism?

In wordCoundJob the usage is like following.

public getPlan(){		
int parallemlism = 2;
plan.setDefaultParallelism(parallelism);
}

public static void main(String[] args) throws Exception {
Plan toExecute = tut.getPlan(inputPath, outputPath, parallelism);
}

Does it work like multi-thread and one thread will work for one map function?
So, map function handles each (key, value) pair, and one thread will take care for one pair
In the above example the program handles 2 pair at the same time because 
parallemlism = 2 

Is there any mistake?

> Add setParallelism() to Java API documentation
> ----------------------------------------------
>
>                 Key: FLINK-1017
>                 URL: https://issues.apache.org/jira/browse/FLINK-1017
>             Project: Flink
>          Issue Type: Task
>          Components: Documentation
>    Affects Versions: 0.6-incubating, pre-apache-0.5
>            Reporter: Fabian Hueske
>            Assignee: Hung Chang
>            Priority: Minor
>              Labels: starter
>             Fix For: 0.6-incubating
>
>
> The Java API offers {{setParallelism()}} to control the degree of parallelism for each
operator. This feature is not documented and should be added.



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Mime
View raw message