hi, patricia

I suggest using the generic asynchronous base sink.

https://flink.apache.org/2022/03/16/the-generic-asynchronous-base-sink/


Best,
Feng

On Fri, Sep 1, 2023 at 6:07 PM patricia lee <plee3...@gmail.com> wrote:

>
> I'd like to ask if there is a way to send data to a vendor (SDK plugin,
> which is also an HTTP request) asynchronously in flink 1.17?
>
> After transformation on the data, I usually collate them as a List to my
> custom SinkFunction. I initialized a CompleteableFuture inside the invoke()
> method. However I read about the Async I/O from the documentation but I
> couldn't figure out how to use it in my use case.
>
>
> How can I close the resources initialized in SinkFunction properly? e.g.
> the job failed.
> Is using completableFuture inside SinkFunction a good approach?
>
>
> Regards,
> Pat
>
>

Reply via email to