Upgrading from Vaadin 25.3 to 25.4
- Update the Version
- Build and Dependencies
- Java API Changes
- React Views and Browser-Callable Services
- Components
- AI Integration (Preview)
- Observability Kit
- Browserless Testing and TestBench
- Deprecations to Address Before Vaadin 26
Vaadin 25.4 is a minor release, and for most applications the upgrade is a version bump. It requires Node.js 26 instead of Node.js 24 for building the frontend. The other system requirements are the same as for Vaadin 25.3. This page lists the changes that can still need attention, followed by the deprecations to act on before Vaadin 26.
For what’s new in Vaadin 25.4, see the release notes. If you’re upgrading from Vaadin 24, follow Upgrading from Vaadin 24 first, and then this page.
Update the Version
Set the Vaadin version in the pom.xml or gradle.properties file:
Source code
XML
<vaadin.version>25.4.0</vaadin.version>XML
properties
properties
Use the latest 25.4 maintenance release, if one is available. See the list of releases on GitHub.
Build and Dependencies
- Node.js 26
-
The build needs Node.js 26. If the installed Node.js is older, Vaadin downloads Node.js 26 into the
~/.vaadindirectory. On minimal Linux images, such as slim Docker base images, install thelibatomic1package, which the Node.js 26 binaries need, or the package with the same library for your distribution. Update CI configurations and scripts that reference a Node.js 24 installation. - Spring dependencies
-
The
vaadin-springartifact no longer brings in Spring MVC, Spring WebSocket, and Hibernate Validator. The Vaadin Spring Boot starter includes them, so applications that use it need no changes. If your Spring Boot application depends onvaadin-springwithout the starter, addspring-boot-starter-webmvc,spring-boot-starter-websocket, andspring-boot-starter-validation. A Spring application without Spring Boot declaresspring-webmvcitself,spring-websocketfor push over WebSocket, and a Bean Validation implementation, such asorg.hibernate.validator:hibernate-validator, for Bean Validation. Without Spring WebSocket, push can’t use WebSocket in an embedded server and falls back to long polling. See Spring Dependencies of the Vaadin Spring Integration. - Spring Framework versions
-
The
vaadin-bomno longer manages the versions of Spring Framework, Micrometer, and Tomcat. Spring Boot applications get them from Spring Boot. A Spring application without Spring Boot has to manage them itself, for example by importing thespring-framework-bom. - Jandex indexes
-
Every Vaadin artifact contains its own Jandex index. The
flow-jandexartifact is removed, so remove any dependency on it. Thevaadin-jandexandvaadin-core-jandexartifacts are deprecated. See Quarkus. gentyref-
The
flow-serverartifact no longer depends oncom.vaadin.external:gentyref. If your code uses thecom.googlecode.gentyrefclasses, declare the dependency yourself. @JsModulewith a runtime URL-
On a component or the application shell, a
@JsModulevalue with a runtime URL, such as one with a leading/,context://, orhttps://, is no longer bundled. It’s loaded at runtime instead. To keep bundling a file in thefrontenddirectory, use a relative value, such as./foo.js. See Using Annotations.
Java API Changes
- Two-way signal bindings
-
AppLayout.bindDrawerOpened(),Checkbox.bindIndeterminate(), and thebindValue()methods ofGrid.asSingleSelect()andGrid.asMultiSelect()throw aNullPointerExceptionwhen the write callback isnull. Pass a callback that writes the user’s change to the signal. - Custom handlers for web components and translations
-
WebComponentProviderandTranslationFileRequestHandlerimplementSessionlessRequestHandlerinstead of extendingSynchronizedRequestHandler, so they run without a session. A subclass that overridessynchronizedHandleRequest()orcanHandleRequest()has to overridehandleRequest(VaadinRequest, VaadinResponse)instead, which has no session parameter. See Service Init Listener.
React Views and Browser-Callable Services
- TypeScript generator
-
The TypeScript code for browser-callable services is generated in Java, without Node.js. The
@vaadin/hilla-generator-*packages are removed, except for@vaadin/hilla-generator-utils. Vaadin removes the ones it added topackage.jsonitself. Remove any that you added yourself. Custom generator plugins aren’t supported. hilla-maven-plugin-
The
nodeCommandparameter of the plugin goals is removed. Delete it from thepom.xml. - OpenAPI file
-
The build no longer writes the
hilla-openapi.jsonfile. Tools that read it have to use another source. Thecom.vaadin.hilla.OpenAPIUtilclass is removed. To get the classes that browser-callable services use, callEndpointCodeGenerator.getInstance().getClassesUsedInEndpoints(). - Form models
-
Generated form models, such as
PersonModel, are constants built with@vaadin/hilla-models, instead of classes. The class-based models are removed from@vaadin/hilla-lit-form. Code that extends a generated model, creates one withnew, or imports model classes or symbols from@vaadin/hilla-lit-formhas to be updated, and thejavaTypeof the model metadata is nowjvmType. See Form Models Are Constants. @indexviews-
A view in an
@index.tsxfile can’t set therouteproperty of its view configuration. The build fails if it does. Rename the file, or move it to a directory that matches the route. See View Configuration.
Components
- Form Layout: labels aside
-
In auto-responsive mode with labels aside, fields placed directly in a Form Layout show their label beside the field when the labels fit. A Form Item isn’t needed for this. A field without a label still reserves the label column. Other components, such as buttons, start at the label column. Wrap such components in a Form Item, or style them with the
data-form-layout-has-labels-asideattribute. See Label Position. - Form Layout: label width in Lumo
-
In auto-responsive mode with labels aside, the default label width of a Form Item,
8em, is relative to the font size of the layout instead of the label. In Lumo, with the default font sizes, this makes the label column 128 pixels wide instead of 112 pixels. - Custom Field and Date Time Picker in Lumo
-
The helper text and error message are spaced like those of a Text Field. The
whitespacetheme variant of Custom Field has no effect, and the fields inside a Custom Field have no outer padding of their own. Remove CSS that compensates for the old spacing. - Card title
-
In the web component and the React component, a title element in the
titleslot takes precedence over thecardTitleproperty. SettingcardTitleno longer removes the slotted title, so remove the element to replace it. - Date Picker calendar
-
The focus,
tabindex,aria-label, andaria-disabledof a date are on an element with thedate-buttonclass androle="button"inside the date cell, and the month calendar hasrole="application". CSS that styles the focused date with[part~='date']:focushas to use thefocusedpart instead. Update end-to-end tests that read these attributes from the cell. This also concerns Date Time Picker. - Client-side
i18nproperty -
The
i18nproperty of web components, such as Date Picker and Upload, isundefineduntil the application sets it, instead of returning the default texts. Client-side code that reads texts from it, such asel.i18n.cancel, has to handleundefined. Setting a partial object still merges it with the defaults. - Grid cells
-
Grid renders its body cells with Lit. Body cells no longer have generated
idattributes. With lazy column rendering, the content of columns scrolled out of view is removed from the DOM, and overlays opened from it close and reopen. Subclasses of thevaadin-gridweb component can’t use the removed protected members_detailsCells,_configureDetailsCell(),_updateFirstAndLastColumnForRow(), and_generateCellPartNames().
AI Integration (Preview)
The AI integration is still a preview feature, behind the com.vaadin.experimental.aiComponents feature flag, and Vaadin 25.4 renames its classes and interfaces. AI and LLM in a type name are now written as Ai and Llm, also in nested types. For example, AIOrchestrator is now AiOrchestrator, LLMProvider.LLMRequest is LlmProvider.LlmRequest, and SpringAILLMProvider is SpringAiLlmProvider. LangChain4JLLMProvider is now LangChain4jLlmProvider, with a lowercase j.
In addition, DatabaseProvider is now QueryExecutor, and DatabaseProviderAITools is QueryExecutorAiTools.
Update the imports and the type references in your code. The packages and the method names are unchanged. See AI Support for details.
Observability Kit
ComponentResolverremoved-
The
com.vaadin.observability.micrometer.ComponentResolverclass is removed. CallgetComponent()on the RPC invocation event of Flow instead. For a field wrapped in aComposite, it returns the composite, so useComponentUtil.getInnermostComponent()to get the field that the resolver returned. - Spring dependencies
-
Applications that use the Observability Kit Spring Boot starter need no changes. Only an application that uses the
observability-kit-springartifact without the starter is affected, because the artifact no longer brings in Spring Framework. Such an application has to declarespring-context, andspring-webfor observing HTTP requests, for example with the versions from thespring-framework-bom.
Browserless Testing and TestBench
-
The Kotlin extension functions and properties that browserless testing declared on Flow and component types are removed. Kotlin tests call the remaining helpers as plain functions, such as
_get(button, TextField::class.java)instead ofbutton._get(TextField::class.java). Use Flow API, such asComponent.findAncestor()andComponentUtil.fireEvent(), instead of the removed helpers, andGridTesterorTreeGridTesterinstead of the removed Grid helpers. See Kotlin Extensions Removed. -
With auto upload turned off,
UploadTester.upload()anduploadAll()leave the files pending untilstartUpload()is called. -
UploadTester.removeFile(String)removes the last added file with the name. UseremoveFile(int)to remove a specific entry. -
test(uploadButton)returns anUploadButtonTester, which extendsButtonTester. Code that assigns the result to aButtonTester<Button>variable needs the new type, orvar. -
In TestBench,
SelectElement.getItems(),getItemsStream(), andgetSelectedOptionItem()no longer open the popup. CallopenPopup()before clicking a returned item.
See Upload Testers for examples and details.
Deprecations to Address Before Vaadin 26
Deprecated APIs still work in Vaadin 25.4, but most of them are removed in Vaadin 26. Replacing them now makes the next upgrade easier.
| Deprecated | Replacement |
|---|---|
|
|
|
|
|
|
|
|
The | The constructor that takes a |
|
|
|
|
| None. |
|
|
|
|
| None. The variant has no effect, so remove it. |
| None. The option has no effect, so remove it. Use |
The | The |
The | The |
The | None. Remove the dependency. |