delta-io/connectors

java.lang.IllegalAccessError for Flink Delta Sink when trying to deploy on a Flink cluster

pkubit-g opened this issue · 0 comments

A Flink job with a Flink Delta Sink gives above error when trying to deploy it to a Flink cluster.

Caused by: java.lang.IllegalAccessError: tried to access method org.apache.flink.streaming.api.functions.sink.filesystem.OutputStreamBasedPartFileWriter.<init>(Ljava/lang/Object;Lorg/apache/flink/core/fs/RecoverableFsDataOutputStream;J)V from class org.apache.flink.streaming.api.functions.sink.filesystem.DeltaBulkPartWriter

The solution is to shade the org.apache.flink.streaming.api.functions.sink.filesystem package inside the job's fat-jar, but it shouldn't be necessary by default.

Affected artifact: delta-flink
Affected version: 0.4.0

I've already prepared the PR with a fix for this issue.