Examples of ClusteredEntityWithEnumCompoundKey


Examples of info.archinnov.achilles.test.integration.entity.ClusteredEntityWithEnumCompoundKey

  @Test
  public void should_persist_and_get_reference() throws Exception {
    compoundKey = new ClusteredKey(RandomUtils.nextLong(0,Long.MAX_VALUE), Type.AUDIO);

    entity = new ClusteredEntityWithEnumCompoundKey(compoundKey, "clustered_value");

    manager.insert(entity);

    ClusteredEntityWithEnumCompoundKey found = manager.getProxy(ClusteredEntityWithEnumCompoundKey.class,
                                                                    compoundKey);

    assertThat(found.getId()).isEqualTo(compoundKey);
    assertThat(found.getValue()).isEqualTo("clustered_value");
  }
View Full Code Here

Examples of info.archinnov.achilles.test.integration.entity.ClusteredEntityWithEnumCompoundKey

  @Test
  public void should_persist_and_find() throws Exception {
    compoundKey = new ClusteredKey(RandomUtils.nextLong(0,Long.MAX_VALUE), Type.AUDIO);

    entity = new ClusteredEntityWithEnumCompoundKey(compoundKey, "clustered_value");

    manager.insert(entity);

    ClusteredEntityWithEnumCompoundKey found = manager.find(ClusteredEntityWithEnumCompoundKey.class, compoundKey);

    assertThat(found.getId()).isEqualTo(compoundKey);
    assertThat(found.getValue()).isEqualTo("clustered_value");
  }
View Full Code Here

Examples of info.archinnov.achilles.test.integration.entity.ClusteredEntityWithEnumCompoundKey

  @Test
  public void should_update_modifications() throws Exception {

    compoundKey = new ClusteredKey(RandomUtils.nextLong(0,Long.MAX_VALUE), Type.FILE);

    entity = new ClusteredEntityWithEnumCompoundKey(compoundKey, "clustered_value");

    entity = manager.insert(entity);

    entity.setValue("new_clustered_value");
    manager.update(entity);
View Full Code Here

Examples of info.archinnov.achilles.test.integration.entity.ClusteredEntityWithEnumCompoundKey

  @Test
  public void should_delete() throws Exception {
    compoundKey = new ClusteredKey(RandomUtils.nextLong(0,Long.MAX_VALUE), Type.IMAGE);

    entity = new ClusteredEntityWithEnumCompoundKey(compoundKey, "clustered_value");

    entity = manager.insert(entity);

    manager.delete(entity);
View Full Code Here

Examples of info.archinnov.achilles.test.integration.entity.ClusteredEntityWithEnumCompoundKey

  public void should_refresh() throws Exception {

    long partitionKey = RandomUtils.nextLong(0,Long.MAX_VALUE);
    compoundKey = new ClusteredKey(partitionKey, Type.FILE);

    entity = new ClusteredEntityWithEnumCompoundKey(compoundKey, "clustered_value");

    entity = manager.insert(entity);

    session.execute("UPDATE " + TABLE_NAME + " set value='new_clustered_value' where id=" + partitionKey
        + " and type = 'FILE'");
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.