Package com.mongodb.connection
Class ServerSettings
- java.lang.Object
-
- com.mongodb.connection.ServerSettings
-
@Immutable @Deprecated(since="2021-05-27") public class ServerSettings extends java.lang.Object
Deprecated.Usage of this API is not supported in AEM as a Cloud Service.Settings relating to monitoring of each server.- Since:
- 3.0
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ServerSettings.Builder
Deprecated.Usage of this API is not supported in AEM as a Cloud Service.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static ServerSettings.Builder
builder()
Deprecated.Creates a builder for ServerSettings.static ServerSettings.Builder
builder(ServerSettings serverSettings)
Deprecated.Creates a builder instance.boolean
equals(java.lang.Object o)
Deprecated.long
getHeartbeatFrequency(java.util.concurrent.TimeUnit timeUnit)
Deprecated.Gets the frequency that the cluster monitor attempts to reach each server.long
getMinHeartbeatFrequency(java.util.concurrent.TimeUnit timeUnit)
Deprecated.Gets the minimum heartbeat frequency.java.util.List<ServerListener>
getServerListeners()
Deprecated.Gets the server listeners.java.util.List<ServerMonitorListener>
getServerMonitorListeners()
Deprecated.Gets the server monitor listeners.int
hashCode()
Deprecated.java.lang.String
toString()
Deprecated.
-
-
-
Method Detail
-
builder
public static ServerSettings.Builder builder()
Deprecated.Creates a builder for ServerSettings.- Returns:
- a new Builder for creating ServerSettings.
-
builder
public static ServerSettings.Builder builder(ServerSettings serverSettings)
Deprecated.Creates a builder instance.- Parameters:
serverSettings
- existing ServerSettings to default the builder settings on.- Returns:
- a builder
- Since:
- 3.5
-
getHeartbeatFrequency
public long getHeartbeatFrequency(java.util.concurrent.TimeUnit timeUnit)
Deprecated.Gets the frequency that the cluster monitor attempts to reach each server. The default value is 10 seconds.- Parameters:
timeUnit
- the time unit- Returns:
- the heartbeat frequency
-
getMinHeartbeatFrequency
public long getMinHeartbeatFrequency(java.util.concurrent.TimeUnit timeUnit)
Deprecated.Gets the minimum heartbeat frequency. In the event that the driver has to frequently re-check a server's availability, it will wait at least this long since the previous check to avoid wasted effort. The default value is 500 milliseconds.- Parameters:
timeUnit
- the time unit- Returns:
- the heartbeat reconnect retry frequency
-
getServerListeners
public java.util.List<ServerListener> getServerListeners()
Deprecated.Gets the server listeners. The default value is an empty list.- Returns:
- the server listeners
- Since:
- 3.3
-
getServerMonitorListeners
public java.util.List<ServerMonitorListener> getServerMonitorListeners()
Deprecated.Gets the server monitor listeners. The default value is an empty list.- Returns:
- the server monitor listeners
- Since:
- 3.3
-
equals
public boolean equals(java.lang.Object o)
Deprecated.- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
Deprecated.- Overrides:
hashCode
in classjava.lang.Object
-
toString
public java.lang.String toString()
Deprecated.- Overrides:
toString
in classjava.lang.Object
-
-