code: public Integer awaitStatusCode(long timeout, TimeUnit timeUnit) {
          try {
              if (!awaitCompletion(timeout, timeUnit)) {
                  throw new DockerClientException("Awaiting status code timeout.");
              }
          } catch (InterruptedException e) {
              throw new DockerClientException("Awaiting status code interrupted: ", e);
          }
  
          return getStatusCode();
      }
docs: Awaits the status code from the container.
  
  @throws DockerClientException
  if the wait operation fails.