Skip to content
Snippets Groups Projects
Commit 06ff592b authored by abat's avatar abat
Browse files

Merge into master from pull request #301:

parents eaebf504 5cedf45a
No related branches found
No related tags found
No related merge requests found
......@@ -368,14 +368,23 @@ public class Forwarding extends ForwardingBase implements IFloodlightModule {
// read our config options
Map<String, String> configOptions = context.getConfigParams(this);
String idleTimeout = configOptions.get("idletimeout");
if (idleTimeout != null) {
FLOWMOD_DEFAULT_IDLE_TIMEOUT = Short.parseShort(idleTimeout);
try {
String idleTimeout = configOptions.get("idletimeout");
if (idleTimeout != null) {
FLOWMOD_DEFAULT_IDLE_TIMEOUT = Short.parseShort(idleTimeout);
}
} catch (NumberFormatException e) {
log.warn("Error parsing flow idle timeout, using default of {} seconds",
FLOWMOD_DEFAULT_IDLE_TIMEOUT);
}
String hardTimeout = configOptions.get("hardtimeout");
if (hardTimeout != null) {
FLOWMOD_DEFAULT_HARD_TIMEOUT = Short.parseShort(hardTimeout);
try {
String hardTimeout = configOptions.get("hardtimeout");
if (hardTimeout != null) {
FLOWMOD_DEFAULT_HARD_TIMEOUT = Short.parseShort(hardTimeout);
}
} catch (NumberFormatException e) {
log.warn("Error parsing flow hard timeout, using default of {} seconds",
FLOWMOD_DEFAULT_HARD_TIMEOUT);
}
log.debug("FlowMod idle timeout set to {} seconds", FLOWMOD_DEFAULT_IDLE_TIMEOUT);
log.debug("FlowMod hard timeout set to {} seconds", FLOWMOD_DEFAULT_HARD_TIMEOUT);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment