When you start a new project as "Debug using Hotswap Agent" in IntelliJ, hotswapping works and the open view is updated.
However, if you stop the server and start it again, then the view is never updated anymore after a change. A manual refresh updates the view.
The cause seems to be that Hotswapper relies on SessionInitEvent events to track open sessions but no such event is fired for the session that already exists in the server / was persisted during restart.
Expected behavior
It always works
Minimal reproducible example
New project
"Debug using Hotswap Agent" in IntelliJ
Edit code
Stop the server
"Debug using Hotswap Agent" in IntelliJ
Edit code
Versions
Hilla: 24.5-SNAPSHOT
Flow: 24.5-SNAPSHOT
Vaadin: 24.5-SNAPSHOT
Copilot: 24.5-SNAPSHOT
Frontend Hotswap: Disabled, using pre-built bundle
OS: aarch64 Mac OS X 14.6.1
Java: JetBrains s.r.o. 21.0.3
Browser: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/129.0.0.0 Safari/537.36
Java Hotswap: false
IDE Plugin: ☑ 1.0.0.eap42
Description of the bug
When you start a new project as "Debug using Hotswap Agent" in IntelliJ, hotswapping works and the open view is updated. However, if you stop the server and start it again, then the view is never updated anymore after a change. A manual refresh updates the view.
The cause seems to be that
Hotswapper
relies onSessionInitEvent
events to track open sessions but no such event is fired for the session that already exists in the server / was persisted during restart.Expected behavior
It always works
Minimal reproducible example
Versions
Hilla: 24.5-SNAPSHOT Flow: 24.5-SNAPSHOT Vaadin: 24.5-SNAPSHOT Copilot: 24.5-SNAPSHOT Frontend Hotswap: Disabled, using pre-built bundle OS: aarch64 Mac OS X 14.6.1 Java: JetBrains s.r.o. 21.0.3 Browser: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/129.0.0.0 Safari/537.36 Java Hotswap: false IDE Plugin: ☑ 1.0.0.eap42