Home Forums Report Bugs Memory Leak

Memory Leak

Viewing 9 posts - 1 through 9 (of 9 total)
  • #14828

    See this jsfiddle example http://jsfiddle.net/xhoycvsn/21/

    1) In this example when you click the ‘run’ button and then ‘reload’ and ‘run’ multiple times the browser memory increases and never releases.
    Our application is a single page JSF application. Is there any javascript call or other solution that can free up memory used by previously rendered canvasjs charts in this case?

    2) Our charts are very dynamic, the user can run a report with any number of charts and then go back and run a different report with completely different charts.
    Unfortunately since we are using JSF and a single page the dom does not change. How can we free the memory from previously rendered canvasjs charts?

    3) We understand the update() functionality which appends data to existing charts json (which we are already using in other cases), but that solution is not applicable in case this due the reason described in above points.

    #14861

    We have replied to you and your team via mail.


    Sanjoy Debnath
    Team CanvasJS

    #15586

    Sanjoy–Having the same issue as Alex, what was the solution to this problem?

    #15590

    @Austin,

    We have introduced a new destroy method in v1.9.8.1 which solves this problem. For more details please take a look at this documentation page.

    Destroy method in chart

    Bivek Singh,
    Team CanvasJS

    #22560

    Hi,

    We are facing the same issue, we are using destroy method also, but still increasing memory

    Application details
    ——————-
    we have a dashboard page, it will show dashboard for each level, while switch between levels memory is increasing continuously.

    in our application while switching between level we first destroy every existing charts using destroy method, then create new dashboard with charts, but still increasing memory

    #22567

    @mhdajmalik,

    I recommend you to use the latest version of CanvasJS – v2.2. Please check out our release blog for more information.

    If you are still facing the issue in the latest version, kindly provide the browser details and share a JSFiddle reproducing the issue you are facing so that we can understand your scenario better and help you out.

    __
    Priyanka M S
    Team CanvasJS

    #28360
    #32405

    Hey guys,
    First of all, thank you for the great tool that you have developed.

    I am a beginner in programming so most likely, it could be something that I am missing.

    I am currently using AJAX to pull data from a database and using your Scatter graph to display. It works fine until I use setInterval command to to call the same function that pulls data from database via AJAX call and render the chart again.

    The browser crashes after few loops as the browser is consuming too much memory. I have tried using the chart.destory() function, but that didn’t help either.
    I tried pasting the code, but it keeps on saying, I have been blocked.

    I have uploaded the javascript file in fiddle.
    https://jsfiddle.net/nrwcdeep/bLzacyhd/2/#&togetherjs=G5Qn4NLc6S

    • This reply was modified 3 years, 3 months ago by nrwcdeep. Reason: fiddle
    #32420

    @nrwcdeep,

    Can you kindly share a sample project reproducing the issue you are facing over Google-Drive or OneDrive so that we can look into your code, run it locally at our end to understand the scenario better and help you out?

    —-
    Manoj Mohan
    Team CanvasJS

Viewing 9 posts - 1 through 9 (of 9 total)

You must be logged in to reply to this topic.