Top Description Methods
org.springframework.messaging.tcp

public Interface ReconnectStrategy

Known Direct Implementers
org.springframework.messaging.tcp.FixedIntervalReconnectStrategy
Annotations
@FunctionalInterface
Imports
org.springframework.lang.Nullable

A contract to determine the frequency of reconnect attempts after connection failure.
Author
Rossen Stoyanchev
Since
4.0

Method Summary

Modifier and TypeMethod and Description
public Long

Returns:

the amount of time in milliseconds, or null to stop
getTimeToNextAttempt
(int
how many reconnect attempts have been made already
attemptCount
)

Return the time to the next attempt to reconnect.

Method Detail

getTimeToNextAttemptback to summary
public Long getTimeToNextAttempt(int attemptCount)

Return the time to the next attempt to reconnect.

Parameters
attemptCount:int

how many reconnect attempts have been made already

Returns:Long

the amount of time in milliseconds, or null to stop

Annotations
@Nullable