Details
-
Type:
New Feature
-
Status:
Resolved
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: None
-
Fix Version/s: 3.4.0
-
Component/s: C# API, Framework Core
-
Labels:None
Description
A fixed-size component pool has several benefits:
- it can preallocate a given set of components,
- it can work on a fixed number of components, for example equal to the number of cores,
- no surprises with soft/weak references vanishing under load.
- no surprises when porting to .NET (mono has a very different GC model).
Look at ControllerTest.java, search for: "Create a size-one pool because tests depend on the first object instantiated.". If you create a fixed-size pool of 2 or more components tests fail, I couldn't diagnose why – I suspect the fact that FixedSizePool instantiates the entire pool of objects immediately may be of importance here.