Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: trigger refresh from client on hotswap with PUSH #20848

Merged
merged 2 commits into from
Jan 20, 2025

Conversation

mcollovati
Copy link
Collaborator

When PUSH is enabled, Flow Hotswapper uses it to refresh only the affected UIs. However, this can cause issues if Flow views contain code that relies on VaadinRequest thread local, since hotswap refresh start in a background thread. This change defines a client side event listener to trigger the refresh, and uses PUSH only to fires the event.

Fixes #20843

When PUSH is enabled, Flow Hotswapper uses it to refresh only the affected UIs.
However, this can cause issues if Flow views contain code that relies on
VaadinRequest thread local, since hotswap refresh start in a background thread.
This change defines a client side event listener to trigger the refresh,
and uses PUSH only to fires the event.

Fixes #20843
Copy link

github-actions bot commented Jan 15, 2025

Test Results

1 163 files  ± 0  1 163 suites  ±0   1h 33m 12s ⏱️ + 1m 43s
7 620 tests ± 0  7 564 ✅ +15  56 💤 ±0  0 ❌  - 2 
7 987 runs  +31  7 921 ✅ +45  66 💤 +1  0 ❌  - 2 

Results for commit c09fa73. ± Comparison against base commit 3fe8592.

♻️ This comment has been updated with latest results.

@mcollovati mcollovati marked this pull request as ready for review January 16, 2025 07:27
@mshabarov mshabarov merged commit 1e68cbe into main Jan 20, 2025
26 checks passed
@mshabarov mshabarov deleted the issues/20843-hotswapper_start_refresh_from_client branch January 20, 2025 08:42
vaadin-bot pushed a commit that referenced this pull request Jan 20, 2025
* fix: trigger refresh from client on hotswap with PUSH

When PUSH is enabled, Flow Hotswapper uses it to refresh only the affected UIs.
However, this can cause issues if Flow views contain code that relies on
VaadinRequest thread local, since hotswap refresh start in a background thread.
This change defines a client side event listener to trigger the refresh,
and uses PUSH only to fires the event.

Fixes #20843

* fix test
vaadin-bot pushed a commit that referenced this pull request Jan 20, 2025
* fix: trigger refresh from client on hotswap with PUSH

When PUSH is enabled, Flow Hotswapper uses it to refresh only the affected UIs.
However, this can cause issues if Flow views contain code that relies on
VaadinRequest thread local, since hotswap refresh start in a background thread.
This change defines a client side event listener to trigger the refresh,
and uses PUSH only to fires the event.

Fixes #20843

* fix test
vaadin-bot added a commit that referenced this pull request Jan 20, 2025
* fix: trigger refresh from client on hotswap with PUSH

When PUSH is enabled, Flow Hotswapper uses it to refresh only the affected UIs.
However, this can cause issues if Flow views contain code that relies on
VaadinRequest thread local, since hotswap refresh start in a background thread.
This change defines a client side event listener to trigger the refresh,
and uses PUSH only to fires the event.

Fixes #20843

* fix test

Co-authored-by: Marco Collovati <[email protected]>
vaadin-bot added a commit that referenced this pull request Jan 20, 2025
* fix: trigger refresh from client on hotswap with PUSH

When PUSH is enabled, Flow Hotswapper uses it to refresh only the affected UIs.
However, this can cause issues if Flow views contain code that relies on
VaadinRequest thread local, since hotswap refresh start in a background thread.
This change defines a client side event listener to trigger the refresh,
and uses PUSH only to fires the event.

Fixes #20843

* fix test

Co-authored-by: Marco Collovati <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

org.springframework.beans.factory.BeanCreationException on hotswap
4 participants