SFOConfigValidator.java revision d97b7ab26c446ed6c58b71c45249970c62f876f8
/*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
*
* Copyright (c) 2008 Sun Microsystems Inc. All Rights Reserved
*
* The contents of this file are subject to the terms
* of the Common Development and Distribution License
* (the License). You may not use this file except in
* compliance with the License.
*
* You can obtain a copy of the License at
* See the License for the specific language governing
* permission and limitations under the License.
*
* When distributing Covered Code, include this CDDL
* Header Notice in each file and include the License file
* at opensso/legal/CDDLv1.0.txt.
* If applicable, add the following below the CDDL Header,
* with the fields enclosed by brackets [] replaced by
* your own identifying information:
* "Portions Copyrighted [year] [name of copyright owner]"
*
* $Id: SFOConfigValidator.java,v 1.1 2008/11/22 02:41:22 ak138937 Exp $
*
* Portions Copyright 2013-2015 ForgeRock AS.
*/
/**
* This is a supporting class to validate the Session Failover
* configuration properties.
*/
public class SFOConfigValidator extends ServerConfigBase {
private IToolOutput toolOutWriter;
public SFOConfigValidator() {
}
/**
* Validate the configuration.
*/
if (loadConfig(path)) {
ssoToken = getAdminSSOToken();
} else {
}
} else {
}
}
boolean loaded = false;
try {
loaded = true;
}
} catch (Exception e) {
}
return loaded;
}
boolean isSessionFailoverEnabled = false;
int minPoolSize = 8;
int maxPoolSize = 32;
boolean isPropertyNotificationEnabled = false;
try {
).booleanValue();
if (sfoEnabled) {
isSessionFailoverEnabled = true;
} else {
}
} else {
}
"SFOConfigValidator.processSFO: " +
"Exception in validating sfo configuration " +
"information", ex);
}
}
boolean valid = true;
new String[] {sessionRepositoryURL});
valid = false;
} else {
}
}
if (valid) {
while (st.hasMoreTokens()) {
if (isValidSyntax(str)) {
toolOutWriter.printStatusMsg(true,
"sfo-validate-jdbc-url");
} else {
toolOutWriter.printStatusMsg(false,
"sfo-validate-jdbc-url");
}
}
}
}
} else {
}
}
boolean valid = false;
} else {
if (!isValidHost(host)) {
} else {
valid = true;
}
if (!isValidPort(port)){
valid = false;
} else {
valid &= true;
}
}
return valid;
}
private String getSessionServerURL() {
boolean isSiteEnabled = false;
try {
if (isSiteEnabled) {
} else {
}
"SFOConfigValidator.getSessionServerURL: " +
"Exception in getting Session server URL", ex);
}
return sessionServiceID.toString();
}
}