Opened 11 years ago

Closed 10 years ago

#12812 closed defect (invalid)

dojo.fx animation functions leak connections

Reported by: masnare Owned by: Bryan Forbes
Priority: blocker Milestone: tbd
Component: fx Version: 1.6.0
Keywords: tree fx wipeIn wipeOut animateProperty memory connection leak Cc:
Blocked By: Blocking:


Several functions in the dojo.fx code leak connections.

dojo.animateProperty in dojo/_base/fx.js creates 2 connections (one for beforeBegin, one for onAnimate) and neither are ever cleaned up.

dojo.wipeIn in dojo/fx.js creates a connection for onEnd and never cleans it up.

dojo.wipeOut in dojo/fx.js creates 2 connections (one for beforeBegin, one for onEnd) and never cleans them up.

The above listings are not comprehensive. There are other leaks in just these 2 files.

Since dijit.Tree uses wipeIn for node expansion, and wipeIn uses animateProperty, every tree node expansion leaks 3 connections. Likewise every tree node collapse leaks 4 connections. Sure, this is only a problem if the treeNode itself gets destroyed, but that's a supported workflow so this is a problem.

In my app, we have a dashboard that uses multiple (10) trees where each tree is a category navigation control for various event categories.

The trees update every 30 seconds by discarding the root node and re-retrieving the model (yes, this could be made more efficient, but that's beside the point). Since the trees start out expanded, that's 30 connection leaks every 30 seconds. Over the course of the day, that's 86,400 leaked connections. Obviously, that's a problem.

Change History (3)

comment:1 Changed 11 years ago by masnare

Sorry. You may be able to close this. On further investigation this may be an issue with the tree, or store, or model, or anything other than the fx code. I've been running a much simpler test of the animation code for a bit now with no memory increase.

comment:2 Changed 10 years ago by Colin Snover

Priority: highblocker

Bulk update of open ticket priorities.

comment:3 Changed 10 years ago by Bryan Forbes

Resolution: invalid
Status: newclosed
Note: See TracTickets for help on using tickets.