belugabehr commented on PR #3194:
URL: https://github.com/apache/avro/pull/3194#issuecomment-2570022151

   @KalleOlaviNiemitalo @martin-g
   
   Thank you for the correspondence.
   
   I'm taking another look at this. It seems less than ideal that there is 
synchronized code paths for fast-reading Avro data. I am not sure why this 
Collection was ever updated to be synchronized as this code is inherently not 
thread-safe. The [GenericDatumReader 
](https://github.com/apache/avro/blob/2943ea7f7be3628f6c97c8d297aa3841a9847e60/lang/java/avro/src/main/java/org/apache/avro/generic/GenericDatumReader.java#L144)
 `read()` method accepts a `Decoder`. Decoders are certainly _not_ thread safe 
as they typically have unsynchronized source reads and internal buffer 
manipulation.
   
   If we can relax this requirement then performance is measurably better as a 
read path will have no synchronization overhead.


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to