Ice.ACM.*

On this page:

Ice.ACM.Close

Synopsis

Ice.ACM.Close=num

Description

This property determines when Active Connection Management (ACM) closes a connection. Legal values for num correspond directly to the ACMClose enumerators found in Connection.ice:

Slice
local enum ACMClose
{
    CloseOff,
    CloseOnIdle,
    CloseOnInvocation,
    CloseOnInvocationAndIdle,
    CloseOnIdleForceful
}

The table below describes the semantics of each value:

EnumeratorProperty ValueDescription
CloseOff0ACM does not close the connection. A connection is closed when the communicator is destroyed, when there's a network failure or when the peer closes it.
CloseOnIdle1ACM closes the connection gracefully when this connection remains idle for Timeout (or longer) and has no outstanding invocation or dispatch.
CloseOnInvocation2

ACM closes the connection forcefully when this connection remains idle for Timeout (or longer), has no outstanding dispatch and has at least one outstanding invocation.

This setting is useful when you don't want ACM to close unused connections but still want ACM to close forcefully a connection when invocations are in progress but no messages are received from the peer, potentially indicating that the peer is dead. This setting should be used with a Heartbeat configuration where heartbeats are sent at regular intervals by the peer while a request is being dispatched (such as HeartbeatOnDispatch, HeartbeatOnIdle or HeartbeatAlways). Hearbeats prevent a connection from remaining idle; not receiving heartbeats from the peer indicates a problem with the peer or the connection.

CloseOnInvocationAndIdle3Combines the behaviors of CloseOnIdle and CloseOnInvocation. ACM closes a connection gracefully if it remains idle for Timeout (or longer) and has no outstanding invocation and dispatch (CloseOnIdle). ACM closes a connection forcefully if it remains idle for Timeout (or longer) and has one or more outstanding invocation but no outstanding dispatch (CloseOnInvocation).
CloseOnIdleForceful4ACM closes a connection when it remains idle for Timeout (or longer), regardless of pending invocations and dispatches.

You must set a non-zero value for Ice.ACM.Timeout for this property to have any effect. Use Ice.ACM.Close in conjunction with Ice.ACM.Heartbeat to tailor a connection management policy for your application. Use the corresponding Ice.ACM.Client.Close or Ice.ACM.Server.Close properties to override this setting in a client or server context, respectively. See Connection Closure for more information on closing connections.

If not defined, the default value is 3 for a client connection and 2 for a server connection.

Ice.ACM.Heartbeat

Synopsis

Ice.ACM.Heartbeat=num

Description

This property determines whether heartbeats are enabled. You can use heartbeats in conjunction with the Ice.ACM.Close and Ice.ACM.Timeout properties to create a connection management policy as part of Active Connection Management (ACM). Legal values for num correspond directly to the ACMHeartbeat enumerators found in Connection.ice:

Slice
local enum ACMHeartbeat
{
    HeartbeatOff,
    HeartbeatOnDispatch,
    HeartbeatOnIdle,
    HeartbeatAlways
}

The table below describes the semantics of each value:

EnumeratorProperty ValueDescription
HeartbeatOff0Disable heartbeats.
HeartbeatOnDispatch1

When there is a pending dispatch and no data is sent or received over the connection, send heartbeats at regular intervals to prevent the connection from remaining idle.

This is useful if you don't want to send heartbeats to keep the connection alive but still want ACM to notify the peer that the connection is alive while a dispatch is in progress.

HeartbeatOnIdle2

When no data is sent or received over the connection, send heartbeats at regular intervals to prevent the connection from remaining idle.

For example, if the application steadily reads data from a connection, the connection is not at risk from remaining idle and ACM does not send any heartbeat.

HeartbeatAlways3

Send heartbeats at regular intervals until the connection is closed. Messages sent or received by the application on this connection don't cancel these heartbeats.

You must set a non-zero value for Ice.ACM.Timeout for this property to have any effect. Use the corresponding Ice.ACM.Client.Heartbeat or Ice.ACM.Server.Heartbeat properties to override this setting in a client or server context, respectively.

To send a heartbeat, ACM sends a validate connection message to the remote end. Heartbeats are not supported on datagram connections.

If not defined, the default value is 1.

Ice.ACM.Timeout

Synopsis

Ice.ACM.Timeout=num

Description

The value for num represents a timeout in seconds for Active Connection Management (ACM). The setting for Ice.ACM.Close determines when connections are automatically closed, and the setting for Ice.ACM.Heartbeat can be used to prevent connections from being closed prematurely. Use the corresponding Ice.ACM.Client.Timeout or Ice.ACM.Server.Timeout properties to override this setting in a client or server context, respectively. The value must be positive or 0. Setting the timeout to 0 disables ACM which is equivalent to setting CloseOff and HeartbeatOff for the close and heartbeat ACM settings respectively.

If not defined, the default value is 60.

Ice.ACM.Client.Close

Synopsis

Ice.ACM.Client.Close=num

Description

Overrides the value of Ice.ACM.Close for client connections.

Ice.ACM.Client.Heartbeat

Synopsis

Ice.ACM.Client.Heartbeat=num

Description

Overrides the value of Ice.ACM.Heartbeat for client connections.

Ice.ACM.Client.Timeout

Synopsis

Ice.ACM.Client.Timeout=num

Description

Overrides the value of Ice.ACM.Timeout for client connections.

Ice.ACM.Server.Close

Synopsis

Ice.ACM.Server.Close=num

Description

Overrides the value of Ice.ACM.Close for server connections.

Ice.ACM.Server.Heartbeat

Synopsis

Ice.ACM.Server.Heartbeat=num

Description

Overrides the value of Ice.ACM.Heartbeat for server connections.

Ice.ACM.Server.Timeout

Synopsis

Ice.ACM.Server.Timeout=num

Description

Overrides the value of Ice.ACM.Timeout for server connections.