1 Reply Latest reply on Jun 28, 2007 8:51 AM by Ales Justin

    Why this semantic change?

    Adrian Brock Master

       

      @@ -648,10 +648,6 @@
       */
       protected void doInstall(Deployer deployer, DeploymentContext context, boolean doComponents) throws Throwable
       {
      - // Take a copy of the components so we don't start looping on newly added components
      - // in the component deployers
      - List<DeploymentContext> components = new ArrayList<DeploymentContext>(context.getComponents());
      -
       DeploymentUnit unit = context.getDeploymentUnit();
       if (isRelevant(deployer, unit, context.isTopLevel(), context.isComponent()))
       deployer.deploy(unit);
      @@ -660,9 +656,13 @@
      
       if (doComponents)
       {
      - try
      + List<DeploymentContext> currentComponents = context.getComponents();
      + if (currentComponents != null && currentComponents.isEmpty() == false)
      


      The code is even commented to say that it is retrieving the components
      *before* it invokes the deployer on the main context

      Take a copy of the components so we don't start looping on newly added components

      but you've changed it to do the opposite.

      In practice, the condition doesn't occur, because none of the
      current deployers that create components, accept components,
      but if/when such a deployer is created, it will loop after this change.