BEA Systems, Inc.

WebLogic Server 6.1 API Reference

weblogic.management.configuration
Interface ApplicationMBean


public interface ApplicationMBean
extends ConfigurationMBean

An application represents a J2EE application contained in a EAR file or EAR directory. The EAR file contains a set of components such as WAR, EJB and JMS JAR components. These components might include EJBs, servlets, JMS destinations, or connector components.

An application represents the actual EAR file for this application.

Author:
Copyright © 2001 BEA Systems, Inc. All Rights Reserved.

Method Summary
 boolean addComponent(ComponentMBean component)
          Add a component to this application.
 void deploy()
           
 ComponentMBean[] getComponents()
          Returns the components that make up this application.
 long getLastModified()
          Returns the time when this application was last loaded.
 java.lang.Exception getLoadError()
          Return the error thrown the last attempt to call load or reload if any, null otherwise.
 java.lang.String getPath()
          Returns the path pointing to the application's EAR file.
 java.lang.String[] getStagedTargets()
          List of servers this application is known to be staged on.
 boolean isDeployed()
          Returns whether or not this application is deployed.
 void load()
          Intializes all the MBeans for an application,for any changes in the application descriptor to take into affect the load has to be called on the Application MBean before the application is deployed/redeployed.
 void load(boolean autoDiscover)
          Load or reload the application, automatically discovering components.
 boolean removeComponent(ComponentMBean component)
          Remove a component from this application.
 void setDeployed(boolean deployed)
          Deploy or undeploy the entire application.
 void setLastModified(long time)
           
 void setPath(java.lang.String path)
          Set the path pointing to the application's EAR file.
 boolean staged(java.lang.String server)
          Convenience method for determining whether this application is currently staged on a particular server.
 void undeploy()
           
 
Methods inherited from interface weblogic.management.configuration.ConfigurationMBean
getNotes, setNotes, setPersistenceEnabled
 
Methods inherited from interface weblogic.management.WebLogicMBean
getMBeanInfo, getName, getObjectName, getParent, getType, isCachingDisabled, isRegistered, setName, setParent
 
Methods inherited from interface javax.management.DynamicMBean
getAttribute, getAttributes, invoke, setAttribute, setAttributes
 
Methods inherited from interface javax.management.MBeanRegistration
postDeregister, postRegister, preDeregister, preRegister
 
Methods inherited from interface javax.management.NotificationBroadcaster
addNotificationListener, getNotificationInfo, removeNotificationListener
 

Method Detail

getPath

public java.lang.String getPath()
Returns the path pointing to the application's EAR file. The file is relative to the Admin Server's file system.


setPath

public void setPath(java.lang.String path)
             throws ManagementException,
                    javax.management.InvalidAttributeValueException
Set the path pointing to the application's EAR file. The path is relative to the Admin Server's file system.

Legal NULL: false
Throws:
ManagementException - if the path does not point to a valid operation or if a problem is encountered while parsing the application's deployment descriptor or creating management modules the application's modules.

getComponents

public ComponentMBean[] getComponents()
Returns the components that make up this application.

A non-configurable MBean attribute.

addComponent

public boolean addComponent(ComponentMBean component)
                     throws javax.management.InvalidAttributeValueException,
                            DistributedManagementException
Add a component to this application.

A dynamic MBean attribute

removeComponent

public boolean removeComponent(ComponentMBean component)
                        throws javax.management.InvalidAttributeValueException,
                               DistributedManagementException
Remove a component from this application.

A dynamic MBean attribute

load

public void load()
          throws ManagementException
Intializes all the MBeans for an application,for any changes in the application descriptor to take into affect the load has to be called on the Application MBean before the application is deployed/redeployed.

A dynamic MBean attribute

load

public void load(boolean autoDiscover)
          throws ManagementException
Load or reload the application, automatically discovering components.

A dynamic MBean attribute

getLoadError

public java.lang.Exception getLoadError()
Return the error thrown the last attempt to call load or reload if any, null otherwise.


getLastModified

public long getLastModified()
Returns the time when this application was last loaded.

A non-configurable MBean attribute.

setDeployed

public void setDeployed(boolean deployed)
                 throws DeploymentException,
                        UndeploymentException,
                        DistributedManagementException
Deploy or undeploy the entire application. All of the application's components will be deployed or undeployed. Setting deployed to be true on an application that is already deployed is a no-op. Likewise, setting deployed to be false on an application that is not deployed is a no-op.

A dynamic MBean attribute
Default Value: true

deploy

public void deploy()
            throws DeploymentException,
                   DistributedManagementException


undeploy

public void undeploy()
              throws UndeploymentException,
                     DistributedManagementException


isDeployed

public boolean isDeployed()
Returns whether or not this application is deployed.


setLastModified

public void setLastModified(long time)


getStagedTargets

public java.lang.String[] getStagedTargets()
List of servers this application is known to be staged on. This makes no distinction regarding the version or state of the staged files, just that they are staged. The array returned contains the names of the target servers. This set should not include cluster names.

A dynamic MBean attribute

staged

public boolean staged(java.lang.String server)
Convenience method for determining whether this application is currently staged on a particular server.

A non-configurable MBean attribute.

Documentation is available at
http://download.oracle.com/docs/cd/E13222_01/wls/docs61

WebLogic classes and methods that do not appear in this reference are not public and are not supported.