LibreCat icon indicating copy to clipboard operation
LibreCat copied to clipboard

publication_count() is slow

Open nics opened this issue 6 years ago • 3 comments

publication_count() in index_user.fix slows makes indexing the user table 20 to 200 times slower. It should be rewritten or turned into an asynchronous job.

nics avatar May 25 '18 13:05 nics

Basically, this feature was intended for batch jobs. The described behaviour was not intended. So how to distinguish that as they use the same code base.

vpeil avatar Jun 11 '18 10:06 vpeil

If we move this to the model, we can do: publications->add($stream, skip_before_add => ['publication_count'])

nics avatar Jun 11 '18 11:06 nics

Turning these fix steps into hooks is generally preferred probably, as they make turning features on and off possible.

nics avatar Jun 11 '18 11:06 nics