code: @Override
    public SessionHandle openSession(String username, String password,
        Map<String, String> configuration)
            throws HiveSQLException {
      try {
        TOpenSessionReq req = new TOpenSessionReq();
        req.setUsername(username);
        req.setPassword(password);
        req.setConfiguration(configuration);
        TOpenSessionResp resp = cliService.OpenSession(req);
        checkStatus(resp.getStatus());
        return new SessionHandle(resp.getSessionHandle(), resp.getServerProtocolVersion());
      } catch (HiveSQLException e) {
        throw e;
      } catch (Exception e) {
        throw new HiveSQLException(e);
      }
    }
docs: /* (non-Javadoc)
  @see org.apache.hive.service.cli.ICLIService#openSession(java.lang.String, java.lang.String, java.util.Map)