Java Code Examples for org.apache.hadoop.hive.metastore.HiveMetaStore#startMetaStore()

The following examples show how to use org.apache.hadoop.hive.metastore.HiveMetaStore#startMetaStore() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: HiveLocalMetaStore.java    From hadoop-mini-clusters with Apache License 2.0 5 votes vote down vote up
@Override
public void run() {
    try {
        HiveMetaStore.startMetaStore(hiveMetastorePort, 
                new HadoopThriftAuthBridge(), 
                hiveConf);
    } catch (Throwable t) {
        t.printStackTrace();
    }
}
 
Example 2
Source File: InternalMetastoreServer.java    From incubator-sentry with Apache License 2.0 5 votes vote down vote up
private void startMetastore() throws Exception {
  Callable<Void> metastoreService = new Callable<Void>() {
    public Void call() throws Exception {
      try {
        HiveMetaStore.startMetaStore(getMetastorePort(conf),
            ShimLoader.getHadoopThriftAuthBridge(), conf);
      } catch (Throwable e) {
        throw new Exception("Error starting metastore", e);
      }
      return null;
    }
  };
  metaStoreExecutor.submit(metastoreService);
}