Skip to content

Commit 2f57a3d

Browse files
iahsfacebook-github-bot
authored andcommitted
Fix deadlock when using serial interactions with streaming
Summary: We have to dequeue the next request when we transfer the interaction refcount ownership to the stream even though we aren't decrementing said refcount Differential Revision: D28548647 fbshipit-source-id: f879e951ad5ccd43da3387c1e9c64ec6fba886de
1 parent 6d7bf66 commit 2f57a3d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

yarpl/flowable/ThriftStreamShim.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,8 @@ class ThriftStreamShim {
161161
~StreamServerCallbackAdaptor() {
162162
if (interaction_) {
163163
std::move(eb_).add([interaction = interaction_](auto eb) {
164-
interaction->__fbthrift_releaseRef(*eb);
164+
interaction->__fbthrift_releaseRef(
165+
*eb, apache::thrift::InteractionReleaseEvent::STREAM_END);
165166
});
166167
}
167168
}

0 commit comments

Comments
 (0)