Skip to content

Commit ccfdf45

Browse files
committed
updated messaging to explain what threadID is doing.
1 parent 6ba7534 commit ccfdf45

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

src/main/java/software/amazon/awssdk/crt/mqtt5/PublishReturn.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,9 @@ private synchronized void invalidateAfterCallback() {
109109
* This is only called in JNI to make a new PublishReturn with a PUBLISH packet.
110110
* The controlId is eagerly acquired by native code prior to
111111
* {@link Mqtt5ClientOptions.PublishEvents#onMessageReceived} being called.
112+
* The threadID is set to the calling thread and is used when
113+
* {@link #acquirePublishAcknowledgementControl()} is called to guarantee the result
114+
* is accurate and enforces the requirement of calling it from within the callback.
112115
*
113116
* @param newPublishPacket The PublishPacket data received from the server.
114117
* @param controlId The pre-acquired publish acknowledgement control ID (0 for QoS 0 messages).

0 commit comments

Comments
 (0)