10.2 Integration into hosted environment - Reference Documentation
Authors: The Whole GPars Gang
Version: 1.1.0
10.2 Integration into hosted environment
Hosted environments, such as Google App Engine, impose additional restrictions on threading. For GPars to integrate with these environments better, the default thread factory and timer factory can be customized. The GPars_Config class provides static initialization methods allowing third parties to register their own implementations of the PoolFactory and TimerFactory interfaces, which will then be used to create default pools and timers for Actors, Dataflow and PGroups.public final class GParsConfig { private static volatile PoolFactory poolFactory; private static volatile TimerFactory timerFactory; public static void setPoolFactory(final PoolFactory pool) public static PoolFactory getPoolFactory() public static Pool retrieveDefaultPool() public static void setTimerFactory(final TimerFactory timerFactory) public static TimerFactory getTimerFactory() public static GeneralTimer retrieveDefaultTimer(final String name, final boolean daemon) }