-
New Feature Request
-
Resolution: Unresolved
-
High
-
None
-
6.4.0beta5
-
centos
need:
When using zabbix, we found that some databases using mysql mode do not support "lock in share mode", but support "select for update". They are not compatible with zabbix, mainly because the zbx_db_lock_maintenanceids function uses shared locks. Oracle selectively uses "select for update" by defining the macro HAVE_ORACLE, but this approach is expensive. All we need is to be able to use "select for update" also in mysql mode.
suggestion:
1. Add a configuration item named "AllowLockForUpdate", with a value of 1 indicating that "select for update" can be used.
2. Modify the zbx_db_lock_maintenanceids function. In mysql mode, if AllowSelectForUpdate = 1, use "select for update" instead of "lock in share mode".
This change is small, but it can greatly improve the compatibility of zabbix. I think "select for update" semantics should be configurable, not just support oracle mode.