Methods Summary |
---|
protected java.util.Set | findAllOldCandidates()
ObjectName pattern = null;
Set<ObjectName> oldNames = null;
pattern = Util.newObjectNamePattern( "com.sun.appserv", "category=config" );
oldNames = JMXUtil.queryNames( getMBeanServer(), pattern, null );
oldNames.addAll( getOldServerConfigObjectNames() );
debug( "LoaderOfOldConfig: found the following:" );
debug( CollectionUtil.toString( oldNames, "\n" ) );
return( oldNames );
|
protected java.util.Set | getIgnoreTypes()
return( OldConfigTypes.getIgnoreTypes() );
|
private javax.management.ObjectName | getListenToServerRefConfigPattern()
final String jmxDomain = Util.getObjectName( getDomainRoot() ).getDomain();
final String props = Util.makeJ2EETypeProp( XTypes.SERVER_REF_CONFIG );
return Util.newObjectNamePattern( jmxDomain, props );
|
protected java.util.Set | getNeedsSupport()
return( NEEDS_SUPPORT );
|
private java.util.Set | getOldServerConfigObjectNames()
// 8.0 put the type=server MBeans into ias:
// see if they are present under com.sun.appserv
//
ObjectName pattern =
Util.newObjectNamePattern( "com.sun.appserv", "type=server" );
Set<ObjectName> objectNames = JMXUtil.queryNames( getMBeanServer(), pattern, null );
if ( objectNames.size() == 0 )
{
pattern = Util.newObjectNamePattern( "ias", "type=server" );
objectNames = JMXUtil.queryNames( getMBeanServer(), pattern, null );
}
return( objectNames );
|
private boolean | isOldConfigMBean(javax.management.ObjectName objectName)
boolean isOldConfigMBean = false;
if ( objectName.getDomain().equals( "com.sun.appserv" ) &&
"config".equals( objectName.getKeyProperty( "category" ) ) )
{
final String type = objectName.getKeyProperty( "type" );
isOldConfigMBean = ! OldConfigTypes.getIgnoreTypes().contains( type );
}
return( isOldConfigMBean );
|
protected boolean | isOldMBean(javax.management.ObjectName objectName)
return( isOldConfigMBean( objectName ) );
|
protected javax.management.ObjectName | oldToNewObjectName(javax.management.ObjectName oldObjectName)
trace( "oldToNewObjectName: " + oldObjectName );
final OldTypeToJ2EETypeMapper mapper = new MyOldTypes( );
final OldProps oldProps = new OldProps( oldObjectName, mapper );
final String domainName = mLoader.getAMXJMXDomainName();
String props = oldProps.getNewProps();
// may be modified down below
final ObjectName newObjectName = Util.newObjectName( domainName, props );
return( newObjectName );
|