Skip ke Konten
Menu
Pertanyaan ini telah diberikan tanda

I am having a database with lots of account move lines ,  while loading the trial balance on screen report without applying ir rules , it gets load within 30 seconds or so , but if i apply record rules it takes a lots of time like 6 - 7 minutes , i think the query execution takes a lots of time !!

I have also generated odoo profile but it gives like majority parts goes to get_html method , but while debugging , majority time goes on get_lines method and the html is loaded within seconds  after that .

Any idea how to optimise this or track where is the exact point of failure or issue , i even done indexing on the fields included in record rules .. but no difference , also no compute field in that.

Thanks

Avatar
Buang

could you share the domain applied for the rule

Penulis

Niyas,
actually there are multiple record rules in there, in between 10 to 15

Penulis

All for different use case , but when we go to trial balance they all get applies and makes the query so heavy !! Same conditions also applies on the general ledger but it gets printed in no time , and also i see some repeated union all statements also in the trial balance query , do you think maybe that can be a reason ??

How can i trace it like what is not working here , because the profilers are saying its the html , but i am debugging code and it takes maximum time for cr.execute !! So i am stuck here.

Penulis Jawaban Terbai

Also the query has multiple union all with same conditions !! and all with applied record rule conditions.

Avatar
Buang
Post Terkait Replies Tampilan Aktivitas
0
Jul 25
627
2
Feb 23
2014
1
Jun 18
6058
2
Jun 16
5887
0
Jun 15
3974