As mentioned in HBASE-15291, there is a race condition. If Two secure bulkload calls from the same UGI into two different regions and one region finishes earlier, it will close the bulk load fs, and the other region will fail.
Another case would be more serious. The FileSystem.close() function needs two synchronized variables : CACHE and deleteOnExit. If one region calls FileSystem.closeAllForUGI ( in SecureBulkLoadManager.cleanupBulkLoad) while another region is trying to close srcFS ( in SecureBulkLoadListener.closeSrcFs) , can cause deadlock here.
I have wrote a UT for this and fixed it using reference counter.