Pre loader

Issues about the memory debugging tools

Welcome to the SciChart Forums!

  • Please read our Question Asking Guidelines for how to format a good question
  • Some reputation is required to post answers. Get up-voted to avoid the spam filter!
  • We welcome community answers and upvotes. Every Q&A improves SciChart for everyone

WPF Forums | JavaScript Forums | Android Forums | iOS Forums

Answered
1
0

I have upgraded the SciChart version to v3.2 and tried to use the memory debugging tools. https://www.scichart.com/documentation/js/current/webframe.html#MemoryLeakDebugging.html

Below are few issues I found:

  • The example in the Memory Leak Debugging page got typo. It should
    import the MemoryUsageHelper instead of MemoryUsageTracker.

import { MemoryUsageTracker } from “scichart”;
MemoryUsageHelper.isMemoryUsageDebugEnabled = true;

  • When I turn on the memory debugger, I always got this warning when I
    move the crosshair in my chart. Is this expected?

DeletableEntity.js:70 Failed to remove
CursorTooltipSvgAnnotation_42d65afd-b859-4e14-b82d-7cda881cf1eb from
the Object Registry Probably it has been already deleted!

  • I also got the warning in point 2 when I try to delete annotation
    from the chart. I think it’s because I am trying to do something
    like this:

sciChartSurfaceRef.chartModifiers.remove(markerAnnotation);
markerAnnotation.delete();

The warning will be gone if I remove the second line above. Is it true that if I remove an annotation/dataSeries from a chart, I don’t need to remove that annotation/dataSeries manually afterward (i.e. annotation.delete()) ? Also, if I deleted a chart, I don’t need to delete it’s annotation/dataSeries manally, right?

Version
3.2
  • Andrew Burnett-Thompson
    Hi Quyen, issue with Documentation has been fixed (will be deployed later). Regarding your other questions, Jim on our JS team will look into them and reply when he has a fix / update for you. Thanks for reporting!
  • Jim Risen
    Hello. Thanks for noticing the issues and for the feedback. Warnings thrown by the Cursor or Rollover modifier may not be related to an actual memory leak, so you can just ignore them or verify if there are actual leaks to be safe. Regarding deleting annotation/dataSeries, in general, if you are removing an item from a collection, it still could be added to the collection again. But if you don’t need it you should call “delete” manually. Alternatively, you can pass a flag to the “remove” method to autodelete the removed item. E.g. “surface.renderableSeries.remove(lineSeries, true)”, where lineSeries would be deleted automatically.
  • You must to post comments
Best Answer
0
0

Hi Quyen

If you get SciChart.js version 3.2.509 or later this issue should be resolved.

From the changelog:

3.2.509 – 7th November 2023
removed some unnecessary memory warnings

Best regards
Andrew

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.