Interface MongoDbClientFactory

All Known Implementing Classes:
DefaultMongoDbClientFactory

public interface MongoDbClientFactory
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final org.slf4j.Logger
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static SSLContext
    Creates SSL context initialized with custom
    default com.mongodb.client.MongoClient
    Creates native MongoClient instance
    com.mongodb.MongoClientSettings
    Creates MongoClientSettings used to obtain MongoClient instances
    static KeyStore
    loadKeyStore(String type, Path path, char[] password)
    Creates keystore
  • Field Details

    • LOGGER

      static final org.slf4j.Logger LOGGER
  • Method Details

    • getMongoClientSettings

      com.mongodb.MongoClientSettings getMongoClientSettings()
      Creates MongoClientSettings used to obtain MongoClient instances
      Returns:
      client settings
    • getMongoClient

      default com.mongodb.client.MongoClient getMongoClient()
      Creates native MongoClient instance
      Returns:
      mongo client
    • loadKeyStore

      static KeyStore loadKeyStore(String type, Path path, char[] password)
      Creates keystore
      Parameters:
      type - keyfile type
      path - keyfile path
      password - keyfile password
      Returns:
      keystore with loaded keys
    • createSSLContext

      static SSLContext createSSLContext(MongoDbConnectorConfig connectorConfig)
      Creates SSL context initialized with custom
      Parameters:
      connectorConfig - connector configuration
      Returns:
      ssl context