You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@yunikorn.apache.org by GitBox <gi...@apache.org> on 2022/03/10 06:09:12 UTC

[GitHub] [incubator-yunikorn-k8shim] pbacsko commented on pull request #382: [YUNIKORN-1108] Follow-up: Fix race conditions in dispatcher_test.go

pbacsko commented on pull request #382:
URL: https://github.com/apache/incubator-yunikorn-k8shim/pull/382#issuecomment-1063698532


   > In a number of tests we manipulate the dispatcher and use defer calls to fix up the exact changes made one at a time. This could be simplified to just replacing the whole dispatcher with a clean one via a defer call:
   > 
   > ```
   > initDispatcher()
   > defer initDispatcher()
   > ```
   > 
   > We do not need to track or reset things one by one as we know the dispatcher will be thrown away. Simplifies the code even further. Cleanup diff: +5, -15 lines if I count correctly.
   
   I ended up with only -15 :) pls check.


-- 
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: reviews-unsubscribe@yunikorn.apache.org

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