You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2022/04/20 21:02:13 UTC

[GitHub] [pulsar-client-go] samuelhewitt opened a new issue, #763: [Bug] Producer blocks on Send when Schema fails to Encode

samuelhewitt opened a new issue, #763:
URL: https://github.com/apache/pulsar-client-go/issues/763

   #### Expected behavior
   When calling producer.Send() and producer.SendAsync(), the relevant error should be returned when the ProducerMessage.Value cannot be encoded by the schema. The publish Semaphore should also be released.
   
   #### Actual behavior
   Send never returns and SendAsync never executes the callback. Additionally, the publish Semaphore is never released.
   
   #### Steps to reproduce
   Execute code similar to the following, observe that Send never returns.
   ```
   	// create producer
   	producer, err := client.CreateProducer(ProducerOptions{
   		Topic:  topic,
   		Schema: NewAvroSchema("{\"type\":\"string\"}", nil),
   	})
   	defer producer.Close()
   
   	// producer should send return an error as message is Int64, but schema is String
   	mid, err := producer.Send(ctx, &ProducerMessage{
   		Value: int64(1),
   	})
   ```
   
   #### System configuration
   **Pulsar client version**: v0.8.0
   **Pulsar version**: 2.10.0
   


-- 
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: commits-unsubscribe@pulsar.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [pulsar-client-go] merlimat closed issue #763: [Bug] Producer blocks on Send when Schema fails to Encode

Posted by GitBox <gi...@apache.org>.
merlimat closed issue #763: [Bug] Producer blocks on Send when Schema fails to Encode
URL: https://github.com/apache/pulsar-client-go/issues/763


-- 
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: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org