PicoContainer
  1. PicoContainer
  2. PICO-62

unregisterComponent fails after getComponentInstances

    Details

    • Type: Bug Bug
    • Status: Closed Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.1
    • Fix Version/s: 1.0-beta-5
    • Component/s: PicoContainer (Java)
    • Labels:
      None
    • Number of attachments :
      1

      Description

      There seems to be something wrong with the component unregistration from DefaultPicoContainer. I've seen the testcase DefaultPicoContainerUnregisterComponentTestCase working correctly, but if I add the line:

      picoContainer.getComponentInstances();

      right before the picoContainer.unregisterComponent(..) into every test
      method in this testcase, 3 of the 4 tests fail.

      Some further investigation shows, that after calling getComponentInstances() and unregisterComponent() (in this order), getComponentKeys() will show the correct amount of keys, but getComponentInstances() will not (the latter will show the unregistered component as well), so that smells like inconsistent behaviour.

      I think not being able to completely unregister components from picocontainer is a major issue, please investigate the problem.

        Activity

        Hide
        Kristof Jozsa added a comment -

        the modified testcase which fails. I forgat to say, I've verified this issue against the latest CVS head version, it also exists there.

        Show
        Kristof Jozsa added a comment - the modified testcase which fails. I forgat to say, I've verified this issue against the latest CVS head version, it also exists there.
        Kristof Jozsa made changes -
        Field Original Value New Value
        Attachment DefaultPicoContainerUnregisterComponentTestCase.java [ 11031 ]
        Aslak Hellesøy made changes -
        Assignee Aslak Hellesoy [ rinkrank ]
        Aslak Hellesøy made changes -
        Fix Version/s 1.0.1 [ 10307 ]
        Affects Version/s 1.0.1 [ 10307 ]
        Aslak Hellesøy made changes -
        Fix Version/s 1.0-beta-5 [ 10145 ]
        Status Open [ 1 ] Closed [ 6 ]
        Fix Version/s 1.0.1 [ 10307 ]
        Resolution Fixed [ 1 ]

          People

          • Assignee:
            Aslak Hellesøy
            Reporter:
            Kristof Jozsa
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: