Package | Description |
---|---|
com.mongodb |
The core mongodb package
|
com.mongodb.async.client |
This packages contains classes for the new async client
|
com.mongodb.connection |
Contains classes that manage connecting to MongoDB servers.
|
com.mongodb.operation |
The core of the MongoDB driver works via operations, using the command pattern.
|
Modifier and Type | Field and Description |
---|---|
private MongoCredential |
MongoSecurityException.credential |
private MongoCredential |
ConnectionString.credential |
Modifier and Type | Field and Description |
---|---|
private java.util.List<MongoCredential> |
Mongo.credentialsList |
Modifier and Type | Method and Description |
---|---|
static MongoCredential |
MongoCredential.createCredential(java.lang.String userName,
java.lang.String database,
char[] password)
Creates a MongoCredential instance with an unspecified mechanism.
|
private MongoCredential |
ConnectionString.createCredentials(java.util.Map<java.lang.String,java.util.List<java.lang.String>> optionsMap,
java.lang.String userName,
char[] password) |
static MongoCredential |
MongoCredential.createGSSAPICredential(java.lang.String userName)
Creates a MongoCredential instance for the GSSAPI SASL mechanism.
|
static MongoCredential |
MongoCredential.createMongoCRCredential(java.lang.String userName,
java.lang.String database,
char[] password)
Creates a MongoCredential instance for the MongoDB Challenge Response protocol.
|
static MongoCredential |
MongoCredential.createMongoX509Credential()
Creates a MongoCredential instance for the MongoDB X.509 protocol where the distinguished subject name of the client certificate
acts as the userName.
|
static MongoCredential |
MongoCredential.createMongoX509Credential(java.lang.String userName)
Creates a MongoCredential instance for the MongoDB X.509 protocol.
|
static MongoCredential |
MongoCredential.createPlainCredential(java.lang.String userName,
java.lang.String source,
char[] password)
Creates a MongoCredential instance for the PLAIN SASL mechanism.
|
static MongoCredential |
MongoCredential.createScramSha1Credential(java.lang.String userName,
java.lang.String source,
char[] password)
Creates a MongoCredential instance for the SCRAM-SHA-1 SASL mechanism.
|
MongoCredential |
MongoSecurityException.getCredential()
The credential being authenticated.
|
MongoCredential |
ConnectionString.getCredential()
Gets the credentials in an immutable list.
|
MongoCredential |
MongoURI.getCredentials()
Deprecated.
Gets the credentials.
|
MongoCredential |
MongoClientURI.getCredentials()
Gets the credentials.
|
<T> MongoCredential |
MongoCredential.withMechanismProperty(java.lang.String key,
T value)
Creates a new MongoCredential as a copy of this instance, with the specified mechanism property added.
|
Modifier and Type | Method and Description |
---|---|
java.util.List<MongoCredential> |
ConnectionString.getCredentialList()
Deprecated.
|
java.util.List<MongoCredential> |
MongoClient.getCredentialsList()
Gets the list of credentials that this client authenticates all connections with
|
(package private) java.util.List<MongoCredential> |
Mongo.getCredentialsList() |
Modifier and Type | Method and Description |
---|---|
private static Cluster |
Mongo.createCluster(ClusterSettings clusterSettings,
java.util.List<MongoCredential> credentialsList,
MongoClientOptions options,
MongoDriverInformation mongoDriverInformation) |
private static Cluster |
Mongo.createCluster(java.util.List<ServerAddress> seedList,
java.util.List<MongoCredential> credentialsList,
MongoClientOptions options,
MongoDriverInformation mongoDriverInformation) |
private static Cluster |
Mongo.createCluster(ServerAddress serverAddress,
java.util.List<MongoCredential> credentialsList,
MongoClientOptions options,
MongoDriverInformation mongoDriverInformation) |
Constructor and Description |
---|
MongoClient(java.util.List<ServerAddress> seeds,
MongoCredential credential,
MongoClientOptions options)
Creates an instance based on a list of replica set members or mongos servers.
|
MongoClient(java.util.List<ServerAddress> seeds,
MongoCredential credential,
MongoClientOptions options,
MongoDriverInformation mongoDriverInformation)
Creates a MongoClient
|
MongoClient(ServerAddress addr,
MongoCredential credential,
MongoClientOptions options)
Creates a Mongo instance based on a (single) mongo node using a given server address, credential, and options
|
MongoClient(ServerAddress addr,
MongoCredential credential,
MongoClientOptions options,
MongoDriverInformation mongoDriverInformation)
Creates a MongoClient to a single node using a given ServerAddress.
|
MongoCredential(MongoCredential from,
java.lang.String mechanismPropertyKey,
T mechanismPropertyValue)
Constructs a new instance using the given credential plus an additional mechanism property.
|
MongoSecurityException(MongoCredential credential,
java.lang.String message)
Construct an instance
|
MongoSecurityException(MongoCredential credential,
java.lang.String message,
java.lang.Throwable cause)
Construct an instance
|
Constructor and Description |
---|
Mongo(Cluster cluster,
MongoClientOptions options,
java.util.List<MongoCredential> credentialsList) |
Mongo(java.util.List<ServerAddress> seedList,
java.util.List<MongoCredential> credentialsList,
MongoClientOptions options) |
Mongo(java.util.List<ServerAddress> seedList,
java.util.List<MongoCredential> credentialsList,
MongoClientOptions options,
MongoDriverInformation mongoDriverInformation) |
Mongo(ServerAddress serverAddress,
java.util.List<MongoCredential> credentialsList,
MongoClientOptions options) |
Mongo(ServerAddress serverAddress,
java.util.List<MongoCredential> credentialsList,
MongoClientOptions options,
MongoDriverInformation mongoDriverInformation) |
MongoClient(java.util.List<ServerAddress> seeds,
java.util.List<MongoCredential> credentialsList)
Deprecated.
|
MongoClient(java.util.List<ServerAddress> seeds,
java.util.List<MongoCredential> credentialsList,
MongoClientOptions options)
Deprecated.
|
MongoClient(java.util.List<ServerAddress> seeds,
java.util.List<MongoCredential> credentialsList,
MongoClientOptions options,
MongoDriverInformation mongoDriverInformation)
|
MongoClient(ServerAddress addr,
java.util.List<MongoCredential> credentialsList)
Deprecated.
|
MongoClient(ServerAddress addr,
java.util.List<MongoCredential> credentialsList,
MongoClientOptions options)
Deprecated.
|
MongoClient(ServerAddress addr,
java.util.List<MongoCredential> credentialsList,
MongoClientOptions options,
MongoDriverInformation mongoDriverInformation)
|
Modifier and Type | Field and Description |
---|---|
private java.util.List<MongoCredential> |
MongoClientSettings.credentialList |
private java.util.List<MongoCredential> |
MongoClientSettings.Builder.credentialList |
Modifier and Type | Method and Description |
---|---|
MongoCredential |
MongoClientSettings.getCredential()
Gets the credential list.
|
Modifier and Type | Method and Description |
---|---|
java.util.List<MongoCredential> |
MongoClientSettings.getCredentialList()
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
MongoClientSettings.Builder |
MongoClientSettings.Builder.credential(MongoCredential credential)
Sets the credential.
|
Modifier and Type | Method and Description |
---|---|
MongoClientSettings.Builder |
MongoClientSettings.Builder.credentialList(java.util.List<MongoCredential> credentialList)
Deprecated.
|
Modifier and Type | Field and Description |
---|---|
private MongoCredential |
ScramSha1Authenticator.ScramSha1SaslClient.credential |
private MongoCredential |
Authenticator.credential |
Modifier and Type | Field and Description |
---|---|
private java.util.List<MongoCredential> |
DefaultClusterableServerFactory.credentialList |
Modifier and Type | Method and Description |
---|---|
(package private) MongoCredential |
Authenticator.getCredential() |
Modifier and Type | Method and Description |
---|---|
private Authenticator |
InternalStreamConnectionFactory.createAuthenticator(MongoCredential credential) |
Modifier and Type | Method and Description |
---|---|
Cluster |
DefaultClusterFactory.create(ClusterSettings settings,
ServerSettings serverSettings,
ConnectionPoolSettings connectionPoolSettings,
StreamFactory streamFactory,
StreamFactory heartbeatStreamFactory,
java.util.List<MongoCredential> credentialList,
ClusterListener clusterListener,
ConnectionPoolListener connectionPoolListener,
ConnectionListener connectionListener) |
Cluster |
ClusterFactory.create(ClusterSettings settings,
ServerSettings serverSettings,
ConnectionPoolSettings connectionPoolSettings,
StreamFactory streamFactory,
StreamFactory heartbeatStreamFactory,
java.util.List<MongoCredential> credentialList,
ClusterListener clusterListener,
ConnectionPoolListener connectionPoolListener,
ConnectionListener connectionListener)
Creates a cluster with the given settings.
|
Cluster |
DefaultClusterFactory.create(ClusterSettings settings,
ServerSettings serverSettings,
ConnectionPoolSettings connectionPoolSettings,
StreamFactory streamFactory,
StreamFactory heartbeatStreamFactory,
java.util.List<MongoCredential> credentialList,
ClusterListener clusterListener,
ConnectionPoolListener connectionPoolListener,
ConnectionListener connectionListener,
CommandListener commandListener)
|
Cluster |
DefaultClusterFactory.create(ClusterSettings settings,
ServerSettings serverSettings,
ConnectionPoolSettings connectionPoolSettings,
StreamFactory streamFactory,
StreamFactory heartbeatStreamFactory,
java.util.List<MongoCredential> credentialList,
ClusterListener clusterListener,
ConnectionPoolListener connectionPoolListener,
ConnectionListener connectionListener,
CommandListener commandListener,
java.lang.String applicationName,
MongoDriverInformation mongoDriverInformation)
|
Cluster |
DefaultClusterFactory.createCluster(ClusterSettings clusterSettings,
ServerSettings serverSettings,
ConnectionPoolSettings connectionPoolSettings,
StreamFactory streamFactory,
StreamFactory heartbeatStreamFactory,
java.util.List<MongoCredential> credentialList,
CommandListener commandListener,
java.lang.String applicationName,
MongoDriverInformation mongoDriverInformation)
|
Cluster |
DefaultClusterFactory.createCluster(ClusterSettings clusterSettings,
ServerSettings serverSettings,
ConnectionPoolSettings connectionPoolSettings,
StreamFactory streamFactory,
StreamFactory heartbeatStreamFactory,
java.util.List<MongoCredential> credentialList,
CommandListener commandListener,
java.lang.String applicationName,
MongoDriverInformation mongoDriverInformation,
java.util.List<MongoCompressor> compressorList)
Creates a cluster with the given settings.
|
Constructor and Description |
---|
Authenticator(MongoCredential credential) |
DefaultAuthenticator(MongoCredential credential) |
GSSAPIAuthenticator(MongoCredential credential) |
NativeAuthenticator(MongoCredential credential) |
PlainAuthenticator(MongoCredential credential) |
SaslAuthenticator(MongoCredential credential) |
ScramSha1Authenticator(MongoCredential credential) |
ScramSha1Authenticator(MongoCredential credential,
ScramSha1Authenticator.RandomStringGenerator randomStringGenerator) |
ScramSha1SaslClient(MongoCredential credential,
ScramSha1Authenticator.RandomStringGenerator randomStringGenerator) |
X509Authenticator(MongoCredential credential) |
Constructor and Description |
---|
DefaultClusterableServerFactory(ClusterId clusterId,
ClusterSettings clusterSettings,
ServerSettings serverSettings,
ConnectionPoolSettings connectionPoolSettings,
StreamFactory streamFactory,
StreamFactory heartbeatStreamFactory,
java.util.List<MongoCredential> credentialList,
CommandListener commandListener,
java.lang.String applicationName,
MongoDriverInformation mongoDriverInformation,
java.util.List<MongoCompressor> compressorList) |
InternalStreamConnectionFactory(StreamFactory streamFactory,
java.util.List<MongoCredential> credentialList,
java.lang.String applicationName,
MongoDriverInformation mongoDriverInformation,
java.util.List<MongoCompressor> compressorList,
CommandListener commandListener) |
Modifier and Type | Field and Description |
---|---|
private MongoCredential |
UpdateUserOperation.credential |
private MongoCredential |
CreateUserOperation.credential |
Modifier and Type | Method and Description |
---|---|
MongoCredential |
UpdateUserOperation.getCredential()
Gets the users credentials.
|
MongoCredential |
CreateUserOperation.getCredential()
Gets the users credentials.
|
Modifier and Type | Method and Description |
---|---|
(package private) static BsonDocument |
UserOperationHelper.asCollectionInsertDocument(MongoCredential credential,
boolean readOnly) |
(package private) static BsonDocument |
UserOperationHelper.asCollectionQueryDocument(MongoCredential credential) |
(package private) static BsonDocument |
UserOperationHelper.asCollectionUpdateDocument(MongoCredential credential,
boolean readOnly) |
(package private) static BsonDocument |
UserOperationHelper.asCommandDocument(MongoCredential credential,
boolean readOnly,
java.lang.String commandName) |
private static java.lang.String |
UserOperationHelper.getRoleName(MongoCredential credential,
boolean readOnly) |
Constructor and Description |
---|
CreateUserOperation(MongoCredential credential,
boolean readOnly)
|
CreateUserOperation(MongoCredential credential,
boolean readOnly,
WriteConcern writeConcern)
Construct a new instance.
|
UpdateUserOperation(MongoCredential credential,
boolean readOnly)
|
UpdateUserOperation(MongoCredential credential,
boolean readOnly,
WriteConcern writeConcern)
Construct a new instance.
|