Interface MongoDbEndpointBuilderFactory.AdvancedMongoDbEndpointProducerBuilder

All Superinterfaces:
org.apache.camel.builder.EndpointProducerBuilder, org.apache.camel.EndpointProducerResolver
All Known Subinterfaces:
MongoDbEndpointBuilderFactory.AdvancedMongoDbEndpointBuilder
Enclosing interface:
MongoDbEndpointBuilderFactory

public static interface MongoDbEndpointBuilderFactory.AdvancedMongoDbEndpointProducerBuilder extends org.apache.camel.builder.EndpointProducerBuilder
Advanced builder for endpoint producers for the MongoDB component.
  • Method Details

    • basic

    • lazyStartProducer

      default MongoDbEndpointBuilderFactory.AdvancedMongoDbEndpointProducerBuilder lazyStartProducer(boolean lazyStartProducer)
      Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the route to fail being started. By deferring this startup to be lazy then the startup failure can be handled during routing messages via Camel's routing error handlers. Beware that when the first message is processed then creating and starting the producer may take a little time and prolong the total processing time of the processing. The option is a: boolean type. Default: false Group: producer (advanced)
      Parameters:
      lazyStartProducer - the value to set
      Returns:
      the dsl builder
    • lazyStartProducer

      Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the route to fail being started. By deferring this startup to be lazy then the startup failure can be handled during routing messages via Camel's routing error handlers. Beware that when the first message is processed then creating and starting the producer may take a little time and prolong the total processing time of the processing. The option will be converted to a boolean type. Default: false Group: producer (advanced)
      Parameters:
      lazyStartProducer - the value to set
      Returns:
      the dsl builder
    • appName

      Sets the logical name of the application. The application name may be used by the client to identify the application to the server, for use in server logs, slow query logs, and profile collection. Default: null. The option is a: java.lang.String type. Group: advanced
      Parameters:
      appName - the value to set
      Returns:
      the dsl builder
    • compressors

      Specifies one or more compression algorithms that the driver will attempt to use to compress requests sent to the connected MongoDB instance. Possible values include: zlib, snappy, and zstd. Default: null. The option is a: java.lang.String type. Group: advanced
      Parameters:
      compressors - the value to set
      Returns:
      the dsl builder
    • connectTimeoutMS

      Specifies the maximum amount of time, in milliseconds, the Java driver waits for a connection to open before timing out. A value of 0 instructs the driver to never time out while waiting for a connection to open. Default: 10000 (10 seconds). The option is a: java.lang.Integer type. Default: 10000 Group: advanced
      Parameters:
      connectTimeoutMS - the value to set
      Returns:
      the dsl builder
    • connectTimeoutMS

      Specifies the maximum amount of time, in milliseconds, the Java driver waits for a connection to open before timing out. A value of 0 instructs the driver to never time out while waiting for a connection to open. Default: 10000 (10 seconds). The option will be converted to a java.lang.Integer type. Default: 10000 Group: advanced
      Parameters:
      connectTimeoutMS - the value to set
      Returns:
      the dsl builder
    • cursorRegenerationDelay

      default MongoDbEndpointBuilderFactory.AdvancedMongoDbEndpointProducerBuilder cursorRegenerationDelay(long cursorRegenerationDelay)
      MongoDB tailable cursors will block until new data arrives. If no new data is inserted, after some time the cursor will be automatically freed and closed by the MongoDB server. The client is expected to regenerate the cursor if needed. This value specifies the time to wait before attempting to fetch a new cursor, and if the attempt fails, how long before the next attempt is made. Default value is 1000ms. The option is a: long type. Default: 1000 Group: advanced
      Parameters:
      cursorRegenerationDelay - the value to set
      Returns:
      the dsl builder
    • cursorRegenerationDelay

      default MongoDbEndpointBuilderFactory.AdvancedMongoDbEndpointProducerBuilder cursorRegenerationDelay(String cursorRegenerationDelay)
      MongoDB tailable cursors will block until new data arrives. If no new data is inserted, after some time the cursor will be automatically freed and closed by the MongoDB server. The client is expected to regenerate the cursor if needed. This value specifies the time to wait before attempting to fetch a new cursor, and if the attempt fails, how long before the next attempt is made. Default value is 1000ms. The option will be converted to a long type. Default: 1000 Group: advanced
      Parameters:
      cursorRegenerationDelay - the value to set
      Returns:
      the dsl builder
    • directConnection

      default MongoDbEndpointBuilderFactory.AdvancedMongoDbEndpointProducerBuilder directConnection(boolean directConnection)
      Specifies that the driver must connect to the host directly. Default: false. The option is a: boolean type. Default: false Group: advanced
      Parameters:
      directConnection - the value to set
      Returns:
      the dsl builder
    • directConnection

      Specifies that the driver must connect to the host directly. Default: false. The option will be converted to a boolean type. Default: false Group: advanced
      Parameters:
      directConnection - the value to set
      Returns:
      the dsl builder
    • dynamicity

      Sets whether this endpoint will attempt to dynamically resolve the target database and collection from the incoming Exchange properties. Can be used to override at runtime the database and collection specified on the otherwise static endpoint URI. It is disabled by default to boost performance. Enabling it will take a minimal performance hit. The option is a: boolean type. Default: false Group: advanced
      Parameters:
      dynamicity - the value to set
      Returns:
      the dsl builder
    • dynamicity

      Sets whether this endpoint will attempt to dynamically resolve the target database and collection from the incoming Exchange properties. Can be used to override at runtime the database and collection specified on the otherwise static endpoint URI. It is disabled by default to boost performance. Enabling it will take a minimal performance hit. The option will be converted to a boolean type. Default: false Group: advanced
      Parameters:
      dynamicity - the value to set
      Returns:
      the dsl builder
    • heartbeatFrequencyMS

      default MongoDbEndpointBuilderFactory.AdvancedMongoDbEndpointProducerBuilder heartbeatFrequencyMS(Integer heartbeatFrequencyMS)
      heartbeatFrequencyMS controls when the driver checks the state of the MongoDB deployment. Specify the interval (in milliseconds) between checks, counted from the end of the previous check until the beginning of the next one. Default: Single-threaded drivers: 60 seconds. Multithreaded drivers: 10 seconds. The option is a: java.lang.Integer type. Group: advanced
      Parameters:
      heartbeatFrequencyMS - the value to set
      Returns:
      the dsl builder
    • heartbeatFrequencyMS

      default MongoDbEndpointBuilderFactory.AdvancedMongoDbEndpointProducerBuilder heartbeatFrequencyMS(String heartbeatFrequencyMS)
      heartbeatFrequencyMS controls when the driver checks the state of the MongoDB deployment. Specify the interval (in milliseconds) between checks, counted from the end of the previous check until the beginning of the next one. Default: Single-threaded drivers: 60 seconds. Multithreaded drivers: 10 seconds. The option will be converted to a java.lang.Integer type. Group: advanced
      Parameters:
      heartbeatFrequencyMS - the value to set
      Returns:
      the dsl builder
    • loadBalanced

      default MongoDbEndpointBuilderFactory.AdvancedMongoDbEndpointProducerBuilder loadBalanced(boolean loadBalanced)
      If true the driver will assume that it's connecting to MongoDB through a load balancer. The option is a: boolean type. Default: false Group: advanced
      Parameters:
      loadBalanced - the value to set
      Returns:
      the dsl builder
    • loadBalanced

      If true the driver will assume that it's connecting to MongoDB through a load balancer. The option will be converted to a boolean type. Default: false Group: advanced
      Parameters:
      loadBalanced - the value to set
      Returns:
      the dsl builder
    • localThresholdMS

      The size (in milliseconds) of the latency window for selecting among multiple suitable MongoDB instances. Default: 15 milliseconds. The option is a: java.lang.Integer type. Default: 15 Group: advanced
      Parameters:
      localThresholdMS - the value to set
      Returns:
      the dsl builder
    • localThresholdMS

      The size (in milliseconds) of the latency window for selecting among multiple suitable MongoDB instances. Default: 15 milliseconds. The option will be converted to a java.lang.Integer type. Default: 15 Group: advanced
      Parameters:
      localThresholdMS - the value to set
      Returns:
      the dsl builder
    • maxConnecting

      Specifies the maximum number of connections a pool may be establishing concurrently. Default: 2. The option is a: java.lang.Integer type. Default: 2 Group: advanced
      Parameters:
      maxConnecting - the value to set
      Returns:
      the dsl builder
    • maxConnecting

      Specifies the maximum number of connections a pool may be establishing concurrently. Default: 2. The option will be converted to a java.lang.Integer type. Default: 2 Group: advanced
      Parameters:
      maxConnecting - the value to set
      Returns:
      the dsl builder
    • maxIdleTimeMS

      Specifies the maximum amount of time, in milliseconds, the Java driver will allow a pooled connection to idle before closing the connection. A value of 0 indicates that there is no upper bound on how long the driver can allow a pooled collection to be idle. Default: 0. The option is a: java.lang.Integer type. Default: 0 Group: advanced
      Parameters:
      maxIdleTimeMS - the value to set
      Returns:
      the dsl builder
    • maxIdleTimeMS

      Specifies the maximum amount of time, in milliseconds, the Java driver will allow a pooled connection to idle before closing the connection. A value of 0 indicates that there is no upper bound on how long the driver can allow a pooled collection to be idle. Default: 0. The option will be converted to a java.lang.Integer type. Default: 0 Group: advanced
      Parameters:
      maxIdleTimeMS - the value to set
      Returns:
      the dsl builder
    • maxLifeTimeMS

      Specifies the maximum amount of time, in milliseconds, the Java driver will continue to use a pooled connection before closing the connection. A value of 0 indicates that there is no upper bound on how long the driver can keep a pooled connection open. Default: 0. The option is a: java.lang.Integer type. Default: 0 Group: advanced
      Parameters:
      maxLifeTimeMS - the value to set
      Returns:
      the dsl builder
    • maxLifeTimeMS

      Specifies the maximum amount of time, in milliseconds, the Java driver will continue to use a pooled connection before closing the connection. A value of 0 indicates that there is no upper bound on how long the driver can keep a pooled connection open. Default: 0. The option will be converted to a java.lang.Integer type. Default: 0 Group: advanced
      Parameters:
      maxLifeTimeMS - the value to set
      Returns:
      the dsl builder
    • maxPoolSize

      The maximum number of connections in the connection pool. The default value is 100. The option is a: java.lang.Integer type. Default: 100 Group: advanced
      Parameters:
      maxPoolSize - the value to set
      Returns:
      the dsl builder
    • maxPoolSize

      The maximum number of connections in the connection pool. The default value is 100. The option will be converted to a java.lang.Integer type. Default: 100 Group: advanced
      Parameters:
      maxPoolSize - the value to set
      Returns:
      the dsl builder
    • maxStalenessSeconds

      default MongoDbEndpointBuilderFactory.AdvancedMongoDbEndpointProducerBuilder maxStalenessSeconds(Integer maxStalenessSeconds)
      Specifies, in seconds, how stale a secondary can be before the driver stops communicating with that secondary. The minimum value is either 90 seconds or the heartbeat frequency plus 10 seconds, whichever is greater. For more information, see the server documentation for the maxStalenessSeconds option. Not providing a parameter or explicitly specifying -1 indicates that there should be no staleness check for secondaries. Default: -1. The option is a: java.lang.Integer type. Default: -1 Group: advanced
      Parameters:
      maxStalenessSeconds - the value to set
      Returns:
      the dsl builder
    • maxStalenessSeconds

      default MongoDbEndpointBuilderFactory.AdvancedMongoDbEndpointProducerBuilder maxStalenessSeconds(String maxStalenessSeconds)
      Specifies, in seconds, how stale a secondary can be before the driver stops communicating with that secondary. The minimum value is either 90 seconds or the heartbeat frequency plus 10 seconds, whichever is greater. For more information, see the server documentation for the maxStalenessSeconds option. Not providing a parameter or explicitly specifying -1 indicates that there should be no staleness check for secondaries. Default: -1. The option will be converted to a java.lang.Integer type. Default: -1 Group: advanced
      Parameters:
      maxStalenessSeconds - the value to set
      Returns:
      the dsl builder
    • minPoolSize

      Specifies the minimum number of connections that must exist at any moment in a single connection pool. Default: 0. The option is a: java.lang.Integer type. Default: 0 Group: advanced
      Parameters:
      minPoolSize - the value to set
      Returns:
      the dsl builder
    • minPoolSize

      Specifies the minimum number of connections that must exist at any moment in a single connection pool. Default: 0. The option will be converted to a java.lang.Integer type. Default: 0 Group: advanced
      Parameters:
      minPoolSize - the value to set
      Returns:
      the dsl builder
    • readPreference

      Configure how MongoDB clients route read operations to the members of a replica set. Possible values are PRIMARY, PRIMARY_PREFERRED, SECONDARY, SECONDARY_PREFERRED or NEAREST. The option is a: java.lang.String type. Default: PRIMARY Group: advanced
      Parameters:
      readPreference - the value to set
      Returns:
      the dsl builder
    • readPreferenceTags

      default MongoDbEndpointBuilderFactory.AdvancedMongoDbEndpointProducerBuilder readPreferenceTags(String readPreferenceTags)
      A representation of a tag set as a comma-separated list of colon-separated key-value pairs, e.g. dc:ny,rack:1. Spaces are stripped from the beginning and end of all keys and values. To specify a list of tag sets, using multiple readPreferenceTags, e.g., readPreferenceTags=dc:ny,rack:1;readPreferenceTags=dc:ny;readPreferenceTags= Note the empty value for the last one, which means match any secondary as a last resort. Order matters when using multiple readPreferenceTags. The option is a: java.lang.String type. Group: advanced
      Parameters:
      readPreferenceTags - the value to set
      Returns:
      the dsl builder
    • replicaSet

      Specifies that the connection string provided includes multiple hosts. When specified, the driver attempts to find all members of that set. The option is a: java.lang.String type. Group: advanced
      Parameters:
      replicaSet - the value to set
      Returns:
      the dsl builder
    • retryReads

      Specifies that the driver must retry supported read operations if they fail due to a network error. Default: true. The option is a: boolean type. Default: true Group: advanced
      Parameters:
      retryReads - the value to set
      Returns:
      the dsl builder
    • retryReads

      Specifies that the driver must retry supported read operations if they fail due to a network error. Default: true. The option will be converted to a boolean type. Default: true Group: advanced
      Parameters:
      retryReads - the value to set
      Returns:
      the dsl builder
    • retryWrites

      Specifies that the driver must retry supported write operations if they fail due to a network error. Default: true. The option is a: boolean type. Default: true Group: advanced
      Parameters:
      retryWrites - the value to set
      Returns:
      the dsl builder
    • retryWrites

      Specifies that the driver must retry supported write operations if they fail due to a network error. Default: true. The option will be converted to a boolean type. Default: true Group: advanced
      Parameters:
      retryWrites - the value to set
      Returns:
      the dsl builder
    • serverSelectionTimeoutMS

      default MongoDbEndpointBuilderFactory.AdvancedMongoDbEndpointProducerBuilder serverSelectionTimeoutMS(Integer serverSelectionTimeoutMS)
      Specifies how long (in milliseconds) to block for server selection before throwing an exception. Default: 30,000 milliseconds. The option is a: java.lang.Integer type. Default: 30000 Group: advanced
      Parameters:
      serverSelectionTimeoutMS - the value to set
      Returns:
      the dsl builder
    • serverSelectionTimeoutMS

      default MongoDbEndpointBuilderFactory.AdvancedMongoDbEndpointProducerBuilder serverSelectionTimeoutMS(String serverSelectionTimeoutMS)
      Specifies how long (in milliseconds) to block for server selection before throwing an exception. Default: 30,000 milliseconds. The option will be converted to a java.lang.Integer type. Default: 30000 Group: advanced
      Parameters:
      serverSelectionTimeoutMS - the value to set
      Returns:
      the dsl builder
    • socketTimeoutMS

      Specifies the maximum amount of time, in milliseconds, the Java driver will wait to send or receive a request before timing out. A value of 0 instructs the driver to never time out while waiting to send or receive a request. Default: 0. The option is a: java.lang.Integer type. Default: 0 Group: advanced
      Parameters:
      socketTimeoutMS - the value to set
      Returns:
      the dsl builder
    • socketTimeoutMS

      Specifies the maximum amount of time, in milliseconds, the Java driver will wait to send or receive a request before timing out. A value of 0 instructs the driver to never time out while waiting to send or receive a request. Default: 0. The option will be converted to a java.lang.Integer type. Default: 0 Group: advanced
      Parameters:
      socketTimeoutMS - the value to set
      Returns:
      the dsl builder
    • srvMaxHosts

      The maximum number of hosts from the SRV record to connect to. The option is a: java.lang.Integer type. Group: advanced
      Parameters:
      srvMaxHosts - the value to set
      Returns:
      the dsl builder
    • srvMaxHosts

      The maximum number of hosts from the SRV record to connect to. The option will be converted to a java.lang.Integer type. Group: advanced
      Parameters:
      srvMaxHosts - the value to set
      Returns:
      the dsl builder
    • srvServiceName

      Specifies the service name of the SRV resource recordsthe driver retrieves to construct your seed list. You must use the DNS Seed List Connection Format in your connection URI to use this option. Default: mongodb. The option is a: java.lang.String type. Default: mongodb Group: advanced
      Parameters:
      srvServiceName - the value to set
      Returns:
      the dsl builder
    • tls

      Specifies that all communication with MongoDB instances should use TLS. Supersedes the ssl option. Default: false. The option is a: boolean type. Default: false Group: advanced
      Parameters:
      tls - the value to set
      Returns:
      the dsl builder
    • tls

      Specifies that all communication with MongoDB instances should use TLS. Supersedes the ssl option. Default: false. The option will be converted to a boolean type. Default: false Group: advanced
      Parameters:
      tls - the value to set
      Returns:
      the dsl builder
    • tlsAllowInvalidHostnames

      default MongoDbEndpointBuilderFactory.AdvancedMongoDbEndpointProducerBuilder tlsAllowInvalidHostnames(boolean tlsAllowInvalidHostnames)
      Specifies that the driver should allow invalid hostnames in the certificate for TLS connections. Supersedes sslInvalidHostNameAllowed. Has the same effect as tlsInsecure by setting tlsAllowInvalidHostnames to true. Default: false. The option is a: boolean type. Default: false Group: advanced
      Parameters:
      tlsAllowInvalidHostnames - the value to set
      Returns:
      the dsl builder
    • tlsAllowInvalidHostnames

      default MongoDbEndpointBuilderFactory.AdvancedMongoDbEndpointProducerBuilder tlsAllowInvalidHostnames(String tlsAllowInvalidHostnames)
      Specifies that the driver should allow invalid hostnames in the certificate for TLS connections. Supersedes sslInvalidHostNameAllowed. Has the same effect as tlsInsecure by setting tlsAllowInvalidHostnames to true. Default: false. The option will be converted to a boolean type. Default: false Group: advanced
      Parameters:
      tlsAllowInvalidHostnames - the value to set
      Returns:
      the dsl builder
    • waitQueueTimeoutMS

      default MongoDbEndpointBuilderFactory.AdvancedMongoDbEndpointProducerBuilder waitQueueTimeoutMS(Integer waitQueueTimeoutMS)
      Specifies the maximum amount of time, in milliseconds that a thread may wait for a connection to become available. Default: 120000 (120 seconds). The option is a: java.lang.Integer type. Default: 120000 Group: advanced
      Parameters:
      waitQueueTimeoutMS - the value to set
      Returns:
      the dsl builder
    • waitQueueTimeoutMS

      default MongoDbEndpointBuilderFactory.AdvancedMongoDbEndpointProducerBuilder waitQueueTimeoutMS(String waitQueueTimeoutMS)
      Specifies the maximum amount of time, in milliseconds that a thread may wait for a connection to become available. Default: 120000 (120 seconds). The option will be converted to a java.lang.Integer type. Default: 120000 Group: advanced
      Parameters:
      waitQueueTimeoutMS - the value to set
      Returns:
      the dsl builder
    • writeConcern

      Configure the connection bean with the level of acknowledgment requested from MongoDB for write operations to a standalone mongod, replicaset or cluster. Possible values are ACKNOWLEDGED, W1, W2, W3, UNACKNOWLEDGED, JOURNALED or MAJORITY. The option is a: java.lang.String type. Default: ACKNOWLEDGED Group: advanced
      Parameters:
      writeConcern - the value to set
      Returns:
      the dsl builder
    • writeResultAsHeader

      default MongoDbEndpointBuilderFactory.AdvancedMongoDbEndpointProducerBuilder writeResultAsHeader(boolean writeResultAsHeader)
      In write operations, it determines whether instead of returning WriteResult as the body of the OUT message, we transfer the IN message to the OUT and attach the WriteResult as a header. The option is a: boolean type. Default: false Group: advanced
      Parameters:
      writeResultAsHeader - the value to set
      Returns:
      the dsl builder
    • writeResultAsHeader

      default MongoDbEndpointBuilderFactory.AdvancedMongoDbEndpointProducerBuilder writeResultAsHeader(String writeResultAsHeader)
      In write operations, it determines whether instead of returning WriteResult as the body of the OUT message, we transfer the IN message to the OUT and attach the WriteResult as a header. The option will be converted to a boolean type. Default: false Group: advanced
      Parameters:
      writeResultAsHeader - the value to set
      Returns:
      the dsl builder
    • zlibCompressionLevel

      default MongoDbEndpointBuilderFactory.AdvancedMongoDbEndpointProducerBuilder zlibCompressionLevel(Integer zlibCompressionLevel)
      Specifies the degree of compression that Zlib should use to decrease the size of requests to the connected MongoDB instance. The level can range from -1 to 9, with lower values compressing faster (but resulting in larger requests) and larger values compressing slower (but resulting in smaller requests). Default: null. The option is a: java.lang.Integer type. Group: advanced
      Parameters:
      zlibCompressionLevel - the value to set
      Returns:
      the dsl builder
    • zlibCompressionLevel

      default MongoDbEndpointBuilderFactory.AdvancedMongoDbEndpointProducerBuilder zlibCompressionLevel(String zlibCompressionLevel)
      Specifies the degree of compression that Zlib should use to decrease the size of requests to the connected MongoDB instance. The level can range from -1 to 9, with lower values compressing faster (but resulting in larger requests) and larger values compressing slower (but resulting in smaller requests). Default: null. The option will be converted to a java.lang.Integer type. Group: advanced
      Parameters:
      zlibCompressionLevel - the value to set
      Returns:
      the dsl builder