[jbosstools-issues] [JBoss JIRA] Resolved: (JBIDE-9255) Duplicate java elements in CDI validation problem message
Viacheslav Kabanovich (JIRA)
jira-events at lists.jboss.org
Tue Jun 28 17:01:23 EDT 2011
[ https://issues.jboss.org/browse/JBIDE-9255?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Viacheslav Kabanovich resolved JBIDE-9255.
------------------------------------------
Assignee: Alexey Kazakov (was: Viacheslav Kabanovich)
Resolution: Done
Verified.
> Duplicate java elements in CDI validation problem message
> ---------------------------------------------------------
>
> Key: JBIDE-9255
> URL: https://issues.jboss.org/browse/JBIDE-9255
> Project: Tools (JBoss Tools)
> Issue Type: Bug
> Components: cdi (jsr-299)
> Affects Versions: 3.3.0.M3
> Reporter: Alexey Kazakov
> Assignee: Alexey Kazakov
> Fix For: 3.3.0.M3
>
>
> EXECUTE: Create any CDI project with Seam Solder module.
> EXECUTE: Create a few types:
> {code}
> @Retention(RUNTIME)
> @GenericType(MessageSystemConfiguration.class)
> @interface ACMEQueue {
> String name();
> }
> {code}
> {code}
> public class MyMessageQueues {
> @Produces
> @ACMEQueue("defaultQueue")
> @Named("aaa")
> MessageSystemConfiguration defaultQueue = new MessageSystemConfiguration(null);
> @Produces
> @Durable
> @ACMEQueue("defaultQueue")
> @Named("aaa")
> MessageSystemConfiguration defaultQueue1 = new MessageSystemConfiguration(null);
> }
> {code}
> {code}
> @GenericConfiguration(ACMEQueue.class)
> class MessageManager {
> @Inject
> @Generic
> MessageQueue queue;
> @Produces
> @ApplyScope
> MessageDispatcher messageDispatcherProducer() {
> return queue.createMessageDispatcher();
> }
> @Produces
> DispatcherPolicy getPolicy() {
> return queue.getDispatcherPolicy();
> }
> }
> {code}
> {code}
> @GenericConfiguration(ACMEQueue.class)
> @ApplyScope
> public class QueueManager implements Serializable {
> @Produces
> @ApplyScope
> public MessageQueue messageQueueProducer() {
> // return factory.createMessageQueue(config.name());
> return null;
> }
> }
> {code}
> {code}
> public interface MessageQueue {}
> {code}
> EXECUTE: Save the files.
> ASSERT: Both @Named("aaa") marked as duplicate EL names: "A few beans (QueueManager.messageQueueProducer(), MyMessageQueues.defaultQueue1, MyMessageQueues.defaultQueue) have the same EL name and the name is not resolvable [JSR-299 §5.3.1]
> FAILURE: Both @Named("aaa") marked as duplicate EL names: "A few beans (QueueManager.messageQueueProducer(), MyMessageQueues.defaultQueue1, MyMessageQueues.defaultQueue, QueueManager.messageQueueProducer()) have the same EL name and the name is not resolvable [JSR-299 §5.3.1] <-- QueueManager.messageQueueProducer() mentioned twice!
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jbosstools-issues
mailing list