They should actually return different values in many cases.

Datastream.env.getDegreeOfParallelism returns the environment parallelism
(default)

Datastream.getparallelism() returns the parallelism of the operator. There
is a reason when one or the other is used.

Please watch out when you try to modify that because you might actually
break functionality there :p
On Feb 27, 2015 8:55 AM, "Szabó Péter" <nemderogator...@gmail.com> wrote:

> As I know, the time of creation of the execution environment has been
> slightly modified in the streaming API, which caused that
> dataStream.getParallelism() and dataStream.env.getDegreeOfParallelism() may
> return different values. Usage of the former is recommended.
> In theory, the latter is eliminated from the code, but there might be some
> more left, hiding. I've recently fixed one in WindowedDataStream. If you
> encounter problems with the parallelism, it may be the cause.
>
> Peter
>

Reply via email to