You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@flink.apache.org by Marco Villalobos <mv...@kineteque.com> on 2020/08/11 17:13:28 UTC

Question about ParameterTool

What are the dangers of not using the ParameterTool for parsing command
line parameters?

I have been using Picocli (https://picocli.info/). Will this be a mistake?
Are there any side-effects that I should be aware of?

Re: Question about ParameterTool

Posted by Arvid Heise <ar...@ververica.com>.
Since Picocli does not have any dependencies on its own, it's safe to use.
It's a bit quirky to use with Scala, but it's imho the best CLI library for
java.

The only downside as Chesnay mentioned is the increased jar size. Also note
that Flink is not graal-ready.

Best,

Arvid


On Wed, Aug 12, 2020 at 12:27 AM Chesnay Schepler <ch...@apache.org>
wrote:

> The benefit of the ParameterTool is that you do not increase your
> dependency footprint by using it.
>
> When using another CLI library you will generally package it within your
> user-jar, which may or may not increase the risk of dependency conflicts.
> Whether, and how large this risk is, depends naturally on the library.
> This also results in a larger jar file, which may or may not be relevant
> for you.
>
> On 11/08/2020 23:35, Marco Villalobos wrote:
>
> Thank you for the clarification.
>
> But does it offer any additional benefits that are not clearly documented?
>
>
>
> On Tue, Aug 11, 2020 at 12:22 PM Robert Metzger <rm...@apache.org>
> wrote:
>
>> Hi,
>> there are absolutely no dangers not using ParameterTool.
>> It is used by the Flink examples, and as a showcase for global job
>> parameters:
>> https://ci.apache.org/projects/flink/flink-docs-release-1.2/monitoring/best_practices.html#register-the-parameters-globally
>>
>> On Tue, Aug 11, 2020 at 7:13 PM Marco Villalobos <
>> mvillalobos@kineteque.com> wrote:
>>
>>> What are the dangers of not using the ParameterTool for parsing command
>>> line parameters?
>>>
>>> I have been using Picocli (https://picocli.info/). Will this be a
>>> mistake? Are there any side-effects that I should be aware of?
>>>
>>
>

-- 

Arvid Heise | Senior Java Developer

<https://www.ververica.com/>

Follow us @VervericaData

--

Join Flink Forward <https://flink-forward.org/> - The Apache Flink
Conference

Stream Processing | Event Driven | Real Time

--

Ververica GmbH | Invalidenstrasse 115, 10115 Berlin, Germany

--
Ververica GmbH
Registered at Amtsgericht Charlottenburg: HRB 158244 B
Managing Directors: Timothy Alexander Steinert, Yip Park Tung Jason, Ji
(Toni) Cheng

Re: Question about ParameterTool

Posted by Chesnay Schepler <ch...@apache.org>.
The benefit of the ParameterTool is that you do not increase your 
dependency footprint by using it.

When using another CLI library you will generally package it within your 
user-jar, which may or may not increase the risk of dependency conflicts.
Whether, and how large this risk is, depends naturally on the library.
This also results in a larger jar file, which may or may not be relevant 
for you.

On 11/08/2020 23:35, Marco Villalobos wrote:
> Thank you for the clarification.
>
> But does it offer any additional benefits that are not clearly documented?
>
>
>
> On Tue, Aug 11, 2020 at 12:22 PM Robert Metzger <rmetzger@apache.org 
> <ma...@apache.org>> wrote:
>
>     Hi,
>     there are absolutely no dangers not using ParameterTool.
>     It is used by the Flink examples, and as a showcase for global job
>     parameters:
>     https://ci.apache.org/projects/flink/flink-docs-release-1.2/monitoring/best_practices.html#register-the-parameters-globally
>
>     On Tue, Aug 11, 2020 at 7:13 PM Marco Villalobos
>     <mvillalobos@kineteque.com <ma...@kineteque.com>> wrote:
>
>         What are the dangers of not using the ParameterTool for
>         parsing command line parameters?
>
>         I have been using Picocli (https://picocli.info/). Will this
>         be a mistake? Are there any side-effects that I should be
>         aware of?
>


Re: Question about ParameterTool

Posted by Marco Villalobos <mv...@kineteque.com>.
Thank you for the clarification.

But does it offer any additional benefits that are not clearly documented?



On Tue, Aug 11, 2020 at 12:22 PM Robert Metzger <rm...@apache.org> wrote:

> Hi,
> there are absolutely no dangers not using ParameterTool.
> It is used by the Flink examples, and as a showcase for global job
> parameters:
> https://ci.apache.org/projects/flink/flink-docs-release-1.2/monitoring/best_practices.html#register-the-parameters-globally
>
> On Tue, Aug 11, 2020 at 7:13 PM Marco Villalobos <
> mvillalobos@kineteque.com> wrote:
>
>> What are the dangers of not using the ParameterTool for parsing command
>> line parameters?
>>
>> I have been using Picocli (https://picocli.info/). Will this be a
>> mistake? Are there any side-effects that I should be aware of?
>>
>

Re: Question about ParameterTool

Posted by Robert Metzger <rm...@apache.org>.
Hi,
there are absolutely no dangers not using ParameterTool.
It is used by the Flink examples, and as a showcase for global job
parameters:
https://ci.apache.org/projects/flink/flink-docs-release-1.2/monitoring/best_practices.html#register-the-parameters-globally

On Tue, Aug 11, 2020 at 7:13 PM Marco Villalobos <mv...@kineteque.com>
wrote:

> What are the dangers of not using the ParameterTool for parsing command
> line parameters?
>
> I have been using Picocli (https://picocli.info/). Will this be a
> mistake? Are there any side-effects that I should be aware of?
>