Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
None
-
None
-
None
Description
The current implementation of DefaultSourceFactory, DefaultSinkFactory and DefaultChannelFactory ensures that if a create() is called for the same name and type of object, it returns the previously created instance where available. However, on deregister it directly removes the created object from cache. This can lead to multiple instances of same name to exist within the VM which in turn can cause other problems.
Instead if the factory implementation does reference counting, it will be able to ensure that the purge of an object happens only when the number of unregister calls matches the create calls.