bschofield edited a comment on issue #437: URL: https://github.com/apache/pulsar-client-go/issues/437#issuecomment-756824096
Profiling the goroutines in my test program, at the time the send is stalled, results in this.  Note that `partitionProducer.internalSendAsync()` is blocked on semaphore acquisition. Since I don't have the `DisableBlockIfQueueFull` option sent, I think this must be at line 586 of _producer_partition.go_: p.publishSemaphore.Acquire() In the creation of `partitionProducer` at line 108, `publishSemaphore` is initialized with a size from `maxPendingMessages`: publishSemaphore: internal.NewSemaphore(int32(maxPendingMessages)), I am unclear why this semaphore size is inadequate, but this seems like it might be the source of the issue. Is there a case where the semaphore can fill before the batch flush actually occurs, so that the corresponding release in `ReceivedSendReceipt()` never actually fires? ---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: [email protected]
