Files
tryton/trytond
Cédric Krier 792d623c7b Improve threshold between rebuild and update MPTT
Indeed we should count the number of nodes updated instead of the number of
queries.

rebuild: 1 write and 1 select on each node
update: (1 write + 3 select + 2 write on average ½ all nodes + 1 write on child
of id) on each ids

So the threshold is:

2 * count < (4 + 2 * count / 2 + 1 * x) * len(ids)
2 * count < (4 + count + x) * len(ids)

which can be approximated to

2 * count < count * len(ids)
2 < len(ids)

issue5399
review20861002
2016-03-21 23:43:22 +01:00
..
2016-03-17 22:56:58 +01:00
2015-08-21 18:03:44 +02:00
2016-03-05 17:31:25 +01:00
2016-02-07 16:46:16 +01:00
2016-03-15 16:57:26 +01:00
2016-03-15 16:57:26 +01:00
2016-03-15 16:57:26 +01:00
2016-03-03 23:27:38 +01:00
2016-03-15 16:57:26 +01:00
2016-03-15 16:57:26 +01:00
2016-01-21 10:48:32 +01:00
2016-03-13 21:46:30 +01:00
2016-03-15 16:57:26 +01:00
2014-12-02 12:54:01 +01:00
2016-03-17 22:56:58 +01:00
2016-03-15 16:57:26 +01:00
2014-12-02 12:54:01 +01:00
2016-03-15 16:57:26 +01:00
2015-03-09 19:40:41 +01:00
2016-03-15 16:57:26 +01:00
2016-03-15 16:57:26 +01:00