wt.federation
Class ConfigExaminer

java.lang.Object
  extended bywt.federation.ConfigExaminer

public class ConfigExaminer
extends Object

This class examines the Federation configuration and reports what it discovers. It also detects and reports errors and anomolies.


Field Summary
private  WTProperties properties
           
private  String provider
           
private  Hashtable repositoryTypes
           
private  String searchBase
           
private static String SEPARATOR1
           
private static String SEPARATOR2
           
private  String VMName
           
 
Constructor Summary
ConfigExaminer()
          Constructor.
 
Method Summary
private  void examineActions(String objectTypeDn)
          Examine and report actions defined for an object type
private  void examineLDAPServices()
          Examine and report LDAP service configuration.
private  void examineNamingService()
          Examine and report naming service configuration.
private  void examineObjectTypes(String repositoryType)
          Examine and report object types defined for a repository type
private  void examineRepositories()
          Examine and report repositories
private  void examineRepositoryTypes()
          Examine and report repository types
private  void examineTaskConfiguration()
          Examine and report task configuration.
private  void examineWindchillService()
          Examine Windchill service configuration.
private  void examineWindchillURLs()
          Examine and report Windchill URLs
private  void examineWtProperties()
          Examine essential properties defined in wt.properties
static void main(String[] args)
          Main method.
private  String normalizeDn(String dn)
          Removes extraneous whitespace from distinguished names.
private  void printTitle(String title)
          Print a title for a section of the report.
private  Group queryDirectory(String url)
          Queries the LDAP directory and catches any exceptions thrown.
 void run()
          Examine the configuration and report what is discovered.
private  void verifyDn(String dn, String failureMessage)
          Verifies that a string is a valid distinguished name that references a directory entry that can be read.
private  void verifyURL(String url, boolean authenticated)
          Verifies that a URL is accessible and that it's authentication requirements are correct.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

properties

private WTProperties properties

provider

private String provider

repositoryTypes

private Hashtable repositoryTypes

searchBase

private String searchBase

VMName

private String VMName

SEPARATOR1

private static final String SEPARATOR1
See Also:
Constant Field Values

SEPARATOR2

private static final String SEPARATOR2
See Also:
Constant Field Values
Constructor Detail

ConfigExaminer

public ConfigExaminer()
Constructor.

Method Detail

run

public void run()
         throws WTException
Examine the configuration and report what is discovered.

Throws:
WTException

examineWtProperties

private void examineWtProperties()
                          throws WTException
Examine essential properties defined in wt.properties

Throws:
WTException

examineNamingService

private void examineNamingService()
                           throws WTException
Examine and report naming service configuration.

Throws:
WTException

examineWindchillService

private void examineWindchillService()
                              throws WTException
Examine Windchill service configuration.

Throws:
WTException

examineTaskConfiguration

private void examineTaskConfiguration()
                               throws WTException
Examine and report task configuration.

Throws:
WTException

examineWindchillURLs

private void examineWindchillURLs()
                           throws WTException
Examine and report Windchill URLs

Throws:
WTException

examineLDAPServices

private void examineLDAPServices()
                          throws WTException
Examine and report LDAP service configuration.

Throws:
WTException

examineRepositoryTypes

private void examineRepositoryTypes()
                             throws WTException
Examine and report repository types

Throws:
WTException

examineRepositories

private void examineRepositories()
                          throws WTException
Examine and report repositories

Throws:
WTException

examineObjectTypes

private void examineObjectTypes(String repositoryType)
                         throws WTException
Examine and report object types defined for a repository type

Throws:
WTException

examineActions

private void examineActions(String objectTypeDn)
                     throws WTException
Examine and report actions defined for an object type

Throws:
WTException

queryDirectory

private Group queryDirectory(String url)
Queries the LDAP directory and catches any exceptions thrown.

Parameters:
url - The LDAP URL to dereference.
Returns:
The query result, or null if an exception prevents the query from succeeding.

verifyDn

private void verifyDn(String dn,
                      String failureMessage)
Verifies that a string is a valid distinguished name that references a directory entry that can be read.

Parameters:
dn - The distinguished name to verify.
failureMessage - The message to print if verification fails.

verifyURL

private void verifyURL(String url,
                       boolean authenticated)
Verifies that a URL is accessible and that it's authentication requirements are correct.

Parameters:
url - The URL to verify.
authenticated - true if the URL should challenge for authentication

normalizeDn

private String normalizeDn(String dn)
Removes extraneous whitespace from distinguished names.

Parameters:
dn - The distinguished name to normalize.
Returns:
The normalized result.

printTitle

private void printTitle(String title)
Print a title for a section of the report.

Parameters:
title - The title string

main

public static void main(String[] args)
Main method.