Open Eistern opened 5 months ago
PR published - https://github.com/ydb-platform/ydb-java-sdk/pull/281 (for some reason it didn’t link automatically)
This was made on purpose to keep sync interface simple and not to overload it with CompletableFutures. AsyncWriter does exactly what you want.
This was made on purpose to keep sync interface simple and not to overload it with CompletableFutures. AsyncWriter does exactly what you want.
There is a slight issue. We need the blocking behavior of the internal writer queue that is provided by the SyncWriter
(and implementing logic on top of the tech.ydb.topic.write.QueueOverflowException
is not a good idea in terms of performance). Currently, we've declared our own extension of the tech.ydb.topic.write.impl.WriterImpl
to do just that, but it is still a hassle to properly open it without the use of the tech.ydb.topic.TopicClient
We need the blocking behavior of the internal writer queue that is provided by the
SyncWriter
(and implementing logic on top of thetech.ydb.topic.write.QueueOverflowException
is not a good idea in terms of performance).
Ok, I got your concerns. We need some time to consider
We need the blocking behavior of the internal writer queue that is provided by the
SyncWriter
(and implementing logic on top of thetech.ydb.topic.write.QueueOverflowException
is not a good idea in terms of performance).Ok, I got your concerns. We need some time to consider
@pnv1, let's return to this topic
Problem
Currently, the
tech.ydb.topic.write.SyncWriter
interface does not provide any technical means for users to receive and analyze the results of theirsend(...)
operations. This lack of functionality can make it difficult for developers to ensure that their messages are being sent successfully and to troubleshoot any issues that may arise.Proposed solution
Propagate the results of
sendImpl(...).join()
to the user code