![]() |
Open Kilda Java Documentation
|
Public Member Functions | |
DiscoveryLink (SwitchId srcSwitch, int srcPort, int checkInterval, int consecutiveFailureLimit) | |
DiscoveryLink (SwitchId srcSwitch, int srcPort, SwitchId dstSwitch, int dstPort, int checkInterval, int consecutiveFailureLimit, boolean active) | |
DiscoveryLink (@JsonProperty("source") final NetworkEndpoint source, @JsonProperty("destination") final NetworkEndpoint destination, @JsonProperty("attempts") final int attempts, @JsonProperty("ack_attempts") final int ackAttempts, @JsonProperty("time_counter") final int timeCounter, @JsonProperty("check_interval") final int checkInterval, @JsonProperty("consecutive_failure") final int consecutiveFailure, @JsonProperty("consecutive_success") final int consecutiveSuccess, @JsonProperty("consecutive_failure_limit") final int consecutiveFailureLimit, @JsonProperty("active") final boolean active) | |
void | activate (NetworkEndpoint destination) |
void | deactivate () |
void | renew () |
boolean | isNewAttemptAllowed () |
void | clearConsecutiveFailure () |
void | clearConsecutiveSuccess () |
void | fail () |
void | success () |
void | tick () |
void | resetTickCounter () |
boolean | isAttemptsLimitExceeded (int attemptsLimit) |
void | incAttempts () |
boolean | isAckAttemptsLimitExceeded (int attemptsLimit) |
void | incAcknowledgedAttempts () |
boolean | timeToCheck () |
boolean | isDestinationChanged (SwitchId dstSwitch, int dstPort) |
boolean | equals (Object o) |
int | hashCode () |
Static Public Attributes | |
static final int | ENDLESS_ATTEMPTS = -1 |
Definition at line 32 of file DiscoveryLink.java.
org.openkilda.messaging.model.DiscoveryLink.DiscoveryLink | ( | SwitchId | srcSwitch, |
int | srcPort, | ||
int | checkInterval, | ||
int | consecutiveFailureLimit | ||
) |
Constructor with non-defined destination of the ISL.
Definition at line 81 of file DiscoveryLink.java.
org.openkilda.messaging.model.DiscoveryLink.DiscoveryLink | ( | SwitchId | srcSwitch, |
int | srcPort, | ||
SwitchId | dstSwitch, | ||
int | dstPort, | ||
int | checkInterval, | ||
int | consecutiveFailureLimit, | ||
boolean | active | ||
) |
Constructor with defined destination of the ISL.
Definition at line 94 of file DiscoveryLink.java.
org.openkilda.messaging.model.DiscoveryLink.DiscoveryLink | ( | @JsonProperty("source") final NetworkEndpoint | source, |
@JsonProperty("destination") final NetworkEndpoint | destination, | ||
@JsonProperty("attempts") final int | attempts, | ||
@JsonProperty("ack_attempts") final int | ackAttempts, | ||
@JsonProperty("time_counter") final int | timeCounter, | ||
@JsonProperty("check_interval") final int | checkInterval, | ||
@JsonProperty("consecutive_failure") final int | consecutiveFailure, | ||
@JsonProperty("consecutive_success") final int | consecutiveSuccess, | ||
@JsonProperty("consecutive_failure_limit") final int | consecutiveFailureLimit, | ||
@JsonProperty("active") final boolean | active | ||
) |
Main constructor for deserialization by jackson.
Definition at line 110 of file DiscoveryLink.java.
void org.openkilda.messaging.model.DiscoveryLink.activate | ( | NetworkEndpoint | destination | ) |
Activate the ISL.
Definition at line 135 of file DiscoveryLink.java.
void org.openkilda.messaging.model.DiscoveryLink.clearConsecutiveFailure | ( | ) |
Definition at line 172 of file DiscoveryLink.java.
void org.openkilda.messaging.model.DiscoveryLink.clearConsecutiveSuccess | ( | ) |
Definition at line 176 of file DiscoveryLink.java.
void org.openkilda.messaging.model.DiscoveryLink.deactivate | ( | ) |
Deactivating of an ISL. We do not remove the destination of the ISL, because such data helps us to define whether ISL is moved or not.
Definition at line 144 of file DiscoveryLink.java.
boolean org.openkilda.messaging.model.DiscoveryLink.equals | ( | Object | o | ) |
Definition at line 247 of file DiscoveryLink.java.
void org.openkilda.messaging.model.DiscoveryLink.fail | ( | ) |
Definition at line 180 of file DiscoveryLink.java.
int org.openkilda.messaging.model.DiscoveryLink.hashCode | ( | ) |
Definition at line 260 of file DiscoveryLink.java.
void org.openkilda.messaging.model.DiscoveryLink.incAcknowledgedAttempts | ( | ) |
Increases amount of acknowledged attempts.
Definition at line 223 of file DiscoveryLink.java.
void org.openkilda.messaging.model.DiscoveryLink.incAttempts | ( | ) |
Increases amount of attempts.
Definition at line 208 of file DiscoveryLink.java.
boolean org.openkilda.messaging.model.DiscoveryLink.isAckAttemptsLimitExceeded | ( | int | attemptsLimit | ) |
Checks if we should stop trying to discover isl, because of the limit of attempts.
Definition at line 216 of file DiscoveryLink.java.
boolean org.openkilda.messaging.model.DiscoveryLink.isAttemptsLimitExceeded | ( | int | attemptsLimit | ) |
Checks if limit of not acknowledged attempts is exceeded.
Definition at line 201 of file DiscoveryLink.java.
boolean org.openkilda.messaging.model.DiscoveryLink.isDestinationChanged | ( | SwitchId | dstSwitch, |
int | dstPort | ||
) |
Checks whether destination switch/port of that link differs.
dstSwitch | destination switch. |
dstPort | destination port. |
Definition at line 237 of file DiscoveryLink.java.
boolean org.openkilda.messaging.model.DiscoveryLink.isNewAttemptAllowed | ( | ) |
Checks if discovery should be suspended for that link or we can try to discover it.
Definition at line 165 of file DiscoveryLink.java.
void org.openkilda.messaging.model.DiscoveryLink.renew | ( | ) |
Whereas renew is called when a successful Discovery is received, it isn't the place to put "foundIsl". This is out of fear that renew() could be called from somewhere else. The semantics of "renew" doesn't say "found ISL"
Definition at line 155 of file DiscoveryLink.java.
void org.openkilda.messaging.model.DiscoveryLink.resetTickCounter | ( | ) |
Definition at line 193 of file DiscoveryLink.java.
void org.openkilda.messaging.model.DiscoveryLink.success | ( | ) |
Definition at line 185 of file DiscoveryLink.java.
void org.openkilda.messaging.model.DiscoveryLink.tick | ( | ) |
Definition at line 189 of file DiscoveryLink.java.
boolean org.openkilda.messaging.model.DiscoveryLink.timeToCheck | ( | ) |
Definition at line 227 of file DiscoveryLink.java.
|
static |
Means to never stop to check even failed ISL.
Definition at line 37 of file DiscoveryLink.java.