public void waitUntilEnd(long limit,TimeUnit limitUnit) throws TimeoutException {
  long expiry=limitUnit.toMillis(limit) + System.currentTimeMillis();
  waitUntilEnd(expiry);
}

public void waitUntilEnd ( long limit , TimeUnit limitUnit ) throws TimeoutException { long expiry = limitUnit . toMillis ( limit ) + System . currentTimeMillis ( ) ; waitUntilEnd ( expiry ) ; }
wait until docker closes the stream of output .
