Memory-footprint combobox (search autocomplete)

55 Views Asked by At

I use vaadin 7.4.6. I use a combobox filled with a list of cities (huge size).

This combobox is loaded from a backend service java.

But, the memory-footprint of this combobox is very consequent.

The users want to use auto-completion during the search of city.

How can I respond to this request ?

1

There are 1 best solutions below

0
Tatu Lund On

Vaadin 7 lacks built-in generic lazy backend support. Thus ComboBox loads all items at once. One of the main benefits of Vaadin 8 and other newer Vaadin versions over Vaadin 7 is added support for callbacks data providers, which makes it clearly better when implementing something you are trying to do.

With Vaadin 7 there exists mixed set of add-on solutions in Vaadin's Directory to tackle this short coming. Specific for your case is for example the AutocompleteField. There is also more generic solution of Lazy Query Container, that can be use with various components accepting container data source (Table, Grid and ComboBox).