Welcome, Guest. Please login or register.
Did you miss your activation email?

Author Topic: LimeReport Ram Usage Bug  (Read 4080 times)

Proton Phoenix

  • Newbie
  • *
  • Posts: 15
    • View Profile
LimeReport Ram Usage Bug
« on: May 23, 2021, 08:38:20 am »
Hi ~~
i have a problem with Limereport and Qt framework

 
Code: [Select]
LimeReport::ReportEngine m_report(this);

    m_report.loadFromFile("C:/random/report.lrxml");
    m_report.createPreviewScene();
        m_report.previewReport();
       

when i open PreviewReport Ram usage grow from 74 mb to 93 mb
but when i close PreviewReport it will be 89 mb so it's only free 4 mb
the problem here is every time opening the PreviewReport will lead the software to eat more memory without clearing the previous one.
is there any solution??
i am using version 1.5.35

Subst

  • Sr. Member
  • ****
  • Posts: 450
    • View Profile
Re: LimeReport Ram Usage Bug
« Reply #1 on: May 23, 2021, 09:46:58 am »
Hi!
first why you need to call createPreviewScene() ?

createPreviewScene() usefull for customizing the preview, but you've used the standart preview window by calling previewReport

and where you destroing the result QGraphicsScene object?

Proton Phoenix

  • Newbie
  • *
  • Posts: 15
    • View Profile
Re: LimeReport Ram Usage Bug
« Reply #2 on: May 23, 2021, 09:50:02 am »
Thank you bro <3 i've installed limereport just today i am totally a beginner so i need to remove createpreview ... and destroy QGraphicsScene object !!
Thank you bro i will try that then i will comment here about the results <3

Subst

  • Sr. Member
  • ****
  • Posts: 450
    • View Profile
Re: LimeReport Ram Usage Bug
« Reply #3 on: May 23, 2021, 09:57:49 am »
it seems that problem exists
but if you don't wanna customize the preview you don't need to call createPreviewScene
it's must reduce the leak in your case

Proton Phoenix

  • Newbie
  • *
  • Posts: 15
    • View Profile
Re: LimeReport Ram Usage Bug
« Reply #4 on: May 23, 2021, 09:58:56 am »
Many Thanks bro <3


Yes when i removed createpreview .. when closing the preview it releasing 10 to 15 mb of ram usage but the problem still exist because it add 3 to 5 mb every time (opening the preview)
so can you tell me bro ~~ The best way to Destroy QGraphicsScene object!! ?
« Last Edit: May 23, 2021, 10:01:24 am by Proton Phoenix »

Subst

  • Sr. Member
  • ****
  • Posts: 450
    • View Profile
Re: LimeReport Ram Usage Bug
« Reply #5 on: May 23, 2021, 10:22:16 am »
no if you don't call the createPreviewScene() then nothing to delete

but previewReport steel have the mem leaks

Alex knows about problem and looking for solve

Proton Phoenix

  • Newbie
  • *
  • Posts: 15
    • View Profile
Re: LimeReport Ram Usage Bug
« Reply #6 on: May 23, 2021, 10:27:24 am »
<3 Thank you so much bro for helping me <3
okay i will wait Alex for fixing this memory leaks

-- Great Support from you bro Thank you

Subst

  • Sr. Member
  • ****
  • Posts: 450
    • View Profile
Re: LimeReport Ram Usage Bug
« Reply #7 on: May 25, 2021, 12:06:43 pm »
Alex has fixed the memory leak
it's seem work better
let's try 1.5.86

Proton Phoenix

  • Newbie
  • *
  • Posts: 15
    • View Profile
Re: LimeReport Ram Usage Bug
« Reply #8 on: May 25, 2021, 01:48:58 pm »
Thank you so much bro <3 great support from you <3

Subst

  • Sr. Member
  • ****
  • Posts: 450
    • View Profile
Re: LimeReport Ram Usage Bug
« Reply #9 on: May 25, 2021, 02:01:44 pm »
It's support from Alex
I just have some time right now to answer you :)
Alex hasn't one

Arin Alex

  • Developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 1005
    • View Profile
Re: LimeReport Ram Usage Bug
« Reply #10 on: May 26, 2021, 10:27:44 am »
Proton Phoenix, Hi I've fixed the memory leak and pushed the changes to github. You can check it.