I was able to do a workaround solution after stepping through all the 
deployment code yesterday. It works now but I would appreciate your comments on 
whether I did it right and also for the benefit of whoever gets stuck with it 
in the future.

I added the following to the QmfTypeAnnotationDeployer class:

  |     public QmfTypeAnnotationDeployer() {
  |         log.info("Initalizing "+this.getClass().getSimpleName());
  |         addInput(JBossMetaData.class);
  |         setOutputs(new HashSet<String>());
  |         setOutput(QmfRegisteredClassesMetaData.class);
  |     }
  | 

What this does is it makes sure that my custom annotation deployer runs after 
all normal EJB3 annotation scanners. The way I understand it is that the 
problem was that by default GenericAnnotationDeployer sets its output as 
AnnotationEnviroment and this creates a conflict between it and some other 
deployer from EJB3 package which also outputs AnnotationEnviroment but slightly 
changed. Since the previous version of my custom deployer didnt have any inputs 
it was running first and basically giving wrong AnnotationEnviroment to the 
rest of EJB3 deployers - which (after some more processing) would generate the 
exception I have experienced.

If my understanding is correct the fix should be easy - just change the output 
of EJB3 deployer to something like 
setOutput('internal.'+AnnotationEnviroment.class.getSimpleName()) which will 
make sure that both AnnotationEnviroments can co-exist happily :)

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

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4228547
_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user

Reply via email to