Repository navigation
fix: cache Polymer event handler lookup per deployment - #26973
Conversation
Decoding each @ClientCallable argument looked up the Polymer template event handler. When none is registered, the lookup fell back to a ServiceLoader classpath scan on every call. The result is now stored once per VaadinContext. Fixes #26972
vaadin-review-bot
left a comment
There was a problem hiding this comment.
✅ Nothing to flag — the changes look good.
|
|
Documentation Bot: No documentation needed for this change. The change caches the (already-existing) Polymer template event handler lookup per deployment instead of re-running a classpath Nothing was opened in vaadin/docs. If you disagree, the change has to be documented by hand there.
|
|
This ticket/PR has been released with Vaadin 25.4.0-alpha7. |



Fixes #26972
performance · flow-server · every app without Polymer templates that receives
@ClientCallable/$servercalls (Gridscrolling,ComboBoxfiltering, …)Each non-array argument of a
$servercall looked up the deprecated Polymer template event handler. When none is registered, which is the normal case, the lookup scanned the classpath withServiceLoaderon every call, because a missing result was never remembered. The lookup now happens once per deployment.Risks:
Context. Whether the Polymer handler exists is fixed when the
Lookupis built, so caching the result is safe. Caching negative results insideLookupitself was the alternative, but it would change lookup semantics for every service and both lookup implementations, for one hot caller.PublishedServerEventHandlerRpcHandlernow stores the handler lookup result, including a missing handler, in aVaadinContextattribute and reuses it.