此内容没有您所选择的语言版本。
15.3. Configure Lock Striping (Library Mode)
Lock striping is disabled by default in Red Hat JBoss Data Grid. Configure lock striping in JBoss Data Grid's Library mode using the
useLockStriping
parameter as demonstrated in the following procedure.
Procedure 15.1. Configure Lock Striping (Library Mode)
Set the Concurrency Level
TheconcurrencyLevel
is used to specify the size of the shared lock collection use when lock striping is enabled.<infinispan> ... <default> <locking concurrencyLevel="${VALUE}" />
<infinispan> ... <default> <locking concurrencyLevel="${VALUE}" />
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Set Isolation Level
TheisolationLevel
parameter specifies the cache's isolation level. Valid isolation levels areREAD_COMMITTED
andREPEATABLE_READ
.Copy to Clipboard Copied! Toggle word wrap Toggle overflow Specify Lock Acquisition Timeout
ThelockAcquisitionTimeout
parameter specifies time (in milliseconds) after which a lock acquisition attempt times out.Copy to Clipboard Copied! Toggle word wrap Toggle overflow Configure Lock Striping
TheuseLockStriping
parameter specifies whether a pool of shared locks are maintained for all entries that require locks. If set toFALSE
, locks are created for each entry in the cache. If set toTRUE
, lock striping is enabled and shared locks are used as required from the pool.Copy to Clipboard Copied! Toggle word wrap Toggle overflow Configure Write Skew Check
ThewriteSkewCheck
check determines if a modification to the entry from a different transaction should roll back the transaction. Write skew set to true requiresisolation_level
set toREPEATABLE_READ
. The default value forwriteSkewCheck
andisolation_level
areFALSE
andREAD_COMMITTED
respectively.Copy to Clipboard Copied! Toggle word wrap Toggle overflow