question: public void waitToFinish ( ) { flush ( ) ; if ( future != null ) { try { future . get ( ) ; } catch ( InterruptedException | ExecutionException e ) { LOG . error ( e . getMessage ( ) ) ; } } LOG . info ( "All tasks done!" ) ; }
target:  Block the main thread until all of the transactions have finished loading