Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.jboss.system.server
Class ServerInfo

    java.lang.Object
      org.jboss.system.server.ServerInfo

All Implemented Interfaces:
  javax.management.MBeanRegistration, ServerInfoMBean

public class ServerInfo
extends Object
implements ServerInfoMBean, javax.management.MBeanRegistration

An MBean that provides a rich view of system information for the JBoss server in which it is deployed.

Version:
  $Revision: 1.12 $
Author:
  Rickard �berg, Scott Stark, Hiram Chirino, Jason Dillon, Marc Fleury

Field Summary
`static javax.management.ObjectName` | `DEFAULT_LOADER_REPOSITORY`

Fields inherited from interface org.jboss.system.server.ServerInfoMBean
`OBJECT_NAME`

Constructor Summary
`ServerInfo()`

Method Summary
`String` | `displayAllPackageInfo()` This does not work as expected because the thread context class loader is not used to determine which class loader the package list is obtained from.
`String` | `displayInfoForClass(String className)` Display the ClassLoader, ProtectionDomain and Package information for the specified class.
`String` | `displayPackageInfo(String pkgName)` Display the java.lang.Package info for the pkgName
`Integer` | `getActiveThreadCount()`
`Integer` | `getActiveThreadGroupCount()`
`Integer` | `getAvailableProcessors()` Returns `Runtime.getRuntime().availableProcessors()` on JDK 1.4 vms or -1 on previous versions.
`Long` | `getFreeMemory()`
`String` | `getHostAddress()` Returns InetAddress.getLocalHost().getHostAddress();
`String` | `getHostName()` Returns InetAddress.getLocalHost().getHostName();
`String` | `getJavaVendor()`
`String` | `getJavaVersion()`
`String` | `getJavaVMName()`
`String` | `getJavaVMVendor()`
`String` | `getJavaVMVersion()`
`Long` | `getMaxMemory()` Returns `Runtime.getRuntime().maxMemory()`on JDK 1.4 vms or -1 on previous versions.``
`String` | `getOSArch()`
`String` | `getOSName()`
`String` | `getOSVersion()`
`Long` | `getTotalMemory()`
`String` | `listThreadDump()` Return a listing of the active threads and thread groups.
`void` | `postDeregister()`
`void` | `postRegister(Boolean registrationDone)`
`void` | `preDeregister()`
`javax.management.ObjectName` | `preRegister(javax.management.MBeanServer server, javax.management.ObjectName name)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### DEFAULT_LOADER_REPOSITORY

    public static final javax.management.ObjectName DEFAULT_LOADER_REPOSITORY

Constructor Detail

### ServerInfo

    public ServerInfo()

Method Detail

### preRegister

    public javax.management.ObjectName preRegister(javax.management.MBeanServer server,
                                                   javax.management.ObjectName name)
                                            throws Exception

  Specified by:
    `preRegister` in interface `javax.management.MBeanRegistration`
  Throws:
    `Exception`

### postRegister

    public void postRegister(Boolean registrationDone)

  Specified by:
    `postRegister` in interface `javax.management.MBeanRegistration`

### preDeregister

    public void preDeregister()
                       throws Exception

  Specified by:
    `preDeregister` in interface `javax.management.MBeanRegistration`
  Throws:
    `Exception`

### postDeregister

    public void postDeregister()

  Specified by:
    `postDeregister` in interface `javax.management.MBeanRegistration`

### getJavaVersion

    public String getJavaVersion()

  Specified by:
    `getJavaVersion` in interface `ServerInfoMBean`

### getJavaVendor

    public String getJavaVendor()

  Specified by:
    `getJavaVendor` in interface `ServerInfoMBean`

### getJavaVMName

    public String getJavaVMName()

  Specified by:
    `getJavaVMName` in interface `ServerInfoMBean`

### getJavaVMVersion

    public String getJavaVMVersion()

  Specified by:
    `getJavaVMVersion` in interface `ServerInfoMBean`

### getJavaVMVendor

    public String getJavaVMVendor()

  Specified by:
    `getJavaVMVendor` in interface `ServerInfoMBean`

### getOSName

    public String getOSName()

  Specified by:
    `getOSName` in interface `ServerInfoMBean`

### getOSVersion

    public String getOSVersion()

  Specified by:
    `getOSVersion` in interface `ServerInfoMBean`

### getOSArch

    public String getOSArch()

  Specified by:
    `getOSArch` in interface `ServerInfoMBean`

### getTotalMemory

    public Long getTotalMemory()

  Specified by:
    `getTotalMemory` in interface `ServerInfoMBean`

### getFreeMemory

    public Long getFreeMemory()

  Specified by:
    `getFreeMemory` in interface `ServerInfoMBean`

### getMaxMemory

    public Long getMaxMemory()

  Returns `Runtime.getRuntime().maxMemory()`on JDK 1.4 vms or -1 on previous versions.

  ``
  Specified by:
    `getMaxMemory` in interface `ServerInfoMBean`

### getAvailableProcessors

    public Integer getAvailableProcessors()

  Returns `Runtime.getRuntime().availableProcessors()` on JDK 1.4 vms or -1 on previous versions.

  Specified by:
    `getAvailableProcessors` in interface `ServerInfoMBean`

### getHostName

    public String getHostName()

  Returns InetAddress.getLocalHost().getHostName();

  Specified by:
    `getHostName` in interface `ServerInfoMBean`

### getHostAddress

    public String getHostAddress()

  Returns InetAddress.getLocalHost().getHostAddress();

  Specified by:
    `getHostAddress` in interface `ServerInfoMBean`

### getActiveThreadCount

    public Integer getActiveThreadCount()

  Specified by:
    `getActiveThreadCount` in interface `ServerInfoMBean`

### getActiveThreadGroupCount

    public Integer getActiveThreadGroupCount()

  Specified by:
    `getActiveThreadGroupCount` in interface `ServerInfoMBean`

### listThreadDump

    public String listThreadDump()

  Return a listing of the active threads and thread groups.

  Specified by:
    `listThreadDump` in interface `ServerInfoMBean`

### displayPackageInfo

    public String displayPackageInfo(String pkgName)

  Display the java.lang.Package info for the pkgName

  Specified by:
    `displayPackageInfo` in interface `ServerInfoMBean`

### displayInfoForClass

    public String displayInfoForClass(String className)
                               throws Exception

  Display the ClassLoader, ProtectionDomain and Package information for the specified class.

  Specified by:
    `displayInfoForClass` in interface `ServerInfoMBean`
  Returns:
    a simple html report of this information
  Throws:
    `Exception`

### displayAllPackageInfo

    public String displayAllPackageInfo()

  This does not work as expected because the thread context class loader is not used to determine which class loader the package list is obtained from.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2002 JBoss Group, LLC. All Rights Reserved.