Re: [Resin-interest] Qualifier not working on 4.0.6

2010-06-02 Thread Scott Ferguson
Jeff Schnitzer wrote:
 I'm making good progress getting SubEtha running on 4.0.6, but now I
 seem to have a strange and self-contradictory error:

 [10-05-30 11:24:11.854] {main}
 org.subethamail.core.queue.InjectListener.outboundQueue:
 javax.enterprise.inject.UnsatisfiedResolutionException: Can't find a
 bean for 
 'java.util.concurrent.BlockingQueueorg.subethamail.core.queue.DeliveryQueueItem'
 because no beans match the type and bindings
 [...@org.subethamail.core.queue.deliveryqueue()].
Beans:
XmlBean[FileQueue,
 {...@org.subethamail.core.queue.deliveryqueue(),
 @javax.inject.Named(value=delivery), @Any()}, name=delivery,
 @Singleton]
XmlBean[FileQueue,
 {...@org.subethamail.core.queue.injectqueue(),
 @javax.inject.Named(value=inject), @Any()}, name=inject, @Singleton]

 There is clearly a FileQueue with @DeliveryQueue present, yet the
 manager can't seem to resolve it!

 Any idea what might be wrong?
   
It's probably the generic type matching. Our matching didn't exactly 
work with the CDI TCK, and there are still some details left to work out 
to make that work. I've added it as a bug at
http://bugs.caucho.com/view.php?id=4067
 By the way, replacing our legacy plugin architecture (inherited from
 JBoss4 days) with the @Any Instance? api produces amazingly clean
 code!  Really fantastic stuff.
   
Isn't that great? After people start spending time with CDI, I think 
we'll discover a nice set of new patterns that it enables.

-- Scott
 Thanks,
 Jeff


 ___
 resin-interest mailing list
 resin-interest@caucho.com
 http://maillist.caucho.com/mailman/listinfo/resin-interest

   



___
resin-interest mailing list
resin-interest@caucho.com
http://maillist.caucho.com/mailman/listinfo/resin-interest


[Resin-interest] Qualifier not working on 4.0.6

2010-05-30 Thread Jeff Schnitzer
I'm making good progress getting SubEtha running on 4.0.6, but now I
seem to have a strange and self-contradictory error:

[10-05-30 11:24:11.854] {main}
org.subethamail.core.queue.InjectListener.outboundQueue:
javax.enterprise.inject.UnsatisfiedResolutionException: Can't find a
bean for 
'java.util.concurrent.BlockingQueueorg.subethamail.core.queue.DeliveryQueueItem'
because no beans match the type and bindings
[...@org.subethamail.core.queue.deliveryqueue()].
   Beans:
   XmlBean[FileQueue,
{...@org.subethamail.core.queue.deliveryqueue(),
@javax.inject.Named(value=delivery), @Any()}, name=delivery,
@Singleton]
   XmlBean[FileQueue,
{...@org.subethamail.core.queue.injectqueue(),
@javax.inject.Named(value=inject), @Any()}, name=inject, @Singleton]

There is clearly a FileQueue with @DeliveryQueue present, yet the
manager can't seem to resolve it!

Here's the resin-web.xml declaration of the FileQueue:

jms:FileQueue
queue:DeliveryQueue/
ee:Nameddelivery/ee:Named
/jms:FileQueue

Here's the injection point in InjectListener:

@Inject @DeliveryQueue BlockingQueueDeliveryQueueItem outboundQueue;

DeliveryQueue is pretty straightforward:

@Qualifier
@Target({FIELD,METHOD,PARAMETER})
@Retention(RUNTIME)
public @interface DeliveryQueue
{}

Any idea what might be wrong?

By the way, replacing our legacy plugin architecture (inherited from
JBoss4 days) with the @Any Instance? api produces amazingly clean
code!  Really fantastic stuff.

Thanks,
Jeff


___
resin-interest mailing list
resin-interest@caucho.com
http://maillist.caucho.com/mailman/listinfo/resin-interest