Package com.pardot.rhombus

Examples of com.pardot.rhombus.ConnectionManager.teardown()


    assertEquals("clifunctional", keyspace.getName());
    assertEquals(3, keyspace.getDefinitions().get("clitest").getFields().size());
    assertEquals(3, keyspace.getDefinitions().get("clitest").getIndexes().size());
    assertEquals(2, keyspace.getDefinitions().get("clitest2").getIndexes().size());

    cm.teardown();
  }

  @Test
  public void testSetCompactionCLI() throws Exception {
View Full Code Here


    //now verify that the keyspace was migrated and is working
    //cm = getConnectionManager();
    //ResultSet result = cm.getEmptySession().execute("describe keyspace clifunctional;");
    //result.one();

    cm.teardown();
  }


}
View Full Code Here

    criteria.setOrdering("DESC");
    criteria.setLimit(50l);
    dbObjects = om.list(objectType, criteria);
    assertEquals(0, dbObjects.size());

    cm.teardown();
  }

  private List<Map<String, Object>> getNValues(int number, String index1Value, String index2Value) {
    List<Map<String, Object>> values = new ArrayList<Map<String, Object>>();
    for(int i = 0 ; i < number ; i++) {
View Full Code Here

    criteria.setLimit(50l);

    List<Map<String, Object>> dbObjects = om.list("object_audit", criteria);
    assertEquals(1, dbObjects.size());

    cm.teardown();
  }

  @Test
  public void testSendingNullIndexValue() throws Exception {
    logger.debug("Starting testSendingNullIndexValues");
View Full Code Here

    //Get back the data and make sure things match
    Map<String, Object> result = om.getByKey("object_audit", id);
    assertNotNull(result);
    assertEquals(null, result.get("user_id"));

    cm.teardown();
  }

  @Test
  public void testUpdatingNullNonIndexValue() throws Exception {
    logger.debug("Starting testSendingNullIndexValues");
View Full Code Here

    //Get back the data and make sure things match
    Map<String, Object> result = om.getByKey("object_audit", id);
    assertNotNull(result);
    assertEquals(null, result.get("changes"));

    cm.teardown();
  }

  @Test
  public void testUpdatingNonExistingObject() throws Exception {
    logger.debug("Starting testUpdatingNonExistingObject");
View Full Code Here

    //Get back the data and make sure things match
    Map<String, Object> result = om.getByKey("object_audit", id);
    assertNotNull(result);
    assertEquals("Account", result.get("object_type"));

    cm.teardown();
  }
}
View Full Code Here

      Long createdAt = (Long)(object.get("created_at"));
      logger.debug("Inserting audit with created_at: {}", createdAt);
      om.insert("object_audit", JsonUtil.rhombusMapFromJsonMap(object,definition.getDefinitions().get("object_audit")), createdAt);
    }

    cm.teardown();
  }

  @Test
  public void testInsertSync() throws Exception {
    logger.debug("Starting testInsertSync");
View Full Code Here

      Long createdAt = (Long)(object.get("created_at"));
      logger.debug("Inserting audit with created_at: {}", createdAt);
      om.insert("object_audit", JsonUtil.rhombusMapFromJsonMap(object,definition.getDefinitions().get("object_audit")), createdAt);
    }

    cm.teardown();
  }

}
View Full Code Here

    }

    logger.warn("Successfully inserted {} records where each required a new prepare", allInserts.size());

    //Teardown connections
    cm.teardown();
  }


}
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.