[jboss-dev-forums] [Design of EJB 3.0] - Re: Ejb3Deployment.resolveMessageDestination

scott.stark@jboss.org do-not-reply at jboss.com
Mon Aug 4 15:42:35 EDT 2008


The org.jboss.injection.ResourceHandler should just be looking at the mappedName/jndiName/resolvesJndiName and throwing an exception if its not set. This is the change I made in the client container version and then fixed the message-destination-ref link resolution in the MappedReferenceMetaDataResolverDeployer.

The org.jboss.injection.ResourceHandler is not looking to the resolvedJnidName curently. Should be something like:


  |    private static void loadXmlMessageDestinationRefs(InjectionContainer container, Collection<MessageDestinationReferenceMetaData> refs)
  |    {
  |       for (MessageDestinationReferenceMetaData envRef : refs)
  |       {
  |          String encName = "env/" + envRef.getMessageDestinationRefName();
  |          if (container.getEncInjectors().containsKey(encName)) continue;
  |          String jndiName = envRef.getMappedName();
  |          if (jndiName == null || jndiName.equals(""))
  |          {
  |             // Look for a resolved-jndi-name
  |             jndiName = envRef.getResolvedJndiName();
  |             if (jndiName == null)
  |             {
  |                throw new RuntimeException("message-destination has no jndi-name/resolved-jndi-name " + envRef);
  |             }
  |          }
  | ...
  | 


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

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



More information about the jboss-dev-forums mailing list