public static MetaException newMetaException(Exception e) {
    if (e instanceof MetaException) {
      return (MetaException) e;
    }
    MetaException me = new MetaException(e.toString());
    me.initCause(e);
    return me;
  }
Converts the input exception to MetaException and returns.
standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/ExceptionHandler.java