At initialization time, the CPE classifies CasProcessors based on OperationalProperties defined in the AE descriptor. Specifically, it uses isMultipleDeploymentAllowed property to determine whether or not a CasProcessor should be instantiated more than once to run in multiple threads. The CPE instantiates only one instance of a CP that has isMultiplerDeploymentAllowed=false. If such CP appears in a middle of a pipeline, the CPE creates a single instance that is shared by all pipeline threads. This of course implies that while one thread (pipeline) is using a shared CP, the other thread (pipeline) is blocking until the first releases the shared CP.
During classification of CPs, the CPE walks the list of CPs backwards, in the order specified in a CPE descriptor. It will assign all CPs with isMultiplerDeploymentAllowed=false to run in a single thread right behind the OutputQueue. This assignment continues until the first CP with isMultiplerDeploymentAllowed=true is found. Any remaining CPs will be running in a processing pipeline that may be scaled out to run in multiple threads. Jerry
