public Database buildNoModification(Configuration conf) throws MetaException {
    if (name == null) {
      throw new MetaException("You must name the database");
    }
    if (catalogName == null) {
      catalogName = MetaStoreUtils.getDefaultCatalog(conf);
    }
    Database db = new Database(name, description, location, params);
    db.setCatalogName(catalogName);
    db.setCreateTime(createTime);
    if (managedLocation != null)
      db.setManagedLocationUri(managedLocation);
    return db;
  }
A builder for {@link Database}.  The name of the new database is required.  Everything else
selects reasonable defaults.
standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/client/builder/DatabaseBuilder.java