Examples of CqlKeyspaceDefinitionImpl


Examples of com.netflix.astyanax.cql.schema.CqlKeyspaceDefinitionImpl

  public OperationResult<SchemaChangeResult> updateKeyspace(Properties props) throws ConnectionException {
    String keyspaceName = (String) props.remove("name");
    if (keyspaceName == null) {
      throw new RuntimeException("Options missing 'name' property for keyspace name");
    }
    return new CqlKeyspaceDefinitionImpl(session, props).setName(keyspaceName).alterKeyspace().execute();
  }
View Full Code Here

Examples of com.netflix.astyanax.cql.schema.CqlKeyspaceDefinitionImpl

  }
 
  @Override
  public Properties getColumnFamilyProperties(String keyspace, String columnfamilyName) throws ConnectionException {
    try {
      return new CqlKeyspaceDefinitionImpl(session).setName(keyspace).getColumnFamily(columnfamilyName).getProperties();
    } catch (Exception e) {
      throw new RuntimeException(e);
    }
  }
View Full Code Here

Examples of com.netflix.astyanax.cql.schema.CqlKeyspaceDefinitionImpl

    Statement query = QueryBuilder.select().from("system", "schema_keyspaces").where(eq("keyspace_name", keyspaceName));
    Row row = session.execute(query).one();
    if (row == null) {
      throw new RuntimeException("Keyspace not found: " + keyspaceName);
    }
    return (new CqlKeyspaceDefinitionImpl(session, row));
  }
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.