code: public String reserveRepositoryName(String repositoryName) throws RepositoryCreationException
     {
        if (rpcService != null)
        {
           // reserve RepositoryName at coordinator-node
           try
           {
              Object result = rpcService.executeCommandOnCoordinator(reserveRepositoryName, true, repositoryName);
  
              if (result instanceof String)
              {
                 return (String)result;
              }
              else if (result instanceof Throwable)
              {
                 throw new RepositoryCreationException("Can't reserve repository " + repositoryName, (Throwable)result);
              }
              else
              {
                 throw new RepositoryCreationException("ReserveRepositoryName command returns unknown type result.");
              }
           }
           catch (RPCException e)
           {
              Throwable cause = (e).getCause();
              if (cause instanceof RepositoryCreationException)
              {
                 throw (RepositoryCreationException)cause;
              }
              else
              {
                 throw new RepositoryCreationException("Can not reserve repository name " + repositoryName + " since: "
                    + e.getMessage(), e);
              }
           }
        }
        else
        {
           return reserveRepositoryNameLocally(repositoryName);
        }
     }
docs: {@inheritDoc}