@Test
  public void getOnlyMaxEvents() throws Exception {
    hCatClient.createDatabase(HCatCreateDBDesc.create("hcatdb1").build());
    hCatClient.createDatabase(HCatCreateDBDesc.create("hcatdb2").build());
    hCatClient.createDatabase(HCatCreateDBDesc.create("hcatdb3").build());

    List<HCatNotificationEvent> events = hCatClient.getNextNotification(firstEventId, 2, null);
    assertEquals(2, events.size());
    assertEquals(firstEventId + 1, events.get(0).getEventId());
    assertEquals(firstEventId + 2, events.get(1).getEventId());
  }
This can't use TestHCatClient because it has to have control over certain conf variables when
the metastore is started.  Plus, we don't need a metastore running in another thread.  The
local one is fine.
itests/hcatalog-unit/src/test/java/org/apache/hive/hcatalog/api/TestHCatClientNotification.java