Important Notice - Forums is archived
To simplify things and help our users to be more productive, we have archived the current forum and focus our efforts on helping developers on Stack Overflow. You can post new questions on Stack Overflow or join our Discord channel.

Vaadin lets you build secure, UX-first PWAs entirely in Java.
Free ebook & tutorial.
Table with Custom Lazy Container.Sortable: Problem when sorting fails
Hello,
I successfully implemented the Container interface to perform lazy loading from the backend.
I also implemented the Container.Sortable interface to provide custom sorting, as I need to send the sorting info to the backend.
My problem is when the user tries to sort a column from a table by clicking on it. The Table then calls the sort() method from the container and expects that the container sorted everything as it should. But in some special cases, the sorting can fail in the backend. The container does not sort the items but the Table still shows the sort indicator in the other direction, as it would have worked. Clicking again to sort will call sort() with the wrong sort direction.
The real question is: Is it possible to tell the Table that the sorting did not work? Or maybe just tell the Table to revert the sort direction to the state it was before?
I would really appreciate any help on this. Just comments to try to figure it out would also be nice. ;)
Sincerely
Jonas Hartmann