org.rhq.plugins.jbossas
Class ApplicationComponent

java.lang.Object
  extended by org.rhq.plugins.jmx.MBeanResourceComponent<JBossASServerComponent<?>>
      extended by org.rhq.plugins.jbossas.ApplicationComponent
All Implemented Interfaces:
AvailabilityFacet, ConfigurationFacet, ContentFacet, DeleteResourceFacet, ResourceComponent<JBossASServerComponent<?>>, MeasurementFacet, OperationFacet, JMXComponent<JBossASServerComponent<?>>
Direct Known Subclasses:
WarComponent

public class ApplicationComponent
extends MBeanResourceComponent<JBossASServerComponent<?>>
implements ContentFacet, DeleteResourceFacet, OperationFacet

A resource component for managing an application (e.g. EAR or WAR) deployed to a JBossAS server.

Author:
Ian Springer

Field Summary
protected static String FILENAME_PLUGIN_CONFIG_PROP
           
static String RHQ_SHA256
           
 
Fields inherited from class org.rhq.plugins.jmx.MBeanResourceComponent
bean, OBJECT_NAME_PROP, PROPERTY_TRANSFORM, resourceContext
 
Fields inherited from interface org.rhq.plugins.jmx.JMXComponent
CREDENTIALS_CONFIG_PROP, PRINCIPAL_CONFIG_PROP
 
Constructor Summary
ApplicationComponent()
           
 
Method Summary
 void deleteResource()
           
 org.rhq.core.domain.content.transfer.DeployPackagesResponse deployPackages(Set<org.rhq.core.domain.content.transfer.ResourcePackageDetails> packages, ContentServices contentServices)
           
 Set<org.rhq.core.domain.content.transfer.ResourcePackageDetails> discoverDeployedPackages(org.rhq.core.domain.content.PackageType type)
           
 List<org.rhq.core.domain.content.transfer.DeployPackageStep> generateInstallationSteps(org.rhq.core.domain.content.transfer.ResourcePackageDetails packageDetails)
           
 String getApplicationName()
          Returns the name of the application.
 String getFileName()
          Returns the file name of this application.
 JBossASServerComponent getParentResourceComponent()
           
 void getValues(org.rhq.core.domain.measurement.MeasurementReport report, Set<org.rhq.core.domain.measurement.MeasurementScheduleRequest> requests)
           
 OperationResult invokeOperation(String name, org.rhq.core.domain.configuration.Configuration parameters)
           
 org.rhq.core.domain.content.transfer.RemovePackagesResponse removePackages(Set<org.rhq.core.domain.content.transfer.ResourcePackageDetails> packages)
           
 InputStream retrievePackageBits(org.rhq.core.domain.content.transfer.ResourcePackageDetails packageDetails)
           
 void revertFromBackupFile()
          Revert the resource from a possibly existing backup file with the same basename and ending in .bak
 
Methods inherited from class org.rhq.plugins.jmx.MBeanResourceComponent
getAttributeName, getAttributeProperty, getAvailability, getBeanProperties, getEmsBean, getEmsConnection, getPropertyValueAsType, getResourceContext, getValues, invokeOperation, loadBean, loadBean, loadResourceConfiguration, lookupAttributeProperty, setEmsBean, setResourceContext, start, stop, transformBeanName, updateResourceConfiguration, updateResourceConfiguration
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

RHQ_SHA256

public static final String RHQ_SHA256
See Also:
Constant Field Values

FILENAME_PLUGIN_CONFIG_PROP

protected static final String FILENAME_PLUGIN_CONFIG_PROP
See Also:
Constant Field Values
Constructor Detail

ApplicationComponent

public ApplicationComponent()
Method Detail

retrievePackageBits

public InputStream retrievePackageBits(org.rhq.core.domain.content.transfer.ResourcePackageDetails packageDetails)
Specified by:
retrievePackageBits in interface ContentFacet

discoverDeployedPackages

public Set<org.rhq.core.domain.content.transfer.ResourcePackageDetails> discoverDeployedPackages(org.rhq.core.domain.content.PackageType type)
Specified by:
discoverDeployedPackages in interface ContentFacet

removePackages

public org.rhq.core.domain.content.transfer.RemovePackagesResponse removePackages(Set<org.rhq.core.domain.content.transfer.ResourcePackageDetails> packages)
Specified by:
removePackages in interface ContentFacet

generateInstallationSteps

public List<org.rhq.core.domain.content.transfer.DeployPackageStep> generateInstallationSteps(org.rhq.core.domain.content.transfer.ResourcePackageDetails packageDetails)
Specified by:
generateInstallationSteps in interface ContentFacet

deployPackages

public org.rhq.core.domain.content.transfer.DeployPackagesResponse deployPackages(Set<org.rhq.core.domain.content.transfer.ResourcePackageDetails> packages,
                                                                                  ContentServices contentServices)
Specified by:
deployPackages in interface ContentFacet

deleteResource

public void deleteResource()
                    throws Exception
Specified by:
deleteResource in interface DeleteResourceFacet
Throws:
Exception

getValues

public void getValues(org.rhq.core.domain.measurement.MeasurementReport report,
                      Set<org.rhq.core.domain.measurement.MeasurementScheduleRequest> requests)
Specified by:
getValues in interface MeasurementFacet
Overrides:
getValues in class MBeanResourceComponent<JBossASServerComponent<?>>

invokeOperation

public OperationResult invokeOperation(String name,
                                       org.rhq.core.domain.configuration.Configuration parameters)
                                throws InterruptedException,
                                       Exception
Specified by:
invokeOperation in interface OperationFacet
Overrides:
invokeOperation in class MBeanResourceComponent<JBossASServerComponent<?>>
Throws:
InterruptedException
Exception

getApplicationName

public String getApplicationName()
Returns the name of the application.

Returns:
application name

getFileName

public String getFileName()
Returns the file name of this application.

Returns:
full directory and file name of the application

getParentResourceComponent

public JBossASServerComponent getParentResourceComponent()

revertFromBackupFile

public void revertFromBackupFile()
                          throws Exception
Revert the resource from a possibly existing backup file with the same basename and ending in .bak

Throws:
Exception - If anything goes wrong.


Copyright © 2008-2012 Red Hat, Inc.. All Rights Reserved.