2 Replies Latest reply on Apr 29, 2008 3:25 AM by Carlo de Wolf

    EJBTHREE-1290, MCDependencyPolicy interface

    Scott Stark Master

      As part of EJBTHREE-1290 where we want to change the dependency on the ejb container name to be based on demand/supply of the ejb container jndi name, I want to make MCDependencyPolicy a proper interface:

      public interface DependencyPolicy
      {
       public void addDependency(String dependency);
       public void addDatasource(String jndiName);
      }
      public interface MCDependencyPolicy extends DependencyPolicy
      {
       public void addDemand(DemandMetaData dependency);
       public Set<DemandMetaData> getDemands();
       public void addSupply(SupplyMetaData smd);
      }
      


      I want to drop a number of methods from the current MCDependencyPolicy class.
      - addDependency(Class businessInterface) addDependency(String ejbLink, businessInterface), addSupply(businessInterface) as this is something that should have been resolved to a container by the deployment resolver.
      - addJNDIName(String name) which creates a dependency on an ejb mapped name also becomes redundant and should be dropped.

      The current casting to JBoss5DependencyPolicy would be a reliance on the extended MCDependencyPolicy interface instead which would allow for alternate implementations in jbossas vs standalone.