Methods Summary |
---|
private final java.lang.String | deduceModuleName()
// get the last part of the workDir; it should be the actual module name
final String workDir = getSelfProxy().getWorkDir();
final int index1 = workDir.lastIndexOf( "/" );
final int index2 = workDir.lastIndexOf( "\\" );
final int index = index1 > index2 ? index1 : index2;
String result = null;
if (index > 0 )
{
result = workDir.substring( index + 1, workDir.length() );
}
return( result );
|
protected java.lang.String | getConfigPeerName()MBeans of type j2eeType=WebModule have their virtual server prepended
to their name. For example, if the virtual server is "__asadmin", the
name will start with "//__asadmin/".
final String compositeName = getName();
final String webModuleName = WebModuleSupport.extractWebModuleName( compositeName );
return( webModuleName );
|
protected java.lang.String | getMonitoringPeerJ2EEType()
return( XTypes.WEB_MODULE_VIRTUAL_SERVER_MONITOR );
|
protected com.sun.appserv.management.j2ee.WebModule | getSelfProxy()
return (WebModule)getSelf();
|
public java.util.Map | getServletObjectNameMap()
return( getContaineeObjectNameMap( J2EETypes.SERVLET ) );
|
public java.lang.String[] | getservlets()
final Map<String,Servlet> servlets = getSelfProxy().getServletMap();
return( CollectionUtil.toStringArray( Util.toObjectNames( servlets ).values() ) );
|
public boolean | isConfigProvider()
boolean isConfigProvider = super.isConfigProvider();
if ( super.isConfigProvider() && getObjectName() != null )
{
final String name = getConfigPeerName();
/*
Ugly hack for our System WebModules.
// context root is being used instead of module name
*/
if ( name.length() == 0 || name.equals( "asadmin" ) ||
name.equals( "web1" ) )
{
isConfigProvider = false;
}
}
return( isConfigProvider );
|
protected javax.management.ObjectName | queryConfigPeerFailed(java.util.Map propsMap)
final String potentialName = deduceModuleName();
propsMap.put( AMX.NAME_KEY, potentialName );
final ObjectName result = queryProps( propsMap );
return( result );
|
protected javax.management.ObjectName | queryMonitoringPeerFailed(java.util.Map propsMap)
final String selfName = getName();
final String virtualServerName = WebModuleSupport.extractVirtualServerName( selfName );
ObjectName result = null;
final String potentialName = deduceModuleName();
if ( potentialName != null )
{
final String name = WebModuleSupport.formCompositeName( virtualServerName, potentialName );
propsMap.put( AMX.NAME_KEY, name );
result = queryProps( propsMap );
}
return result;
|