stable

Clone or download

Read-only

request #9729: Do not mix linked list and rank for artifact priority

Benchmark in millisecondes (see next commit https://gerrit.tuleap.net/7192) Before: +----------------------------------------+-----+-------+--------+--------+---------+ | | 100 | 10000 | 100000 | 500000 | 1000000 | +----------------------------------------+-----+-------+--------+--------+---------+ | Time taken for put at the end | 14 | 21 | 51 | 436 | 563 | | Time taken for move before (1 rank) | 10 | 25 | 134 | 632 | 1232 | | Time taken for move before (middle) | 11 | 74 | 708 | 3343 | 6956 | | Time taken for move before (all) | 11 | 113 | 1048 | 4973 | 16654 | | Time taken for move 10 before (1 rank) | 12 | 36 | 131 | 620 | 1163 | +----------------------------------------+-----+-------+--------+--------+---------+ After: +----------------------------------------+-----+-------+--------+--------+---------+ | | 100 | 10000 | 100000 | 500000 | 1000000 | +----------------------------------------+-----+-------+--------+--------+---------+ | Time taken for put at the end | 8 | 16 | 67 | 503 | 631 | | Time taken for move before (1 rank) | 9 | 12 | 55 | 211 | 405 | | Time taken for move before (middle) | 8 | 40 | 300 | 2088 | 4635 | | Time taken for move before (all) | 9 | 61 | 529 | 3525 | 7262 | | Time taken for move 10 before (1 rank) | 9 | 14 | 56 | 211 | 405 | +----------------------------------------+-----+-------+--------+--------+---------+ Gain: +----------------------------------------+-----+-------+--------+--------+---------+ | | 100 | 10000 | 100000 | 500000 | 1000000 | +----------------------------------------+-----+-------+--------+--------+---------+ | Time taken for put at the end | 6 | 5 | -16 | -67 | -68 | | Time taken for move before (1 rank) | 1 | 13 | 79 | 421 | 827 | | Time taken for move before (middle) | 3 | 34 | 408 | 1255 | 2321 | | Time taken for move before (all) | 2 | 52 | 519 | 1448 | 9392 | | Time taken for move 10 before (1 rank) | 3 | 22 | 75 | 409 | 758 | +----------------------------------------+-----+-------+--------+--------+---------+ To launch benchmarks, you should execute the following command: $> docker run --rm=true \ -v $PWD:/tuleap \ enalean/tuleap-simpletest:c6-php53 \ /tuleap/plugins/tracker/db_tests/PriorityDaoTestPerformances.php The results of the benchmark is generated in the file $PWD/stats-artifact-priority.csv Maybe it would be a great addition to have a Jenkins job to launch those benchmark on a regular basis? Change-Id: Ie974ebb45431f289daf5388528b363e27a5fbf9e

Modified Files

Name
M plugins/agiledashboard/include/AgileDashboard/BacklogItemDao.class.php +15 −15 Go to diff View file
M plugins/agiledashboard/include/AgileDashboard/KanbanItemDao.class.php +7 −7 Go to diff View file
M plugins/tracker/db/install.sql +4 −8 Go to diff View file
A plugins/tracker/db/mysql/updates/2016/201612091720_use_only_rank_for_artifact_priority.php +72 −0 Go to diff View file
M plugins/tracker/db/uninstall.sql +1 −0 Go to diff View file
M plugins/tracker/db_tests/PriorityDaoTest.php +19 −30 Go to diff View file
A plugins/tracker/db_tests/PriorityDaoTestPerformances.php +210 −0 Go to diff View file
M plugins/tracker/include/Tracker/Artifact/Tracker_Artifact_PriorityManager.class.php +1 −1 Go to diff View file
M plugins/tracker/include/Tracker/Artifact/dao/PriorityDao.class.php +95 −326 Go to diff View file
M plugins/tracker/include/Tracker/Artifact/dao/Tracker_ArtifactDao.class.php +20 −20 Go to diff View file
M plugins/tracker/include/Tracker/Artifact/dao/Tracker_Artifact_PriorityHistoryDao.class.php +2 −2 Go to diff View file
M plugins/tracker/include/Tracker/FormElement/Tracker_FormElement_Field_Priority.class.php +4 −4 Go to diff View file
M plugins/tracker/include/Tracker/FormElement/dao/Tracker_FormElement_Field_Value_ArtifactLinkDao.class.php +2 −2 Go to diff View file