Ahmed Hamdy created FLINK-35454:
-----------------------------------
Summary: Connector ArchTests fails due to dependency on
fink.util.Preconditions
Key: FLINK-35454
URL: https://issues.apache.org/jira/browse/FLINK-35454
Project: Flink
Issue Type: Bug
Components: Test Infrastructure
Affects Versions: 1.20.0
Reporter: Ahmed Hamdy
Fix For: 1.20.0
h2. Description
- Arch Unit Rules for connectors limits dependencies of any classes in
connectors on @Public or @PublicEvolving with exceptions of connector package
classes, this is not true since we should be able to depend on internal util
classes like {{Preconditions}} and {{ExceptionsUtils}}
{code:java}
freeze(
javaClassesThat(resideInAnyPackage(CONNECTOR_PACKAGES))
.and()
.areNotAnnotatedWith(Deprecated.class)
.should()
.onlyDependOnClassesThat(
areFlinkClassesThatResideOutsideOfConnectorPackagesAndArePublic()
.or(
JavaClass.Predicates.resideOutsideOfPackages(
"org.apache.flink.."))
.or(
JavaClass.Predicates.resideInAnyPackage(
CONNECTOR_PACKAGES)) )
.as(
"Connector production code must depend only
on public API when outside of connector packages"));
{code}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)