zbentley commented on code in PR #87:
URL:
https://github.com/apache/pulsar-client-python/pull/87#discussion_r1093518373
##########
src/producer.cc:
##########
@@ -34,6 +34,16 @@ MessageId Producer_send(Producer& producer, const Message&
message) {
return messageId;
}
+void Producer_sendAsync(Producer& producer, const Message& msg, SendCallback
callback) {
+ Py_BEGIN_ALLOW_THREADS
+ producer.sendAsync(msg, callback);
+ Py_END_ALLOW_THREADS
+
+ if (PyErr_CheckSignals() == -1) {
Review Comment:
Sure. Something I've seen before is issues around an error already being
"pre-raise" in a Python thread when some external code (the pulsar client C++
in this case) decides to invoke an unrelated Python callback. Does pybind
handle situations like [this
one](https://github.com/apache/pulsar/pull/16535/files#diff-b9b1b59dde469b15de56c46d20ae54d82e01a7a607ef4bf6f2d759807e5bfd79R119)?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]