[ https://issues.apache.org/jira/browse/FLINK-39426 ]
Paras Negi deleted comment on FLINK-39426:
------------------------------------
was (Author: JIRAUSER312767):
*Proposal:* Restore {{StatefulSink}} and {{TwoPhaseCommittingSink}} directly in
{{flink-core}} as {{@Deprecated}} bridge interfaces extending the current mixin
types ({{{}Sink{}}} + {{{}SupportsWriterState{}}}, {{Sink +}}
{{{}SupportsCommitter{}}}), matching
[FLIP-372|https://cwiki.apache.org/confluence/display/FLINK/FLIP-372%3A+Enhance+and+synchronize+Sink+API+to+match+the+Source+API]'s
original backward-compatible design.
*Why it's the best solution:* This requires zero action from users — connectors
compiled against Flink 1.x resolve the class names automatically, and the
runtime's {{instanceof SupportsWriterState}} / {{instanceof SupportsCommitter}}
checks pass transparently. Unlike a separate module (which users must discover
and add), or doing nothing (which blocks upgrades until every connector
releases a 2.x build), this restores what
[FLIP-372|https://cwiki.apache.org/confluence/display/FLINK/FLIP-372%3A+Enhance+and+synchronize+Sink+API+to+match+the+Source+API]
already designed and what was arguably removed prematurely — only ~6 months
after deprecation, with the migration umbrella (FLINK-28045) still open.
*What's still needed:* These bridges should carry a clear removal target (e.g.,
Flink 2.2) documented in the migration guide, giving the connector ecosystem a
concrete deadline to complete the transition to the mixin pattern.
> Flink 2.0 and Connector version compatibility issue
> ---------------------------------------------------
>
> Key: FLINK-39426
> URL: https://issues.apache.org/jira/browse/FLINK-39426
> Project: Flink
> Issue Type: Bug
> Components: API / Core
> Affects Versions: 2.2.0
> Environment: dev
> Reporter: Xueyan Wang
> Assignee: Paras Negi
> Priority: Critical
> Labels: pull-request-available
>
> {code:java}
> <dependency>
> <groupId>org.apache.flink</groupId>
> <artifactId>flink-connector-jdbc</artifactId>
> <version>3.3.0-1.20</version>
> </dependency> {code}
> {code:java}
> Compilation failure
> cannot access org.apache.flink.api.connector.sink2.StatefulSink [ERROR]
> class file for org.apache.flink.api.connector.sink2.StatefulSink not found
> {code}
> Possible reason: Many existing connectors (e.g., Kafka Connector 3.x) still
> reference {{{}StatefulSink{}}}, which was present in Flink 1.x but is being
> phased out or changed in 2.x.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)