From d0eadd924c53cdf9cf067c97563c4c92588cb228 Mon Sep 17 00:00:00 2001 From: desp99 Date: Tue, 24 Jul 2018 15:01:37 -0400 Subject: [PATCH] Minor fix on the comments in Publisher.java --- .../src/main/java/com/google/cloud/pubsub/v1/Publisher.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/google-cloud-clients/google-cloud-pubsub/src/main/java/com/google/cloud/pubsub/v1/Publisher.java b/google-cloud-clients/google-cloud-pubsub/src/main/java/com/google/cloud/pubsub/v1/Publisher.java index 55434aa17775..2b1fa858010a 100644 --- a/google-cloud-clients/google-cloud-pubsub/src/main/java/com/google/cloud/pubsub/v1/Publisher.java +++ b/google-cloud-clients/google-cloud-pubsub/src/main/java/com/google/cloud/pubsub/v1/Publisher.java @@ -203,7 +203,7 @@ public ApiFuture publish(PubsubMessage message) { final OutstandingPublish outstandingPublish = new OutstandingPublish(publishResult, message); messagesBatchLock.lock(); try { - // Check if the next message makes the batch exceed the current batch byte size. + // Check if the next message makes the current batch exceed the max batch byte size. if (!messagesBatch.isEmpty() && hasBatchingBytes() && batchedBytes + messageSize >= getMaxBatchBytes()) { @@ -212,8 +212,8 @@ && hasBatchingBytes() batchedBytes = 0; } - // Border case if the message to send is greater equals to the max batch size then can't be - // included in the current batch and instead sent immediately. + // Border case if the message to send is greater or equals to the max batch size then can't + // be included in the current batch and instead sent immediately. if (!hasBatchingBytes() || messageSize < getMaxBatchBytes()) { batchedBytes += messageSize; messagesBatch.add(outstandingPublish);