public Response descDatabase(String user, String db, boolean extended)
    throws HcatException, NotAuthorizedException, BusyException,
    ExecuteException, IOException {
    String exec = "desc database " + db + "; ";
    if (extended)
      exec = "desc database extended " + db + "; ";

    try {
      String res = jsonRun(user, exec);
      return JsonBuilder.create(res).build();
    } catch (HcatException e) {
      throw new HcatException("unable to describe database: " + db,
        e.execBean, exec);
    }
  }
Return a json description of the database.
hcatalog/webhcat/svr/src/main/java/org/apache/hive/hcatalog/templeton/HcatDelegator.java