com.netflix.astyanax.thrift
Class ThriftClusterImpl
java.lang.Object
com.netflix.astyanax.thrift.ThriftClusterImpl
- All Implemented Interfaces:
- com.netflix.astyanax.Cluster
public class ThriftClusterImpl
- extends java.lang.Object
- implements com.netflix.astyanax.Cluster
|
Constructor Summary |
ThriftClusterImpl(com.netflix.astyanax.AstyanaxConfiguration config,
com.netflix.astyanax.connectionpool.ConnectionPool<org.apache.cassandra.thrift.Cassandra.Client> connectionPool,
com.netflix.astyanax.KeyspaceTracerFactory tracerFactory)
|
|
Method Summary |
com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> |
addColumnFamily(com.netflix.astyanax.ddl.ColumnFamilyDefinition def)
|
com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> |
addKeyspace(com.netflix.astyanax.ddl.KeyspaceDefinition def)
|
com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> |
createColumnFamily(java.util.Map<java.lang.String,java.lang.Object> options)
|
com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> |
createColumnFamily(java.util.Properties props)
|
com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> |
createKeyspace(java.util.Map<java.lang.String,java.lang.Object> options)
|
com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> |
createKeyspace(java.util.Properties props)
|
java.lang.String |
describeClusterName()
|
com.netflix.astyanax.ddl.KeyspaceDefinition |
describeKeyspace(java.lang.String ksName)
|
java.util.List<com.netflix.astyanax.ddl.KeyspaceDefinition> |
describeKeyspaces()
|
java.lang.String |
describePartitioner()
|
java.util.Map<java.lang.String,java.util.List<java.lang.String>> |
describeSchemaVersions()
|
java.lang.String |
describeSnitch()
|
com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> |
dropColumnFamily(java.lang.String keyspaceName,
java.lang.String columnFamilyName)
|
com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> |
dropKeyspace(java.lang.String keyspaceName)
|
java.util.Properties |
getAllKeyspaceProperties()
|
java.util.Properties |
getColumnFamilyProperties(java.lang.String keyspace,
java.lang.String columnFamily)
|
com.netflix.astyanax.AstyanaxConfiguration |
getConfig()
|
com.netflix.astyanax.Keyspace |
getKeyspace(java.lang.String ksName)
|
java.util.Properties |
getKeyspaceProperties(java.lang.String keyspace)
|
java.lang.String |
getVersion()
Get the version from the cluster |
com.netflix.astyanax.ddl.ColumnDefinition |
makeColumnDefinition()
|
com.netflix.astyanax.ddl.ColumnFamilyDefinition |
makeColumnFamilyDefinition()
|
com.netflix.astyanax.ddl.KeyspaceDefinition |
makeKeyspaceDefinition()
|
com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> |
updateColumnFamily(com.netflix.astyanax.ddl.ColumnFamilyDefinition def)
|
com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> |
updateColumnFamily(java.util.Map<java.lang.String,java.lang.Object> options)
|
com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> |
updateColumnFamily(java.util.Properties props)
|
com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> |
updateKeyspace(com.netflix.astyanax.ddl.KeyspaceDefinition def)
|
com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> |
updateKeyspace(java.util.Map<java.lang.String,java.lang.Object> options)
|
com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> |
updateKeyspace(java.util.Properties props)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ThriftClusterImpl
public ThriftClusterImpl(com.netflix.astyanax.AstyanaxConfiguration config,
com.netflix.astyanax.connectionpool.ConnectionPool<org.apache.cassandra.thrift.Cassandra.Client> connectionPool,
com.netflix.astyanax.KeyspaceTracerFactory tracerFactory)
describeClusterName
public java.lang.String describeClusterName()
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Specified by:
describeClusterName in interface com.netflix.astyanax.Cluster
- Throws:
com.netflix.astyanax.connectionpool.exceptions.ConnectionException
describeSnitch
public java.lang.String describeSnitch()
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Specified by:
describeSnitch in interface com.netflix.astyanax.Cluster
- Throws:
com.netflix.astyanax.connectionpool.exceptions.ConnectionException
describePartitioner
public java.lang.String describePartitioner()
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Specified by:
describePartitioner in interface com.netflix.astyanax.Cluster
- Throws:
com.netflix.astyanax.connectionpool.exceptions.ConnectionException
describeSchemaVersions
public java.util.Map<java.lang.String,java.util.List<java.lang.String>> describeSchemaVersions()
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Specified by:
describeSchemaVersions in interface com.netflix.astyanax.Cluster
- Throws:
com.netflix.astyanax.connectionpool.exceptions.ConnectionException
getVersion
public java.lang.String getVersion()
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Get the version from the cluster
- Specified by:
getVersion in interface com.netflix.astyanax.Cluster
- Returns:
-
- Throws:
com.netflix.astyanax.connectionpool.exceptions.OperationException
com.netflix.astyanax.connectionpool.exceptions.ConnectionException
describeKeyspaces
public java.util.List<com.netflix.astyanax.ddl.KeyspaceDefinition> describeKeyspaces()
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Specified by:
describeKeyspaces in interface com.netflix.astyanax.Cluster
- Throws:
com.netflix.astyanax.connectionpool.exceptions.ConnectionException
describeKeyspace
public com.netflix.astyanax.ddl.KeyspaceDefinition describeKeyspace(java.lang.String ksName)
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Specified by:
describeKeyspace in interface com.netflix.astyanax.Cluster
- Throws:
com.netflix.astyanax.connectionpool.exceptions.ConnectionException
getKeyspace
public com.netflix.astyanax.Keyspace getKeyspace(java.lang.String ksName)
- Specified by:
getKeyspace in interface com.netflix.astyanax.Cluster
makeColumnFamilyDefinition
public com.netflix.astyanax.ddl.ColumnFamilyDefinition makeColumnFamilyDefinition()
- Specified by:
makeColumnFamilyDefinition in interface com.netflix.astyanax.Cluster
addColumnFamily
public com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> addColumnFamily(com.netflix.astyanax.ddl.ColumnFamilyDefinition def)
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Specified by:
addColumnFamily in interface com.netflix.astyanax.Cluster
- Throws:
com.netflix.astyanax.connectionpool.exceptions.ConnectionException
createColumnFamily
public com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> createColumnFamily(java.util.Map<java.lang.String,java.lang.Object> options)
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Specified by:
createColumnFamily in interface com.netflix.astyanax.Cluster
- Throws:
com.netflix.astyanax.connectionpool.exceptions.ConnectionException
createColumnFamily
public com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> createColumnFamily(java.util.Properties props)
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Specified by:
createColumnFamily in interface com.netflix.astyanax.Cluster
- Throws:
com.netflix.astyanax.connectionpool.exceptions.ConnectionException
updateColumnFamily
public com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> updateColumnFamily(com.netflix.astyanax.ddl.ColumnFamilyDefinition def)
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Specified by:
updateColumnFamily in interface com.netflix.astyanax.Cluster
- Throws:
com.netflix.astyanax.connectionpool.exceptions.ConnectionException
updateColumnFamily
public com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> updateColumnFamily(java.util.Map<java.lang.String,java.lang.Object> options)
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Specified by:
updateColumnFamily in interface com.netflix.astyanax.Cluster
- Throws:
com.netflix.astyanax.connectionpool.exceptions.ConnectionException
updateColumnFamily
public com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> updateColumnFamily(java.util.Properties props)
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Specified by:
updateColumnFamily in interface com.netflix.astyanax.Cluster
- Throws:
com.netflix.astyanax.connectionpool.exceptions.ConnectionException
makeKeyspaceDefinition
public com.netflix.astyanax.ddl.KeyspaceDefinition makeKeyspaceDefinition()
- Specified by:
makeKeyspaceDefinition in interface com.netflix.astyanax.Cluster
addKeyspace
public com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> addKeyspace(com.netflix.astyanax.ddl.KeyspaceDefinition def)
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Specified by:
addKeyspace in interface com.netflix.astyanax.Cluster
- Throws:
com.netflix.astyanax.connectionpool.exceptions.ConnectionException
createKeyspace
public com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> createKeyspace(java.util.Map<java.lang.String,java.lang.Object> options)
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Specified by:
createKeyspace in interface com.netflix.astyanax.Cluster
- Throws:
com.netflix.astyanax.connectionpool.exceptions.ConnectionException
createKeyspace
public com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> createKeyspace(java.util.Properties props)
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Specified by:
createKeyspace in interface com.netflix.astyanax.Cluster
- Throws:
com.netflix.astyanax.connectionpool.exceptions.ConnectionException
updateKeyspace
public com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> updateKeyspace(com.netflix.astyanax.ddl.KeyspaceDefinition def)
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Specified by:
updateKeyspace in interface com.netflix.astyanax.Cluster
- Throws:
com.netflix.astyanax.connectionpool.exceptions.ConnectionException
updateKeyspace
public com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> updateKeyspace(java.util.Map<java.lang.String,java.lang.Object> options)
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Specified by:
updateKeyspace in interface com.netflix.astyanax.Cluster
- Throws:
com.netflix.astyanax.connectionpool.exceptions.ConnectionException
updateKeyspace
public com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> updateKeyspace(java.util.Properties props)
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Specified by:
updateKeyspace in interface com.netflix.astyanax.Cluster
- Throws:
com.netflix.astyanax.connectionpool.exceptions.ConnectionException
makeColumnDefinition
public com.netflix.astyanax.ddl.ColumnDefinition makeColumnDefinition()
- Specified by:
makeColumnDefinition in interface com.netflix.astyanax.Cluster
getConfig
public com.netflix.astyanax.AstyanaxConfiguration getConfig()
- Specified by:
getConfig in interface com.netflix.astyanax.Cluster
dropColumnFamily
public com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> dropColumnFamily(java.lang.String keyspaceName,
java.lang.String columnFamilyName)
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Specified by:
dropColumnFamily in interface com.netflix.astyanax.Cluster
- Throws:
com.netflix.astyanax.connectionpool.exceptions.ConnectionException
dropKeyspace
public com.netflix.astyanax.connectionpool.OperationResult<com.netflix.astyanax.ddl.SchemaChangeResult> dropKeyspace(java.lang.String keyspaceName)
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Specified by:
dropKeyspace in interface com.netflix.astyanax.Cluster
- Throws:
com.netflix.astyanax.connectionpool.exceptions.ConnectionException
getAllKeyspaceProperties
public java.util.Properties getAllKeyspaceProperties()
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Specified by:
getAllKeyspaceProperties in interface com.netflix.astyanax.Cluster
- Throws:
com.netflix.astyanax.connectionpool.exceptions.ConnectionException
getKeyspaceProperties
public java.util.Properties getKeyspaceProperties(java.lang.String keyspace)
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Specified by:
getKeyspaceProperties in interface com.netflix.astyanax.Cluster
- Throws:
com.netflix.astyanax.connectionpool.exceptions.ConnectionException
getColumnFamilyProperties
public java.util.Properties getColumnFamilyProperties(java.lang.String keyspace,
java.lang.String columnFamily)
throws com.netflix.astyanax.connectionpool.exceptions.ConnectionException
- Specified by:
getColumnFamilyProperties in interface com.netflix.astyanax.Cluster
- Throws:
com.netflix.astyanax.connectionpool.exceptions.ConnectionException