Change By: Tobias Mattsson (14/Nov/14 3:08 PM)
Description: The forward and include wrappers simulate servlet container dispatch operations by overriding path element getters and adding the appropriate request attributes. To properly implement these they need to adapt when a real dispatch is performed. When the servlet container performs a dispatch it doesn't add a wrapper at the front of the request chain, instead it changes the original request at the back of the chain (or inserts a wrapper inside the chain just after the original one). To detect this the Blossom wrappers probes the chain behind them to figure out if something has changed. They need to know this in order to decide whether they should override attributes and path elements.

While these calls are quick and simple they're called very frequently and need to be as fast as possible.

In BLOSSOM-130 a major improvement was made by letting the include wrapper switch itself off when a real include dispatch happens.

With this issue we should take the same approach for the forward wrapper. Other possible performance improvements should be investigated as well.

More specifically:

* ForwardRequestWrapper should stop overriding path elements when it sees a forward dispatch. This will remove the need to probe backwards for all path elements.
* When applied ForwardRequestWrapper should disable all other ForwardRequestWrappers already in chain since they will have no effect anyway.
* When applied ForwardRequestWrapper should disable all other IncludeRequestWrappers in chain to hide their attributes (bugfix).

* IncludeRequestWrapper should stop exposing attributes when it sees a forward dispatch, they must not be visible (bugfix).
* When applied IncludeRequestWrapper should disable all other IncludeRequestWrappers already in chain since they will have no effect anyway.

* SpecialAttributeRequestWrapper should have slots only for attributes that actually overridden.
* SpecialAttributeRequestWrapper should test with a prefix on attribute name before testing its overrides.
* SpecialAttributeRequestWrapper should not probe backwards to test for changed attributes since this is no longer necessary.
* SpecialAttributeRequestWrapper should skip wrapping attribute name enumeration when disabled.
* SpecialAttributeRequestWrapper should have attribute name enumeration methods inlined.
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira



----------------------------------------------------------------
For list details, see: http://www.magnolia-cms.com/community/mailing-lists.html
Alternatively, use our forums: http://forum.magnolia-cms.com/
To unsubscribe, E-mail to: <[email protected]>
----------------------------------------------------------------

Reply via email to