Configuring the SharedActivation
SharedActivation
provides system-wide locking capabilities for license activations shared across multiple processes. It wraps a standard IActivation
instance with additional locking mechanisms.
The SharedActivation
constructor requires two configuration sections:
Activation Options - Configures the underlying activation (same as regular
Activation
). How to configure activation documentation is available here.Locking Options - Configures the locking mechanism for cross-process synchronization
ISharedActivation activation = SharedActivation(
activationOptions -> /* activation configuration */,
lockingOptions -> /* locking configuration */,
persistence);
Locking Options
Locking options define how SharedActivation
coordinates access between multiple processes:
lockingOptions -> {
// Use system-wide named file lock based on storage location
lockingOptions.useSystemLock();
// OR use system-wide named file lock based
lockingOptions.useSystemLock("Global-YourApp-UniqueIdentifier");
// OR use a custom lock implementation
lockingOptions.useCustomLock(activation -> yourCustomLockFactory);
}
Last updated
Was this helpful?