Package com._1c.g5.v8.internal.derived
Class DerivedDataEngine
java.lang.Object
com._1c.g5.v8.internal.derived.DerivedDataEngine
- All Implemented Interfaces:
IDerivedDataEngine
Derived data engine implementation
-
Constructor Summary
ConstructorsConstructorDescriptionDerivedDataEngine
(IUserActivityBlockingService userActivityBlockingService, ISystemIdleService systemIdleService) Constructs an engine instance -
Method Summary
Modifier and TypeMethodDescriptioncreateProvider
(String projectId, Collection<IDerivedDataConfigurationContributor> contributors, Set<String> filteredSegments, IDerivedDataServiceLockController lockController, Supplier<Boolean> synchronizationActiveStateSupplier, Supplier<IAsyncComputationExecutionContext> executionContextSupplier) Creates a providervoid
setPermittedThreads
(int permittedThreads) Sets the maximum number of computation threads the DD subsystem should use at the moment.void
start()
Starts the inactive engine.void
stop()
Stops the active engine.
-
Constructor Details
-
DerivedDataEngine
public DerivedDataEngine(IUserActivityBlockingService userActivityBlockingService, ISystemIdleService systemIdleService) Constructs an engine instance- Parameters:
userActivityBlockingService
- The reference to theIUserActivityBlockingService
service. May not benull
ISystemIdleService
- The reference to theISystemIdleService
service. May not benull
-
-
Method Details
-
createProvider
public IDerivedDataBmProvider createProvider(String projectId, Collection<IDerivedDataConfigurationContributor> contributors, Set<String> filteredSegments, IDerivedDataServiceLockController lockController, Supplier<Boolean> synchronizationActiveStateSupplier, Supplier<IAsyncComputationExecutionContext> executionContextSupplier) Description copied from interface:IDerivedDataEngine
Creates a provider- Specified by:
createProvider
in interfaceIDerivedDataEngine
- Parameters:
projectId
- The unique identifier of the owner project. Cannot benull
contributors
- The set of derived data contributors. Cannot benull
. Can be emptyfilteredSegments
- The set of segment ids that should be ommitted during the computation. Cannot benull
. Can be emptylockController
- The DD external lock controller. Cannot benull
synchronizationActiveStateSupplier
- The supplier which provides the status of the synchronization. Cannot benull
executionContextSupplier
- The supplier which provides client-specificIAsyncComputationExecutionContext
. Cannot benull
- Returns:
- The created DD provider. Cannot be
null
-
setPermittedThreads
public void setPermittedThreads(int permittedThreads) Description copied from interface:IDerivedDataEngine
Sets the maximum number of computation threads the DD subsystem should use at the moment. It's up to client to control reduction/increasing the number of used threads, the DD subsystem itself won't adjust the maximum number of used threads (though could use less then maximum in any given moment)- Specified by:
setPermittedThreads
in interfaceIDerivedDataEngine
- Parameters:
permittedThreads
- The number of permitted threads. Must be a positive number
-
start
public void start()Description copied from interface:IDerivedDataEngine
Starts the inactive engine. The single engine instance mustn't be started more then once. The engine should be in inactive state prior the start call- Specified by:
start
in interfaceIDerivedDataEngine
-
stop
public void stop()Description copied from interface:IDerivedDataEngine
Stops the active engine. The single engine instance mustn't be stopped more then once. The engine should be in active state prior the stop call- Specified by:
stop
in interfaceIDerivedDataEngine
-