Abacn commented on PR #36028:
URL: https://github.com/apache/beam/pull/36028#issuecomment-3245739733

   > Repeatedly calling MemoizingPerInstantiationSerializableSupplier#get() 
comes with some overhead from volatile reads which can be avoided by fetching 
the shared caches once in setup and reusing those references through 
non-volatile fields.
   
   The change itself looks good, however it may not be relevant to the observed 
OOM was observed since Beam 2.64.0. I understand the caching was introduced in 
#34331, in Beam 2.65.0.
   
   In general I would expect overhead of volatile would still be small as each 
`processElement` call involves `consumer.poll` (API call, would be magnitude 
slower than in memory ops).


-- 
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