[jboss-jira] [JBoss JIRA] Resolved: (JBAS-5557) Implement ManagementView.getDeploymentNamesForType to standard jbossas deployment types
Scott M Stark (JIRA)
jira-events at lists.jboss.org
Wed Jun 11 12:56:15 EDT 2008
[ http://jira.jboss.com/jira/browse/JBAS-5557?page=all ]
Scott M Stark resolved JBAS-5557.
---------------------------------
Resolution: Done
The implementation has been moved to the management layer in the ManagedDeploymentCreator implementation:
deployers.xml:
...
<!-- The ManagedDeploymentCreator implementation that supports mapping
attachment types to ManagedDeployment#getTypes
-->
<bean name="ManagedDeploymentCreator" class="org.jboss.deployers.plugins.managed.TypedManagedDeploymentCreator" />
There are 3 ways the ManagedDeployment type is obtained:
1. From the ManagementDeployment(types={...}) annotation. The
@ManagementObject
@ManagementDeployment(types={"sar"})
public class ServiceDeployment
implements Serializable
{
...
2. From all of the org.jboss.deployers.spi.management.KnownDeploymentTypes enums attached to the DeploymentUnit from which the ManagedDeployment is built.
public enum KnownDeploymentTypes
{
JavaEEApplication("ear"),
JavaEEClientApplication("car"),
JavaEEEnterpriseBeans2x("ejb2x"),
JavaEEEnterpriseBeans3x("ejb3x"),
JavaEEWebApplication("war"),
JavaEEResourceAdaptor("rar"),
JavaEEPersistenceUnit("par"),
JBossServices("sar"),
MCBeans("beans"),
OSGIBundle("bundle"),
SpringApplication("spring"),
Unknown("*")
;
3. By registering an attachment type to deployment type mapping with the TypedManagedDeploymentCreator, typically by the deployer that handles the attachment type. There are two variations of mappings:
3a. Basic mapping from the attachment type class to the deployment type. For example, the KernelDeploymentDeployer registering a beans deployment type for the KernelDeployment attachment:
<bean name="KernelDeploymentDeployer" class="org.jboss.deployers.vfs.deployer.kernel.KernelDeploymentDeployer">
<install bean="ManagedDeploymentCreator" method="addAttachmentType">
<parameter>
<value>org.jboss.kernel.spi.deployment.KernelDeployment</value>
</parameter>
<parameter>
<value>beans</value>
</parameter>
</install>
<uninstall bean="ManagedDeploymentCreator" method="removeAttachmentType">
<parameter>
<value>org.jboss.kernel.spi.deployment.KernelDeployment</value>
</parameter>
</uninstall>
</bean>
3b. A versioned mapping from the attachment type class to the deployment type. Examples of this include the Ejb3Deployer and EJB2xDeployer which register the JBossMetaData attachment type with different version patterns and deployment types:
// Ejb3Deployer handles 3.* versions
<bean name="Ejb3Deployer" class="org.jboss.ejb3.deployers.Ejb3Deployer">
<install bean="ManagedDeploymentCreator" method="addVersionedAttachmentType">
<parameter>
<value>org.jboss.metadata.ejb.jboss.JBossMetaData</value>
</parameter>
<parameter>
<value>ejb3x</value>
</parameter>
<parameter>
<value>3.*</value>
</parameter>
</install>
<uninstall bean="ManagedDeploymentCreator" method="removeVersionedAttachmentType">
<parameter>
<value>org.jboss.metadata.ejb.jboss.JBossMetaData</value>
</parameter>
<parameter>
<value>ejb3x</value>
</parameter>
</uninstall>
...
// EJB2xDeployer handles versions 2.*-1.*
<bean name="EJB2xDeployer" class="org.jboss.ejb.deployers.EjbDeployer">
<install bean="ManagedDeploymentCreator" method="addVersionedAttachmentType">
<parameter>
<value>org.jboss.metadata.ejb.jboss.JBossMetaData</value>
</parameter>
<parameter>
<value>ejb2x</value>
</parameter>
<parameter>
<value>[1-2].*</value>
</parameter>
</install>
<uninstall bean="ManagedDeploymentCreator" method="removeVersionedAttachmentType">
<parameter>
<value>org.jboss.metadata.ejb.jboss.JBossMetaData</value>
</parameter>
<parameter>
<value>ejb2x</value>
</parameter>
</uninstall>
...
> Implement ManagementView.getDeploymentNamesForType to standard jbossas deployment types
> ---------------------------------------------------------------------------------------
>
> Key: JBAS-5557
> URL: http://jira.jboss.com/jira/browse/JBAS-5557
> Project: JBoss Application Server
> Issue Type: Sub-task
> Security Level: Public(Everyone can see)
> Components: Deployers, Management services
> Reporter: Scott M Stark
> Assigned To: Scott M Stark
> Fix For: JBossAS-5.0.0.CR1
>
>
> We need to provide an api for determining the known deployment types (ear/war/ejb-jar/client-app-jar/rar/sar/mcbeans/...) in the ManagementView. This was the purpose of the getDeploymentNamesForType(String) method, but no ManagedDeployments are describing their type correctly as the deployer type was deprecated from the MC deployer api. It needs to be added back somewhere.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-jira
mailing list