Benchmarked with the "Set 40 panels as content" action in
BasicPerformanceTest. This is really a worst case scenario since it
doesn't do anything else than create lots of components, whereas more
common use cases would spend more time updating existing components or
executing business logic instead.
Without this patch, each action spent about 6 ms creating reference
diffstate values, making up about 20% of the total processing time. With
the patch applied, the time (including the new map lookup) was reduced
to around 0.2 ms and the total processing time was also reduced
accordingly.
Change-Id: If22a73b591b87793c78cb360bcfa8e030f003730
* ConnectorTracker.getConnector() is now DnDService-aware
* Deprecated LCM.getDragAndDropService() is removed
* LCM.getConnector() simply delegates to ConnectorTracker.getConnector()
Change-Id: I9627d50f7386ead8d92ccbba27b4a558c03076c7
Refactored how all requests are handled by VaadinServlet and VaadinPortlet (#11192)
* Handling is now based on a list of RequestHandlers in VaadinService
* Request handling logic has been moved to VaadinService
* Users can customize the list by adding own (service level) request handlers
* For users specific request handlers you can still use the request handlers in VaadinSession
* Deprecated RequestType - all handlers are given the opportunity to handle a request until one of them chooses to handle it. RequestType makes no sense as it does not tell which handler will handle the request.
* Removed serveStaticResource which has never been used
Change-Id: Ia7d088535e46430ca8adf631d3f1dd944b9d51e2
Fixed locking in RequestHandlers and documented that RequestHandlers are called without locking (#9945)
* Added SynchronizedRequestHandler which locks the session for the whole request
* Made request handlers which do not do do heavy IO implement SynchronizedRequestHandler
* Fixed locking for GlobalResourceHandler, ConnectorResourceHandler, PublishedFileHandler
Change-Id: I0e7b442a9392828f1930685f194dc4f898d0f525
Removed CommunicationManager and PortletCommunicationManager
* Moved AbstractCommunicationManager abstract methods
getThemeResourceAsStream and createBootstrapHandler to VaadinService
* Made ACM non-abstract and renamed to LegacyCommunicationManager
* Lifted anonymous inner BootstrapHandler subclasses into named public classes
Change-Id: I31739ce8a506d572e75ca8cd5509be215e01693d
* Move UIDL writing from AbstractCommunicationManager to UidlWriter
* Move request handling from ACM to RequestHandlers
* Move server RPC message handling to ServerRpcHandler
* Move portlet event notifications to PortletListenerNotifier (a RequestHandler)
* Communication handlers reside in c.v.server.communication
Change-Id: I087e923dbdf88c6b3fcaafbdb7f685d9d3dad0c1
Moved StreamVariable handling from AbstractCommunicationManager to
ConnectorTracker to prevent untimely unregistrations through other UIs
within the same session (#10112)
Change-Id: Id04c97970325be65b0b3c63756a2f2e731dd60d2
Refactor heartbeat handling and inactive UI/session closing (#10252)
* Package-private VaadinService.cleanupSession() handles these, called from VaadinServlet and VaadinPortlet at the end of a request
* UI detach() called when removing from the session (#9755)
* UIs can be explicitly closed; UIs marked as closed are removed at the end of the request (#10249)
* Remove UI cleanup events and listeners in favor of detach events (#10251)
Change-Id: I1f994c43bd2fc5fe7f99f7152c9db35927235291
Replaced ComponentErrorHandler with generic ErrorHandler (#10231)
* Replaced AbstractComponent ErrorHandler with ClientConnector level error handler. Now uses the same ErrorHandler as other parts of the framework.
* Made error handling hierarchical so that the error handler of the connector where the error occured or its ancestors is used. Falls back to VaadinSession ErrorHandler.
* Changed ErrorEvent to be a class as all other events in the framework
* Renamed ErrorListener to ErrorHandler and DefaultErrorListener to DefaultErrorHandler for consistency
* Unified error handling in AbstractCommunicationManager
* Unified error handling in VaadinServlet and VaadinPortlet
* Removed superfluous ErrorEvent implementations (#10232)
Change-Id: Ied518e05209fe54685f4bebab0709b1cd5584fd1