-
Change Request
-
Resolution: Fixed
-
Critical
-
None
-
None
-
Sprint 26
A primary key in the database can be shown to have significant performance benifits, particularly in a database engine such as InnoDB or Tokudb which clusters the row based on this index.
However it is not currently possible to use a primary key in the history* tables due to the server occasionally attempting to insert the same row twice.
A simple protection against this is to add in zbx_db_insert_execute
#ifdef HAVE_MYSQL zbx_strcpy_alloc(&sql_command, &sql_command_alloc, &sql_command_offset, " ON DUPLICATE KEY UPDATE value=VALUE(value)"); #endif
This should have no (negative) effect on the current schema, however allows experts to modify their schema possibly with a primary key.
- causes
-
ZBXNEXT-6921 Use primary keys for historical tables (PoC)
- Closed
- depends on
-
ZBXNEXT-2363 DB Schema for MariaDB with TokuDB
- Open
- is duplicated by
-
ZBXNEXT-4212 Change zabbix history add DUPLICATE KEY UPDATE clause to db history insertion
- Open
- mentioned in
-
Page Loading...