lakshmi-manasa-g opened a new pull request #1564:
URL: https://github.com/apache/samza/pull/1564


   **Symptom**: calling flush on the azure blob system producer does not 
terminate even after the flush timeout duration expires.
   
   **Cause**: main thread was uploading to azure but the connection was bad and 
main thread got stuck. so when the flush was called on the system producer 
there was no response from the main thread even after the flush timeout 
expired. The expected behavior is for the flush to end either in success or 
failure once the timeout expires.
   
   **Changes**: use reactor's .subsrcibeOn with Schedulers.boundedElastic to 
block on the mono returned by the azure sdk. this lets us impose a timeout on 
the mono.block  and also lets main thread monitor and jump out of the upload if 
upload takes longer than the flush timeout duration. After this change, 
irrespective of which thread (incl main) picks up the azure upload task, it 
will return from the upload after the flush timeout ms duration and will not 
hang indefinitely. 
   
   **Tests**: unit test added. also tested at production scale and compared to 
performance w/ and w/o the change and no major deviations in metrics. Note that 
for the sake of printing the thread name and accurate timestamp during the unit 
test, the log4j files were updated.
   
   API changes: none
   
   usage/upgrade instructions: none
   
   Backwards compatible: yes
   
   


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