Package com.apple.foundationdb
Class Cluster
- java.lang.Object
-
- com.apple.foundationdb.Cluster
-
- All Implemented Interfaces:
java.lang.AutoCloseable
@Deprecated public class Cluster extends java.lang.Object
Deprecated.TheCluster
represents a connection to a physical set of cooperating machines running FoundationDB. ACluster
is opened with a reference to a cluster file. This class is deprecated. UseFDB.open()
to open aDatabase
directly
Note:Cluster
objects must beclosed
when no longer in use in order to free any associated resources.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description void
checkUnclosed(java.lang.String context)
void
close()
boolean
isClosed()
Database
openDatabase()
Deprecated.Creates a connection to the database on an FDB cluster.Database
openDatabase(java.util.concurrent.Executor e)
Deprecated.Creates a connection to the database on an FDB cluster.ClusterOptions
options()
Deprecated.Returns a set of options that can be set on aCluster
.
-
-
-
Method Detail
-
options
public ClusterOptions options()
Deprecated.Returns a set of options that can be set on aCluster
. In the current version of the API, there are no options that can be set on aCluster
.- Returns:
- a set of cluster-specific options affecting this
Cluster
-
openDatabase
public Database openDatabase() throws FDBException
Deprecated.Creates a connection to the database on an FDB cluster.- Returns:
- a
Future
that will be set to aDatabase
upon successful connection. - Throws:
FDBException
-
openDatabase
public Database openDatabase(java.util.concurrent.Executor e) throws FDBException
Deprecated.Creates a connection to the database on an FDB cluster.- Parameters:
e
- theExecutor
to use when executing asynchronous callbacks for the database- Returns:
- a
Future
that will be set to aDatabase
upon successful connection. - Throws:
FDBException
-
isClosed
public boolean isClosed()
-
checkUnclosed
public void checkUnclosed(java.lang.String context)
-
close
public void close()
- Specified by:
close
in interfacejava.lang.AutoCloseable
-
-