Bug. TreeGrid collapsing/expanding functionallity freezes
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 1.8k
- Forks
- 717
- Avg merge
- 2d 6h
- Merged PRs (30d)
- 3
Description
Good day,
Met one issue with Treegrid component on Vaadin 8+ versions.
We leave in very dinamic world where data is changing very fast and we can't be sure that one query that returned one result will respond with same result after one second.
Problem is simple. If we impementing AbstractHierarchicalDataProvider and query inside hasChildren metrod returned positive number of elements and then when user clicked on arrow to expand this element and fetchChildren returned empty stream, then tree table collapsing/expanding functionallity will be freezed.
Solution to cache data on hasChildren call is inappropriate solution, because we should cache a lot of data in memory, and we are not sure, that even it will be used by customer. And data will not be up-to-date.
Possibly related ticket from different angle
I'm attached zip with demonstration of that issue.
TreeGridDemo.zip
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by running the attached TreeGridDemo.zip and trace AbstractHierarchicalDataProvider behavior through hasChildren and fetchChildren. Reproduce the case where hasChildren reports children but fetchChildren returns an empty stream, then inspect the TreeGrid expansion and collapse handling. Done means the component remains usable after this data change and the scenario is covered by a regression test.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100