Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

reuse collections in multiple grids #1397

Closed
gerpres opened this issue Sep 18, 2017 · 3 comments
Closed

reuse collections in multiple grids #1397

gerpres opened this issue Sep 18, 2017 · 3 comments
Assignees
Milestone

Comments

@gerpres
Copy link

gerpres commented Sep 18, 2017

is it allowed to reuse collections in multiple grids?
because currently _StoreMixin._cleanupCollection calls _renderedCollection.tracking.remove() which causes all handles to be removed - also tracking-handles not owned by the current grid

@dylans dylans added this to the 1.3.0 milestone Jan 5, 2018
@edhager
Copy link
Member

edhager commented Jan 22, 2018

It is desired that multiple grids can use the same collection and yes, that remove call is a problem. The handles are not owned by the grid but by the dstore/Trackable mixin. They are the listeners Trackable uses to monitor the collection's activity so Trackable can enhance those events with position information.

I'm not sure if this is a problem that can be easily fixed. It is going to take some thought. I would say for now, create multiple trackable collections if you can.

@edhager
Copy link
Member

edhager commented Jan 22, 2018

I wonder... Do those handles really need to be destroyed? Can't they live the entire life of the Trackable object?

@edhager edhager self-assigned this Jan 23, 2018
@edhager
Copy link
Member

edhager commented Jan 23, 2018

I removed the code that removes the handles held by the collection.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants