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

Matthias Pohl commented on FLINK-30774:
---------------------------------------

I guess that could be done on a use-case basis. Like we have utils packages in 
other classes we could have a dedicated utils package for certain classes 
within flink-core as well. If they are not necessarily used in other packages. 
I came across this issue when reviewing FLINK-27518. There I noticed that we 
cannot use Preconditions in the newly added module {{flink-migration-tests}} 
rightaway.

{{flink-utils}} should be a module that does have plain Java code utility 
methods/classes that are useful in multiple modules. I would let the 
usercode-classloader related code, for instance, leave in {{flink-core}} as 
this is something that closer to the actual Flink functionality. 

[~chesnay] do you see problems adding such a module?

> flink-utils module
> ------------------
>
>                 Key: FLINK-30774
>                 URL: https://issues.apache.org/jira/browse/FLINK-30774
>             Project: Flink
>          Issue Type: Improvement
>          Components: Build System
>    Affects Versions: 1.17.0
>            Reporter: Matthias Pohl
>            Priority: Major
>              Labels: starter
>
> Currently, utility methods generic utility classes like {{Preconditions}} or 
> {{AbstractAutoCloseableRegistry}} are collected in {{flink-core}}. The flaw 
> of this approach is that we cannot use those classes in modules like 
> {{fink-migration-test-utils}}, {{flink-test-utils-junit}}, 
> {{flink-metrics-core}} or {{flink-annotations}}.
> We might want to have a generic {{flink-utils}} analogously to 
> {{flink-test-utils}} that collects Flink-independent utility functionality 
> that can be access by any module {{flink-core}} is depending on to make this 
> utility functionality available in any Flink-related module.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to