[jboss-dev-forums] [Deployers on JBoss (Deployers/JBoss)] - Re: Optional input for AbstractSimpleVFSRealDeployer

adrian@jboss.org do-not-reply at jboss.com
Mon Jul 9 13:41:16 EDT 2007


The real answer is that the annotations should be parsed to create an 
ApplicationClientDD before hitting your deployer.
You're going to need something like eventually so you can create
a ManagedObject for the profile service to use.

The longer answer is that you can't do that with the AbstractSimpleVFSRealDeployer.
You'll have to write an AbstractMoreComplicatedVFSRealDeployer :-)

What you are really asking for is something that does
setInputs(ApplicationClientDD.class) (optional input) instead of setInput(ApplicationClientDD.class) a requirement.

But then you'll have to be careful about the "deployment" being null
and this code in AbstractSimpleRealDeployer

  |    public void deploy(DeploymentUnit unit) throws DeploymentException
  |    {
  |       T deployment = unit.getAttachment(getInput());
  |       if (deployment != null)
  |       {
  |          // Set the deployer type
  |          unit.getTypes().add(getType());
  |          deploy(unit, deployment);
  |       }
  |    }
  | 

You don't want the deployment unit getting tagged as an appclient if it is not! :-)

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4062084#4062084

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4062084



More information about the jboss-dev-forums mailing list