Modified: websites/production/tapestry/content/page-life-cycle.html
==============================================================================
--- websites/production/tapestry/content/page-life-cycle.html (original)
+++ websites/production/tapestry/content/page-life-cycle.html Tue Nov  8 
12:22:26 2016
@@ -36,18 +36,13 @@
 
   <div class="wrapper bs">
 
-        <div id="navigation"><div class="nav">
-<ul class="alternate"><li><a  href="index.html">Home</a></li><li><a  
href="getting-started.html">Getting Started</a></li><li><a  
href="documentation.html">Documentation</a></li><li><a  
href="download.html">Download</a></li><li><a  
href="about.html">About</a></li><li><a  
href="community.html">Community</a></li><li><a  class="external-link" 
href="http://www.apache.org/";>Apache</a></li><li><a  class="external-link" 
href="http://www.apache.org/foundation/sponsorship.html";>Sponsorship</a></li><li><a
  class="external-link" 
href="http://www.apache.org/foundation/thanks.html";>Thanks</a></li></ul>
-</div></div>
+        <div id="navigation"><div class="nav"><ul class="alternate"><li><a  
href="index.html">Home</a></li><li><a  href="getting-started.html">Getting 
Started</a></li><li><a  href="documentation.html">Documentation</a></li><li><a  
href="download.html">Download</a></li><li><a  
href="about.html">About</a></li><li><a  class="external-link" 
href="http://www.apache.org/licenses/LICENSE-2.0";>License</a></li><li><a  
href="community.html">Community</a></li><li><a  class="external-link" 
href="http://www.apache.org/security/";>Security</a></li><li><a  
class="external-link" href="http://www.apache.org/";>Apache</a></li><li><a  
class="external-link" 
href="http://www.apache.org/foundation/sponsorship.html";>Sponsorship</a></li><li><a
  class="external-link" 
href="http://www.apache.org/foundation/thanks.html";>Thanks</a></li></ul></div></div>
 
           <div id="top">
-            <div id="smallbanner"><div class="searchbox" 
style="float:right;margin: .3em 1em .1em 1em"><span style="color: #999; 
font-size: 90%">Tapestry docs, issues, wikis &amp; blogs:</span>
-<form enctype="application/x-www-form-urlencoded" method="get" 
action="http://tapestry.apache.org/search.html";>
-  <input type="text" name="q">
-  <input type="submit" value="Search">
-</form>
-
-</div><div class="emblem" style="float:left"><p><a  href="index.html"><span 
class="confluence-embedded-file-wrapper"><img class="confluence-embedded-image 
confluence-external-resource" 
src="http://tapestry.apache.org/images/tapestry_small.png"; 
data-image-src="http://tapestry.apache.org/images/tapestry_small.png";></span></a></p></div><div
 class="title" style="float:left; margin: 0 0 0 3em"><h1 
id="SmallBanner-PageTitle">Page Life Cycle</h1></div></div>
+            <div id="smallbanner"><div class="searchbox" 
style="float:right;margin: .3em 1em .1em 1em"><span style="color: #999; 
font-size: 90%">Tapestry docs, issues, wikis &amp; blogs:</span><form 
enctype="application/x-www-form-urlencoded" method="get" 
action="http://tapestry.apache.org/search.html";> 
+ <input type="text" name="q"> 
+ <input type="submit" value="Search"> 
+</form></div><div class="emblem" style="float:left"><p><a  
href="index.html"><span class="confluence-embedded-file-wrapper"><img 
class="confluence-embedded-image confluence-external-resource" 
src="http://tapestry.apache.org/images/tapestry_small.png"; 
data-image-src="http://tapestry.apache.org/images/tapestry_small.png";></span></a></p></div><div
 class="title" style="float:left; margin: 0 0 0 3em"><h1 
id="SmallBanner-PageTitle">Page Life Cycle</h1></div></div>
       <div class="clearer"></div>
       </div>
 
@@ -59,73 +54,43 @@
       </div>
 
       <div id="content">
-                <div id="ConfluenceContent"><div class="aui-label" 
style="float:right" title="Related Articles">
-
-
-
-
-
-
-
-
-<h3>Related Articles</h3>
-
-<ul class="content-by-label"><li>
-        <div>
-                <span class="icon aui-icon aui-icon-small 
aui-iconfont-page-default" title="Page">Page:</span>        </div>
-
-        <div class="details">
-                        <a  href="page-navigation.html">Page Navigation</a>
-                
-                        
-                    </div>
-    </li><li>
-        <div>
-                <span class="icon aui-icon aui-icon-small 
aui-iconfont-page-default" title="Page">Page:</span>        </div>
-
-        <div class="details">
-                        <a  href="page-life-cycle.html">Page Life Cycle</a>
-                
-                        
-                    </div>
-    </li><li>
-        <div>
-                <span class="icon aui-icon aui-icon-small 
aui-iconfont-page-default" title="Page">Page:</span>        </div>
-
-        <div class="details">
-                        <a  href="component-rendering.html">Component 
Rendering</a>
-                
-                        
-                    </div>
-    </li><li>
-        <div>
-                <span class="icon aui-icon aui-icon-small 
aui-iconfont-page-default" title="Page">Page:</span>        </div>
-
-        <div class="details">
-                        <a  href="component-events.html">Component Events</a>
-                
-                        
-                    </div>
-    </li><li>
-        <div>
-                <span class="icon aui-icon aui-icon-small 
aui-iconfont-page-default" title="Page">Page:</span>        </div>
-
-        <div class="details">
-                        <a  href="component-events-faq.html">Component Events 
FAQ</a>
-                
-                        
-                    </div>
-    </li><li>
-        <div>
-                <span class="icon aui-icon aui-icon-small 
aui-iconfont-page-default" title="Page">Page:</span>        </div>
-
-        <div class="details">
-                        <a  href="request-processing.html">Request 
Processing</a>
-                
-                        
-                    </div>
-    </li></ul>
-</div><div class="confluence-information-macro 
confluence-information-macro-note"><span class="aui-icon aui-icon-small 
aui-iconfont-warning confluence-information-macro-icon"></span><div 
class="confluence-information-macro-body"><p>This is an advanced topic. Most 
users won't ever need to know anything about the page life 
cycle.</p></div></div><p>&#160;</p><p>In Tapestry, you are free to develop your 
presentation objects, page and components classes, as ordinary objects, 
complete with instance variables and so forth.</p><p>This is somewhat 
revolutionary in terms of web development in Java. By comparison, using 
traditional servlets, or Struts, your presentation objects (Servlets, or Struts 
Actions, or the equivalent in other frameworks) are <em>stateless 
singletons</em>. That is, a <em>single</em> instance is created, and all 
incoming requests are threaded through that single instance. Because multiple 
requests are handled by many different threads, this means that the singleton's 
ins
 tance variables are useless ... any value written into an instance variable 
would immediately be overwritten by a different thread. Thus, it is necessary 
to use the Servlet API's HttpServletRequest object to store per-request data, 
and the HttpSession object to store data between requests.</p><p>Tapestry takes 
a very different approach.</p><p>In Tapestry, each page is a singleton, but 
with a <em>per thread</em> map of field names &amp; values that Tapestry 
invisibly manages for you.</p><p>With this approach, all the difficult, ugly 
issues related to multi-threading go by the wayside. Instead, familiar, simple 
coding practices (using ordinary methods and fields) can be used.</p><div 
class="confluence-information-macro 
confluence-information-macro-information"><span class="aui-icon aui-icon-small 
aui-iconfont-info confluence-information-macro-icon"></span><div 
class="confluence-information-macro-body"><p>Tapestry 5.0 and 5.1 used page 
pooling, rather than a singleton page with a per-t
 hread map, to achieve the same effect.</p></div></div><p>The page life cycle 
is quite simple:</p><ol><li>When first needed, a page is loaded. Loading a page 
involves instantiating the components of the page and connecting them 
together.</li><li>Once a page is loaded, it is <em>attached</em> to the current 
request. Remember that there will be many threads, each handling its own 
request to the same page.</li><li>At the end of a request, after a response has 
been sent to the client, the page is <em>detached</em> from the request. This 
is a chance to perform any cleanup needed for the page.</li></ol><h2 
id="PageLifeCycle-PageLifeCycleMethods">Page Life Cycle Methods</h2><p>There 
are rare occasions where it is useful for a component to perform some 
operations, usually some kind of initialization or caching, based on the life 
cycle of the page.</p><p>As with <a  href="component-rendering.html">component 
rendering</a>, you have the ability to make your components "aware" of these 
events by
  telling Tapestry what methods to invoke for each.</p><p>Page life cycle 
methods should take no parameters and return void.</p><p>You have the choice of 
attaching an annotation to a method, or simply using the method naming 
conventions:</p><div class="table-wrap"><table 
class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1" 
class="confluenceTh"><p>Annotation</p></th><th colspan="1" rowspan="1" 
class="confluenceTh"><p>Method Name</p></th><th colspan="1" rowspan="1" 
class="confluenceTh"><p>When Called</p></th></tr><tr><td colspan="1" 
rowspan="1" class="confluenceTd"><p>@<a  class="external-link" 
href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/annotations/PageLoaded.html";>PageLoaded</a></p></td><td
 colspan="1" rowspan="1" class="confluenceTd"><p>pageLoaded()</p></td><td 
colspan="1" rowspan="1" class="confluenceTd"><p>After the page is fully 
loaded</p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p>@<a 
 class="external-link" href="http://t
 
apestry.apache.org/current/apidocs/org/apache/tapestry5/annotations/PageAttached.html">PageAttached</a></p></td><td
 colspan="1" rowspan="1" class="confluenceTd"><p>pageAttached()</p></td><td 
colspan="1" rowspan="1" class="confluenceTd"><p>After the page is attached to 
the request.</p></td></tr><tr><td colspan="1" rowspan="1" 
class="confluenceTd">@<a  class="external-link" 
href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/annotations/PageReset.html";>PageReset</a></td><td
 colspan="1" rowspan="1" class="confluenceTd">pageReset()</td><td colspan="1" 
rowspan="1" class="confluenceTd">After the page is <em>activated</em>, except 
when requesting the same page</td></tr><tr><td colspan="1" rowspan="1" 
class="confluenceTd"><p>@<a  class="external-link" 
href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/annotations/PageDetached.html";>PageDetached</a></p></td><td
 colspan="1" rowspan="1" class="confluenceTd"><p>pageDetached()</p></td><td 
colspan="1" rowspan=
 "1" class="confluenceTd"><p>AFter the page is detached from the 
request.</p></td></tr></tbody></table></div><p>The @PageReset life cycle (only 
for Tapestry 5.2 and later) is invoked on a page render request when the page 
is linked to from some <em>other</em> page of the application (but <em>not</em> 
on a link to the same page), or upon a reload of the page in the browser. This 
is to allow the page to reset its state, if any, when a user returns to the 
page from some other part of the application.</p><h2 
id="PageLifeCycle-ComparisontoJavaServerPages">Comparison to JavaServer 
Pages</h2><p>JSPs also act as singletons. However, the individual JSP tags are 
pooled.</p><p>This is one of the areas where Tapestry can significantly 
outperform JSPs. Much of the code inside a compiled JSP class concerns getting 
tags from a tag pool, configuring the properties of the tag instance, using the 
tag instance, then cleaning up the tag instance and putting it back in the 
pool.</p><p>The operations Tape
 stry does once per request are instead executed dozens or potentially hundreds 
of times (depending the complexity of the page, and if any nested loops 
occur).</p><p>Pooling JSP tags is simply the wrong granularity.</p><p>Tapestry 
can also take advantage of its more coarse grained caching to optimize how data 
moves, via parameters, between components. This means that Tapestry pages will 
actually speed up after they render the first time.</p><h2 
id="PageLifeCycle-PagePoolConfiguration">Page Pool Configuration</h2><div 
class="confluence-information-macro confluence-information-macro-note"><span 
class="aui-icon aui-icon-small aui-iconfont-warning 
confluence-information-macro-icon"></span><div 
class="confluence-information-macro-body"><p>This related to versions of 
Tapestry prior to 5.2. Modern Tapestry uses an alternate approach that allows a 
single page instance to be shared across many request processing 
threads.</p></div></div><p>In Tapestry 5.0 and 5.1, a page pool is used to 
store 
 page instances. The pool is "keyed" on the name of the page (such as "start") 
and the <em>locale</em> for the page (such as "en" or "fr").</p><p>Within each 
key, Tapestry tracks the number of page instances that have been created, as 
well as the number that are in use (currently attached to a 
request).</p><p>When a page is first accessed in a request, it is taken from 
the pool. Tapestry has some <a  href="configuration.html">configuration 
values</a> that control the details of how and when page instances are 
created.</p><ul><li>If a free page instance is available, the page is marked in 
use and attached to the request.</li><li>If there are fewer page instances than 
the <em>soft limit</em>, then a new page instance is simply created and 
attached to the request.</li><li>If the soft limit has been reached, Tapestry 
will wait for a short period of time for a page instance to become available 
before creating a new page instance.</li><li>If the hard limit has been 
reached, Tapestry will t
 hrow an exception rather than create a new page instance.</li><li>Otherwise, 
Tapestry will create a new page instance.<br clear="none"> Thus a busy 
application will initially create pages up-to the soft limit (which defaults to 
five page instances). If the application continues to be pounded with requests, 
it will slow its request processing, using the soft wait time in an attempt to 
reuse an existing page instance.</li></ul><p>A truly busy application will 
continue to create new page instances as needed until the hard limit is 
reached.</p><p>Remember that all these configuration values are per key: the 
combination of page name and locale. Thus even with a hard limit of 20, you may 
eventually find that Tapestry has created 20 start page instances for locale 
"en" <em>and</em> 20 start page instances for locale "fr" (if your application 
is configured to support both English and French). Likewise, you may have 20 
instances for the start page, and 20 instances for the newaccount page.</
 p><p>Tapestry periodically checks its cache for page instances that have not 
been used recently (within a configurable window). Unused page instances are 
release to the garbage collector.</p><p>The end result is that you have quite a 
degree of tuning control over the process. If memory is a limitation and 
throughput can be sacrificed, try lowering the soft and hard limit and 
increasing the soft wait.</p><p>If performance is absolute and you have lots of 
memory, then increase the soft and hard limit and reduce the soft wait. This 
encourages Tapestry to create more page instances and not wait as long to 
re-use existing instances.</p></div>
+                <div id="ConfluenceContent"><div class="aui-label" 
style="float:right" title="Related Articles"><h3>Related Articles</h3><ul 
class="content-by-label"><li> 
+  <div> 
+   <span class="icon aui-icon aui-icon-small aui-iconfont-page-default" 
title="Page">Page:</span> 
+  </div> 
+  <div class="details"> 
+   <a  href="page-navigation.html">Page Navigation</a> 
+  </div> </li><li> 
+  <div> 
+   <span class="icon aui-icon aui-icon-small aui-iconfont-page-default" 
title="Page">Page:</span> 
+  </div> 
+  <div class="details"> 
+   <a  href="page-life-cycle.html">Page Life Cycle</a> 
+  </div> </li><li> 
+  <div> 
+   <span class="icon aui-icon aui-icon-small aui-iconfont-page-default" 
title="Page">Page:</span> 
+  </div> 
+  <div class="details"> 
+   <a  href="component-rendering.html">Component Rendering</a> 
+  </div> </li><li> 
+  <div> 
+   <span class="icon aui-icon aui-icon-small aui-iconfont-page-default" 
title="Page">Page:</span> 
+  </div> 
+  <div class="details"> 
+   <a  href="component-events.html">Component Events</a> 
+  </div> </li><li> 
+  <div> 
+   <span class="icon aui-icon aui-icon-small aui-iconfont-page-default" 
title="Page">Page:</span> 
+  </div> 
+  <div class="details"> 
+   <a  href="component-events-faq.html">Component Events FAQ</a> 
+  </div> </li><li> 
+  <div> 
+   <span class="icon aui-icon aui-icon-small aui-iconfont-page-default" 
title="Page">Page:</span> 
+  </div> 
+  <div class="details"> 
+   <a  href="request-processing.html">Request Processing</a> 
+  </div> </li></ul></div><div class="confluence-information-macro 
confluence-information-macro-note"><span class="aui-icon aui-icon-small 
aui-iconfont-warning confluence-information-macro-icon"></span><div 
class="confluence-information-macro-body"><p>This is an advanced topic. Most 
users won't ever need to know anything about the page life 
cycle.</p></div></div><p>&#160;</p><p>In Tapestry, you are free to develop your 
presentation objects, page and components classes, as ordinary objects, 
complete with instance variables and so forth.</p><p>This is somewhat 
revolutionary in terms of web development in Java. By comparison, using 
traditional servlets, or Struts, your presentation objects (Servlets, or Struts 
Actions, or the equivalent in other frameworks) are <em>stateless 
singletons</em>. That is, a <em>single</em> instance is created, and all 
incoming requests are threaded through that single instance. Because multiple 
requests are handled by many different threads, this means that 
 the singleton's instance variables are useless ... any value written into an 
instance variable would immediately be overwritten by a different thread. Thus, 
it is necessary to use the Servlet API's HttpServletRequest object to store 
per-request data, and the HttpSession object to store data between 
requests.</p><p>Tapestry takes a very different approach.</p><p>In Tapestry, 
each page is a singleton, but with a <em>per thread</em> map of field names 
&amp; values that Tapestry invisibly manages for you.</p><p>With this approach, 
all the difficult, ugly issues related to multi-threading go by the wayside. 
Instead, familiar, simple coding practices (using ordinary methods and fields) 
can be used.</p><div class="confluence-information-macro 
confluence-information-macro-information"><span class="aui-icon aui-icon-small 
aui-iconfont-info confluence-information-macro-icon"></span><div 
class="confluence-information-macro-body"><p>Tapestry 5.0 and 5.1 used page 
pooling, rather than a singleto
 n page with a per-thread map, to achieve the same 
effect.</p></div></div><p>The page life cycle is quite simple:</p><ol><li>When 
first needed, a page is loaded. Loading a page involves instantiating the 
components of the page and connecting them together.</li><li>Once a page is 
loaded, it is <em>attached</em> to the current request. Remember that there 
will be many threads, each handling its own request to the same 
page.</li><li>At the end of a request, after a response has been sent to the 
client, the page is <em>detached</em> from the request. This is a chance to 
perform any cleanup needed for the page.</li></ol><h2 
id="PageLifeCycle-PageLifeCycleMethods">Page Life Cycle Methods</h2><p>There 
are rare occasions where it is useful for a component to perform some 
operations, usually some kind of initialization or caching, based on the life 
cycle of the page.</p><p>As with <a  href="component-rendering.html">component 
rendering</a>, you have the ability to make your components "aware"
  of these events by telling Tapestry what methods to invoke for 
each.</p><p>Page life cycle methods should take no parameters and return 
void.</p><p>You have the choice of attaching an annotation to a method, or 
simply using the method naming conventions:</p><div class="table-wrap"><table 
class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1" 
class="confluenceTh"><p>Annotation</p></th><th colspan="1" rowspan="1" 
class="confluenceTh"><p>Method Name</p></th><th colspan="1" rowspan="1" 
class="confluenceTh"><p>When Called</p></th></tr><tr><td colspan="1" 
rowspan="1" class="confluenceTd"><p>@<a  class="external-link" 
href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/annotations/PageLoaded.html";>PageLoaded</a></p></td><td
 colspan="1" rowspan="1" class="confluenceTd"><p>pageLoaded()</p></td><td 
colspan="1" rowspan="1" class="confluenceTd"><p>After the page is fully 
loaded</p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p>@<a 
 class="external-l
 ink" 
href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/annotations/PageAttached.html";>PageAttached</a></p></td><td
 colspan="1" rowspan="1" class="confluenceTd"><p>pageAttached()</p></td><td 
colspan="1" rowspan="1" class="confluenceTd"><p>After the page is attached to 
the request.</p></td></tr><tr><td colspan="1" rowspan="1" 
class="confluenceTd">@<a  class="external-link" 
href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/annotations/PageReset.html";>PageReset</a></td><td
 colspan="1" rowspan="1" class="confluenceTd">pageReset()</td><td colspan="1" 
rowspan="1" class="confluenceTd">After the page is <em>activated</em>, except 
when requesting the same page</td></tr><tr><td colspan="1" rowspan="1" 
class="confluenceTd"><p>@<a  class="external-link" 
href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/annotations/PageDetached.html";>PageDetached</a></p></td><td
 colspan="1" rowspan="1" class="confluenceTd"><p>pageDetached()</p></td><td c
 olspan="1" rowspan="1" class="confluenceTd"><p>AFter the page is detached from 
the request.</p></td></tr></tbody></table></div><p>The @PageReset life cycle 
(only for Tapestry 5.2 and later) is invoked on a page render request when the 
page is linked to from some <em>other</em> page of the application (but 
<em>not</em> on a link to the same page), or upon a reload of the page in the 
browser. This is to allow the page to reset its state, if any, when a user 
returns to the page from some other part of the application.</p><h2 
id="PageLifeCycle-ComparisontoJavaServerPages">Comparison to JavaServer 
Pages</h2><p>JSPs also act as singletons. However, the individual JSP tags are 
pooled.</p><p>This is one of the areas where Tapestry can significantly 
outperform JSPs. Much of the code inside a compiled JSP class concerns getting 
tags from a tag pool, configuring the properties of the tag instance, using the 
tag instance, then cleaning up the tag instance and putting it back in the 
pool.</p><p>
 The operations Tapestry does once per request are instead executed dozens or 
potentially hundreds of times (depending the complexity of the page, and if any 
nested loops occur).</p><p>Pooling JSP tags is simply the wrong 
granularity.</p><p>Tapestry can also take advantage of its more coarse grained 
caching to optimize how data moves, via parameters, between components. This 
means that Tapestry pages will actually speed up after they render the first 
time.</p><h2 id="PageLifeCycle-PagePoolConfiguration">Page Pool 
Configuration</h2><div class="confluence-information-macro 
confluence-information-macro-note"><span class="aui-icon aui-icon-small 
aui-iconfont-warning confluence-information-macro-icon"></span><div 
class="confluence-information-macro-body"><p>This related to versions of 
Tapestry prior to 5.2. Modern Tapestry uses an alternate approach that allows a 
single page instance to be shared across many request processing 
threads.</p></div></div><p>In Tapestry 5.0 and 5.1, a page poo
 l is used to store page instances. The pool is "keyed" on the name of the page 
(such as "start") and the <em>locale</em> for the page (such as "en" or 
"fr").</p><p>Within each key, Tapestry tracks the number of page instances that 
have been created, as well as the number that are in use (currently attached to 
a request).</p><p>When a page is first accessed in a request, it is taken from 
the pool. Tapestry has some <a  href="configuration.html">configuration 
values</a> that control the details of how and when page instances are 
created.</p><ul><li>If a free page instance is available, the page is marked in 
use and attached to the request.</li><li>If there are fewer page instances than 
the <em>soft limit</em>, then a new page instance is simply created and 
attached to the request.</li><li>If the soft limit has been reached, Tapestry 
will wait for a short period of time for a page instance to become available 
before creating a new page instance.</li><li>If the hard limit has been reach
 ed, Tapestry will throw an exception rather than create a new page 
instance.</li><li>Otherwise, Tapestry will create a new page instance.<br 
clear="none"> Thus a busy application will initially create pages up-to the 
soft limit (which defaults to five page instances). If the application 
continues to be pounded with requests, it will slow its request processing, 
using the soft wait time in an attempt to reuse an existing page 
instance.</li></ul><p>A truly busy application will continue to create new page 
instances as needed until the hard limit is reached.</p><p>Remember that all 
these configuration values are per key: the combination of page name and 
locale. Thus even with a hard limit of 20, you may eventually find that 
Tapestry has created 20 start page instances for locale "en" <em>and</em> 20 
start page instances for locale "fr" (if your application is configured to 
support both English and French). Likewise, you may have 20 instances for the 
start page, and 20 instances for the
  newaccount page.</p><p>Tapestry periodically checks its cache for page 
instances that have not been used recently (within a configurable window). 
Unused page instances are release to the garbage collector.</p><p>The end 
result is that you have quite a degree of tuning control over the process. If 
memory is a limitation and throughput can be sacrificed, try lowering the soft 
and hard limit and increasing the soft wait.</p><p>If performance is absolute 
and you have lots of memory, then increase the soft and hard limit and reduce 
the soft wait. This encourages Tapestry to create more page instances and not 
wait as long to re-use existing instances.</p></div>
       </div>
 
       <div class="clearer"></div>

Modified: websites/production/tapestry/content/page-navigation.html
==============================================================================
--- websites/production/tapestry/content/page-navigation.html (original)
+++ websites/production/tapestry/content/page-navigation.html Tue Nov  8 
12:22:26 2016
@@ -46,7 +46,7 @@
 
   <div class="wrapper bs">
 
-        <div id="navigation"><div class="nav"><ul class="alternate"><li><a  
href="index.html">Home</a></li><li><a  href="getting-started.html">Getting 
Started</a></li><li><a  href="documentation.html">Documentation</a></li><li><a  
href="download.html">Download</a></li><li><a  
href="about.html">About</a></li><li><a  
href="community.html">Community</a></li><li><a  class="external-link" 
href="http://www.apache.org/";>Apache</a></li><li><a  class="external-link" 
href="http://www.apache.org/foundation/sponsorship.html";>Sponsorship</a></li><li><a
  class="external-link" 
href="http://www.apache.org/foundation/thanks.html";>Thanks</a></li></ul></div></div>
+        <div id="navigation"><div class="nav"><ul class="alternate"><li><a  
href="index.html">Home</a></li><li><a  href="getting-started.html">Getting 
Started</a></li><li><a  href="documentation.html">Documentation</a></li><li><a  
href="download.html">Download</a></li><li><a  
href="about.html">About</a></li><li><a  class="external-link" 
href="http://www.apache.org/licenses/LICENSE-2.0";>License</a></li><li><a  
href="community.html">Community</a></li><li><a  class="external-link" 
href="http://www.apache.org/security/";>Security</a></li><li><a  
class="external-link" href="http://www.apache.org/";>Apache</a></li><li><a  
class="external-link" 
href="http://www.apache.org/foundation/sponsorship.html";>Sponsorship</a></li><li><a
  class="external-link" 
href="http://www.apache.org/foundation/thanks.html";>Thanks</a></li></ul></div></div>
 
           <div id="top">
             <div id="smallbanner"><div class="searchbox" 
style="float:right;margin: .3em 1em .1em 1em"><span style="color: #999; 
font-size: 90%">Tapestry docs, issues, wikis &amp; blogs:</span><form 
enctype="application/x-www-form-urlencoded" method="get" 
action="http://tapestry.apache.org/search.html";> 

Modified: websites/production/tapestry/content/parallel-execution.html
==============================================================================
--- websites/production/tapestry/content/parallel-execution.html (original)
+++ websites/production/tapestry/content/parallel-execution.html Tue Nov  8 
12:22:26 2016
@@ -44,7 +44,7 @@
 
   <div class="wrapper bs">
 
-        <div id="navigation"><div class="nav"><ul class="alternate"><li><a  
href="index.html">Home</a></li><li><a  href="getting-started.html">Getting 
Started</a></li><li><a  href="documentation.html">Documentation</a></li><li><a  
href="download.html">Download</a></li><li><a  
href="about.html">About</a></li><li><a  
href="community.html">Community</a></li><li><a  class="external-link" 
href="http://www.apache.org/";>Apache</a></li><li><a  class="external-link" 
href="http://www.apache.org/foundation/sponsorship.html";>Sponsorship</a></li><li><a
  class="external-link" 
href="http://www.apache.org/foundation/thanks.html";>Thanks</a></li></ul></div></div>
+        <div id="navigation"><div class="nav"><ul class="alternate"><li><a  
href="index.html">Home</a></li><li><a  href="getting-started.html">Getting 
Started</a></li><li><a  href="documentation.html">Documentation</a></li><li><a  
href="download.html">Download</a></li><li><a  
href="about.html">About</a></li><li><a  class="external-link" 
href="http://www.apache.org/licenses/LICENSE-2.0";>License</a></li><li><a  
href="community.html">Community</a></li><li><a  class="external-link" 
href="http://www.apache.org/security/";>Security</a></li><li><a  
class="external-link" href="http://www.apache.org/";>Apache</a></li><li><a  
class="external-link" 
href="http://www.apache.org/foundation/sponsorship.html";>Sponsorship</a></li><li><a
  class="external-link" 
href="http://www.apache.org/foundation/thanks.html";>Thanks</a></li></ul></div></div>
 
           <div id="top">
             <div id="smallbanner"><div class="searchbox" 
style="float:right;margin: .3em 1em .1em 1em"><span style="color: #999; 
font-size: 90%">Tapestry docs, issues, wikis &amp; blogs:</span><form 
enctype="application/x-www-form-urlencoded" method="get" 
action="http://tapestry.apache.org/search.html";> 

Modified: websites/production/tapestry/content/parameter-type-coercion.html
==============================================================================
--- websites/production/tapestry/content/parameter-type-coercion.html (original)
+++ websites/production/tapestry/content/parameter-type-coercion.html Tue Nov  
8 12:22:26 2016
@@ -44,18 +44,13 @@
 
   <div class="wrapper bs">
 
-        <div id="navigation"><div class="nav">
-<ul class="alternate"><li><a  href="index.html">Home</a></li><li><a  
href="getting-started.html">Getting Started</a></li><li><a  
href="documentation.html">Documentation</a></li><li><a  
href="download.html">Download</a></li><li><a  
href="about.html">About</a></li><li><a  
href="community.html">Community</a></li><li><a  class="external-link" 
href="http://www.apache.org/";>Apache</a></li><li><a  class="external-link" 
href="http://www.apache.org/foundation/sponsorship.html";>Sponsorship</a></li><li><a
  class="external-link" 
href="http://www.apache.org/foundation/thanks.html";>Thanks</a></li></ul>
-</div></div>
+        <div id="navigation"><div class="nav"><ul class="alternate"><li><a  
href="index.html">Home</a></li><li><a  href="getting-started.html">Getting 
Started</a></li><li><a  href="documentation.html">Documentation</a></li><li><a  
href="download.html">Download</a></li><li><a  
href="about.html">About</a></li><li><a  class="external-link" 
href="http://www.apache.org/licenses/LICENSE-2.0";>License</a></li><li><a  
href="community.html">Community</a></li><li><a  class="external-link" 
href="http://www.apache.org/security/";>Security</a></li><li><a  
class="external-link" href="http://www.apache.org/";>Apache</a></li><li><a  
class="external-link" 
href="http://www.apache.org/foundation/sponsorship.html";>Sponsorship</a></li><li><a
  class="external-link" 
href="http://www.apache.org/foundation/thanks.html";>Thanks</a></li></ul></div></div>
 
           <div id="top">
-            <div id="smallbanner"><div class="searchbox" 
style="float:right;margin: .3em 1em .1em 1em"><span style="color: #999; 
font-size: 90%">Tapestry docs, issues, wikis &amp; blogs:</span>
-<form enctype="application/x-www-form-urlencoded" method="get" 
action="http://tapestry.apache.org/search.html";>
-  <input type="text" name="q">
-  <input type="submit" value="Search">
-</form>
-
-</div><div class="emblem" style="float:left"><p><a  href="index.html"><span 
class="confluence-embedded-file-wrapper"><img class="confluence-embedded-image 
confluence-external-resource" 
src="http://tapestry.apache.org/images/tapestry_small.png"; 
data-image-src="http://tapestry.apache.org/images/tapestry_small.png";></span></a></p></div><div
 class="title" style="float:left; margin: 0 0 0 3em"><h1 
id="SmallBanner-PageTitle">Parameter Type Coercion</h1></div></div>
+            <div id="smallbanner"><div class="searchbox" 
style="float:right;margin: .3em 1em .1em 1em"><span style="color: #999; 
font-size: 90%">Tapestry docs, issues, wikis &amp; blogs:</span><form 
enctype="application/x-www-form-urlencoded" method="get" 
action="http://tapestry.apache.org/search.html";> 
+ <input type="text" name="q"> 
+ <input type="submit" value="Search"> 
+</form></div><div class="emblem" style="float:left"><p><a  
href="index.html"><span class="confluence-embedded-file-wrapper"><img 
class="confluence-embedded-image confluence-external-resource" 
src="http://tapestry.apache.org/images/tapestry_small.png"; 
data-image-src="http://tapestry.apache.org/images/tapestry_small.png";></span></a></p></div><div
 class="title" style="float:left; margin: 0 0 0 3em"><h1 
id="SmallBanner-PageTitle">Parameter Type Coercion</h1></div></div>
       <div class="clearer"></div>
       </div>
 
@@ -67,73 +62,43 @@
       </div>
 
       <div id="content">
-                <div id="ConfluenceContent"><p><strong style="text-align: 
justify;">Type Coercion</strong><span style="color: rgb(0,0,0);">&#160;is the 
conversion of one type of object to a new object of a different type with 
similar content. Tapestry frequently must coerce objects from one type to 
another. A common example is the coercion of a string into an integer or a 
double.</span></p><p>See&#160;<a  href="type-coercion.html">Type Coercer 
Service</a> for the list of build-in coercions.</p><h2 
id="ParameterTypeCoercion-ParameterTypeCoercions">Parameter Type 
Coercions</h2><div class="aui-label" style="float:right" title="Related 
Articles">
-
-
-
-
-
-
-
-
-<h3>Related Articles</h3>
-
-<ul class="content-by-label"><li>
-        <div>
-                <span class="icon aui-icon aui-icon-small 
aui-iconfont-page-default" title="Page">Page:</span>        </div>
-
-        <div class="details">
-                        <a  href="type-coercion.html">Type Coercion</a>
-                
-                        
-                    </div>
-    </li><li>
-        <div>
-                <span class="icon aui-icon aui-icon-small 
aui-iconfont-page-default" title="Page">Page:</span>        </div>
-
-        <div class="details">
-                        <a  href="parameter-type-coercion.html">Parameter Type 
Coercion</a>
-                
-                        
-                    </div>
-    </li><li>
-        <div>
-                <span class="icon aui-icon aui-icon-small 
aui-iconfont-page-default" title="Page">Page:</span>        </div>
-
-        <div class="details">
-                        <a  href="enum-parameter-recipe.html">Enum Parameter 
Recipe</a>
-                
-                        
-                    </div>
-    </li><li>
-        <div>
-                <span class="icon aui-icon aui-icon-small 
aui-iconfont-page-default" title="Page">Page:</span>        </div>
-
-        <div class="details">
-                        <a  
href="supporting-informal-parameters.html">Supporting Informal Parameters</a>
-                
-                        
-                    </div>
-    </li><li>
-        <div>
-                <span class="icon aui-icon aui-icon-small 
aui-iconfont-page-default" title="Page">Page:</span>        </div>
-
-        <div class="details">
-                        <a  href="default-parameter.html">Default Parameter</a>
-                
-                        
-                    </div>
-    </li><li>
-        <div>
-                <span class="icon aui-icon aui-icon-small 
aui-iconfont-page-default" title="Page">Page:</span>        </div>
-
-        <div class="details">
-                        <a  href="component-parameters.html">Component 
Parameters</a>
-                
-                        
-                    </div>
-    </li></ul>
-</div><p>Tapestry automatically handles type coercions for <a  
href="component-parameters.html">component parameters</a>.</p><p>Type coercions 
occur when a value passed into a parameter (as bound in a template or in an 
annotation) does not match the type of the parameter.</p><p>For example, 
consider the Count component:</p><div class="code panel pdl" 
style="border-width: 1px;"><div class="codeContent panelContent pdl">
+                <div id="ConfluenceContent"><p><strong style="text-align: 
justify;">Type Coercion</strong><span style="color: rgb(0,0,0);">&#160;is the 
conversion of one type of object to a new object of a different type with 
similar content. Tapestry frequently must coerce objects from one type to 
another. A common example is the coercion of a string into an integer or a 
double.</span></p><p>See&#160;<a  href="type-coercion.html">Type Coercer 
Service</a> for the list of build-in coercions.</p><h2 
id="ParameterTypeCoercion-ParameterTypeCoercions">Parameter Type 
Coercions</h2><div class="aui-label" style="float:right" title="Related 
Articles"><h3>Related Articles</h3><ul class="content-by-label"><li> 
+  <div> 
+   <span class="icon aui-icon aui-icon-small aui-iconfont-page-default" 
title="Page">Page:</span> 
+  </div> 
+  <div class="details"> 
+   <a  href="type-coercion.html">Type Coercion</a> 
+  </div> </li><li> 
+  <div> 
+   <span class="icon aui-icon aui-icon-small aui-iconfont-page-default" 
title="Page">Page:</span> 
+  </div> 
+  <div class="details"> 
+   <a  href="parameter-type-coercion.html">Parameter Type Coercion</a> 
+  </div> </li><li> 
+  <div> 
+   <span class="icon aui-icon aui-icon-small aui-iconfont-page-default" 
title="Page">Page:</span> 
+  </div> 
+  <div class="details"> 
+   <a  href="enum-parameter-recipe.html">Enum Parameter Recipe</a> 
+  </div> </li><li> 
+  <div> 
+   <span class="icon aui-icon aui-icon-small aui-iconfont-page-default" 
title="Page">Page:</span> 
+  </div> 
+  <div class="details"> 
+   <a  href="supporting-informal-parameters.html">Supporting Informal 
Parameters</a> 
+  </div> </li><li> 
+  <div> 
+   <span class="icon aui-icon aui-icon-small aui-iconfont-page-default" 
title="Page">Page:</span> 
+  </div> 
+  <div class="details"> 
+   <a  href="default-parameter.html">Default Parameter</a> 
+  </div> </li><li> 
+  <div> 
+   <span class="icon aui-icon aui-icon-small aui-iconfont-page-default" 
title="Page">Page:</span> 
+  </div> 
+  <div class="details"> 
+   <a  href="component-parameters.html">Component Parameters</a> 
+  </div> </li></ul></div><p>Tapestry automatically handles type coercions for 
<a  href="component-parameters.html">component parameters</a>.</p><p>Type 
coercions occur when a value passed into a parameter (as bound in a template or 
in an annotation) does not match the type of the parameter.</p><p>For example, 
consider the Count component:</p><div class="code panel pdl" 
style="border-width: 1px;"><div class="codeContent panelContent pdl">
 <pre class="brush: java; gutter: false; theme: Default" 
style="font-size:12px;">public class Count
 {
     @Parameter

Modified: websites/production/tapestry/content/performance-and-clustering.html
==============================================================================
--- websites/production/tapestry/content/performance-and-clustering.html 
(original)
+++ websites/production/tapestry/content/performance-and-clustering.html Tue 
Nov  8 12:22:26 2016
@@ -36,18 +36,13 @@
 
   <div class="wrapper bs">
 
-        <div id="navigation"><div class="nav">
-<ul class="alternate"><li><a  href="index.html">Home</a></li><li><a  
href="getting-started.html">Getting Started</a></li><li><a  
href="documentation.html">Documentation</a></li><li><a  
href="download.html">Download</a></li><li><a  
href="about.html">About</a></li><li><a  
href="community.html">Community</a></li><li><a  class="external-link" 
href="http://www.apache.org/";>Apache</a></li><li><a  class="external-link" 
href="http://www.apache.org/foundation/sponsorship.html";>Sponsorship</a></li><li><a
  class="external-link" 
href="http://www.apache.org/foundation/thanks.html";>Thanks</a></li></ul>
-</div></div>
+        <div id="navigation"><div class="nav"><ul class="alternate"><li><a  
href="index.html">Home</a></li><li><a  href="getting-started.html">Getting 
Started</a></li><li><a  href="documentation.html">Documentation</a></li><li><a  
href="download.html">Download</a></li><li><a  
href="about.html">About</a></li><li><a  class="external-link" 
href="http://www.apache.org/licenses/LICENSE-2.0";>License</a></li><li><a  
href="community.html">Community</a></li><li><a  class="external-link" 
href="http://www.apache.org/security/";>Security</a></li><li><a  
class="external-link" href="http://www.apache.org/";>Apache</a></li><li><a  
class="external-link" 
href="http://www.apache.org/foundation/sponsorship.html";>Sponsorship</a></li><li><a
  class="external-link" 
href="http://www.apache.org/foundation/thanks.html";>Thanks</a></li></ul></div></div>
 
           <div id="top">
-            <div id="smallbanner"><div class="searchbox" 
style="float:right;margin: .3em 1em .1em 1em"><span style="color: #999; 
font-size: 90%">Tapestry docs, issues, wikis &amp; blogs:</span>
-<form enctype="application/x-www-form-urlencoded" method="get" 
action="http://tapestry.apache.org/search.html";>
-  <input type="text" name="q">
-  <input type="submit" value="Search">
-</form>
-
-</div><div class="emblem" style="float:left"><p><a  href="index.html"><span 
class="confluence-embedded-file-wrapper"><img class="confluence-embedded-image 
confluence-external-resource" 
src="http://tapestry.apache.org/images/tapestry_small.png"; 
data-image-src="http://tapestry.apache.org/images/tapestry_small.png";></span></a></p></div><div
 class="title" style="float:left; margin: 0 0 0 3em"><h1 
id="SmallBanner-PageTitle">Performance and Clustering</h1></div></div>
+            <div id="smallbanner"><div class="searchbox" 
style="float:right;margin: .3em 1em .1em 1em"><span style="color: #999; 
font-size: 90%">Tapestry docs, issues, wikis &amp; blogs:</span><form 
enctype="application/x-www-form-urlencoded" method="get" 
action="http://tapestry.apache.org/search.html";> 
+ <input type="text" name="q"> 
+ <input type="submit" value="Search"> 
+</form></div><div class="emblem" style="float:left"><p><a  
href="index.html"><span class="confluence-embedded-file-wrapper"><img 
class="confluence-embedded-image confluence-external-resource" 
src="http://tapestry.apache.org/images/tapestry_small.png"; 
data-image-src="http://tapestry.apache.org/images/tapestry_small.png";></span></a></p></div><div
 class="title" style="float:left; margin: 0 0 0 3em"><h1 
id="SmallBanner-PageTitle">Performance and Clustering</h1></div></div>
       <div class="clearer"></div>
       </div>
 
@@ -59,46 +54,25 @@
       </div>
 
       <div id="content">
-                <div id="ConfluenceContent"><p>Tapestry has a great 
<strong>performance</strong> story to tell. It's designed to take advantage of 
the speed of the modern JVM: no reflection, built to support a high level of 
concurrency without contention, and clean, lightweight code paths. In addition, 
there is built-in integrated GZIP content compression, far-future expires 
headers on static resources, JavaScript aggregation and minification, and an 
intentionally lightweight use of the HTTPSession. The result is a blistering 
fast framework. See <a  class="external-link" 
href="http://tapestry.apache.org/2011/06/13/tapestrys-performance-tested.html";>Tapestry's
 Performance Tested</a> for some objective numbers.</p><div class="aui-label" 
style="float:right" title="Related Articles">
-
-
-
-
-
-
-
-
-<h3>Related Articles</h3>
-
-<ul class="content-by-label"><li>
-        <div>
-                <span class="icon aui-icon aui-icon-small 
aui-iconfont-page-default" title="Page">Page:</span>        </div>
-
-        <div class="details">
-                        <a  href="performance-and-clustering.html">Performance 
and Clustering</a>
-                
-                        
-                    </div>
-    </li><li>
-        <div>
-                <span class="icon aui-icon aui-icon-small 
aui-iconfont-page-default" title="Page">Page:</span>        </div>
-
-        <div class="details">
-                        <a  href="session-storage.html">Session Storage</a>
-                
-                        
-                    </div>
-    </li><li>
-        <div>
-                <span class="icon aui-icon aui-icon-small 
aui-iconfont-page-default" title="Page">Page:</span>        </div>
-
-        <div class="details">
-                        <a  href="persistent-page-data.html">Persistent Page 
Data</a>
-                
-                        
-                    </div>
-    </li></ul>
-</div><h2 id="PerformanceandClustering-PerformanceTips">Performance 
Tips</h2><p>But even with all of Tapestry's built-in speediness, to really get 
top performance you'll need to be sure you're not hamstringing Tapestry. As a 
start, use the following checklist:</p><ul><li>Ensure (be absolutely sure) that 
<a  href="configuration.html">Production Mode</a> is turned on in 
production.</li><li>Minimize the use of the HTTPSession (see below), especially 
if you're using clustering.</li><li>Set <a  
href="configuration.html">tapestry.clustered-sessions</a> to "false" if you 
aren't using clustering.</li><li>Organize your JavaScript files into <a  
href="legacy-javascript.html">JavaScriptStacks</a>.</li><li>Ensure that your 
static resources (images, CSS, JavaScript) are being cached by the 
browser.<ul><li>Use "asset:" or "context:" <a  
href="component-parameters.html">binding prefixes</a> for all links to static 
resources (images, CSS, JavaScript).</li><li>Make sure that your firewall, 
proxy ser
 ver, load balancer, front-end web servers, and app servers all allow caching 
of static resources.</li><li>Ensure "cache-control" and "vary" HTTP headers are 
set correctly for your static resources.</li><li>Use a client-based tool (like 
Firebug) to examine the requests that your browser makes as you navigate 
through the site. You should <em>not</em> see repeated requests for static 
resources.</li></ul></li><li>Consider using a <a  class="external-link" 
href="http://en.wikipedia.org/wiki/Content_delivery_network"; 
rel="nofollow">Content Delivery Network</a> for static parts of your 
site.</li></ul><p>After all of the above issues are addressed, if you still 
have performance problems, they probably aren't related to Tapestry.</p><h2 
id="PerformanceandClustering-ClusteringversusStickySessions">Clustering versus 
Sticky Sessions</h2><p>For web applications, <strong>clustering</strong> is a 
load-balancing technique in which multiple application servers are set up to 
behave as one big server.
  Generally this requires replicating HttpSession data across the servers, to 
ensure that a user's web interactions will continue without interruption 
regardless of which server handles the next request. Session replication 
achieves very high reliability, but it incurs an extra performance cost (due to 
the serializing and deserializing of session data and the extra network traffic 
required).</p><p>In contrast, <strong>Sticky Sessions</strong> (also called 
<em>session persistence</em> or <em>sticky persistence</em>) is a load 
balancing technique in which each session is assigned to a particular server 
for the duration of the session. This approach doesn't require copying 
HTTPSession data between servers, so it's very scalable. But if a server goes 
down, all of its sessions are lost.</p><p>In general, the sticky sessions 
approach is the way to go when possible (that is, when performance is more 
important than session survival). It represents a much more efficient use of 
resources ... y
 ou are scaling <em>out</em> not <em>up</em>, which is always cheaper. It also 
means that you don't have to be as careful about what goes into the 
HTTPSession.</p><p><em>For details on setting up clustering and sticky 
sessions, see the documentation of whatever load balancer you are 
using.</em></p><h2 
id="PerformanceandClustering-Clustering">Clustering</h2><p>Tapestry is designed 
to be "a good citizen" of an application server that supports clustering. It is 
careful about what it writes into the HttpSession. The framework understands 
that the server that receives a request may not be the same one that rendered 
the page initially; this knowledge affects many code paths, and it guides the 
approach Tapestry takes to caching page and component properties.</p><p>Your 
part is to properly manage the objects put into the HttpSession (via 
@SessionAttribute, @SessionState or @Persist; see <a  
href="session-storage.html">Session Storage</a>):</p><ul><li>Don't store 
anything in the session that 
 you don't have to. Principally this means minimizing the use of @Persist (see 
<a  href="page-navigation.html">Page Activation</a> and <a  
href="using-select-with-a-list.html">Using Select With a List</a>), storing 
only IDs in the session rather than whole entities.</li><li>Where possible, 
persist only objects that are immutable (i.e., String, or a primitive or 
wrapper type).</li><li>Only put <em>serializable</em> objects into the 
session.</li><li>Make use of the @ImmutableSessionPersistedObject annotation 
and OptimizedSessionPersistedObject interface (both described 
below).</li></ul><p>Again, Tapestry is a good citizen, but from the application 
server's point of view, it's just another servlet application. The heavy 
lifting here is application server specific.</p><p></p><h2 
id="PerformanceandClustering-ClusteringIssues">Clustering Issues</h2>
+                <div id="ConfluenceContent"><p>Tapestry has a great 
<strong>performance</strong> story to tell. It's designed to take advantage of 
the speed of the modern JVM: no reflection, built to support a high level of 
concurrency without contention, and clean, lightweight code paths. In addition, 
there is built-in integrated GZIP content compression, far-future expires 
headers on static resources, JavaScript aggregation and minification, and an 
intentionally lightweight use of the HTTPSession. The result is a blistering 
fast framework. See <a  class="external-link" 
href="http://tapestry.apache.org/2011/06/13/tapestrys-performance-tested.html";>Tapestry's
 Performance Tested</a> for some objective numbers.</p><div class="aui-label" 
style="float:right" title="Related Articles"><h3>Related Articles</h3><ul 
class="content-by-label"><li> 
+  <div> 
+   <span class="icon aui-icon aui-icon-small aui-iconfont-page-default" 
title="Page">Page:</span> 
+  </div> 
+  <div class="details"> 
+   <a  href="performance-and-clustering.html">Performance and Clustering</a> 
+  </div> </li><li> 
+  <div> 
+   <span class="icon aui-icon aui-icon-small aui-iconfont-page-default" 
title="Page">Page:</span> 
+  </div> 
+  <div class="details"> 
+   <a  href="session-storage.html">Session Storage</a> 
+  </div> </li><li> 
+  <div> 
+   <span class="icon aui-icon aui-icon-small aui-iconfont-page-default" 
title="Page">Page:</span> 
+  </div> 
+  <div class="details"> 
+   <a  href="persistent-page-data.html">Persistent Page Data</a> 
+  </div> </li></ul></div><h2 
id="PerformanceandClustering-PerformanceTips">Performance Tips</h2><p>But even 
with all of Tapestry's built-in speediness, to really get top performance 
you'll need to be sure you're not hamstringing Tapestry. As a start, use the 
following checklist:</p><ul><li>Ensure (be absolutely sure) that <a  
href="configuration.html">Production Mode</a> is turned on in 
production.</li><li>Minimize the use of the HTTPSession (see below), especially 
if you're using clustering.</li><li>Set <a  
href="configuration.html">tapestry.clustered-sessions</a> to "false" if you 
aren't using clustering.</li><li>Organize your JavaScript files into <a  
href="legacy-javascript.html">JavaScriptStacks</a>.</li><li>Ensure that your 
static resources (images, CSS, JavaScript) are being cached by the 
browser.<ul><li>Use "asset:" or "context:" <a  
href="component-parameters.html">binding prefixes</a> for all links to static 
resources (images, CSS, JavaScript).</li><li>Make sure that your 
 firewall, proxy server, load balancer, front-end web servers, and app servers 
all allow caching of static resources.</li><li>Ensure "cache-control" and 
"vary" HTTP headers are set correctly for your static resources.</li><li>Use a 
client-based tool (like Firebug) to examine the requests that your browser 
makes as you navigate through the site. You should <em>not</em> see repeated 
requests for static resources.</li></ul></li><li>Consider using a <a  
class="external-link" 
href="http://en.wikipedia.org/wiki/Content_delivery_network"; 
rel="nofollow">Content Delivery Network</a> for static parts of your 
site.</li></ul><p>After all of the above issues are addressed, if you still 
have performance problems, they probably aren't related to Tapestry.</p><h2 
id="PerformanceandClustering-ClusteringversusStickySessions">Clustering versus 
Sticky Sessions</h2><p>For web applications, <strong>clustering</strong> is a 
load-balancing technique in which multiple application servers are set up to 
behave
  as one big server. Generally this requires replicating HttpSession data 
across the servers, to ensure that a user's web interactions will continue 
without interruption regardless of which server handles the next request. 
Session replication achieves very high reliability, but it incurs an extra 
performance cost (due to the serializing and deserializing of session data and 
the extra network traffic required).</p><p>In contrast, <strong>Sticky 
Sessions</strong> (also called <em>session persistence</em> or <em>sticky 
persistence</em>) is a load balancing technique in which each session is 
assigned to a particular server for the duration of the session. This approach 
doesn't require copying HTTPSession data between servers, so it's very 
scalable. But if a server goes down, all of its sessions are lost.</p><p>In 
general, the sticky sessions approach is the way to go when possible (that is, 
when performance is more important than session survival). It represents a much 
more efficient use
  of resources ... you are scaling <em>out</em> not <em>up</em>, which is 
always cheaper. It also means that you don't have to be as careful about what 
goes into the HTTPSession.</p><p><em>For details on setting up clustering and 
sticky sessions, see the documentation of whatever load balancer you are 
using.</em></p><h2 
id="PerformanceandClustering-Clustering">Clustering</h2><p>Tapestry is designed 
to be "a good citizen" of an application server that supports clustering. It is 
careful about what it writes into the HttpSession. The framework understands 
that the server that receives a request may not be the same one that rendered 
the page initially; this knowledge affects many code paths, and it guides the 
approach Tapestry takes to caching page and component properties.</p><p>Your 
part is to properly manage the objects put into the HttpSession (via 
@SessionAttribute, @SessionState or @Persist; see <a  
href="session-storage.html">Session Storage</a>):</p><ul><li>Don't store 
anything i
 n the session that you don't have to. Principally this means minimizing the 
use of @Persist (see <a  href="page-navigation.html">Page Activation</a> and <a 
 href="using-select-with-a-list.html">Using Select With a List</a>), storing 
only IDs in the session rather than whole entities.</li><li>Where possible, 
persist only objects that are immutable (i.e., String, or a primitive or 
wrapper type).</li><li>Only put <em>serializable</em> objects into the 
session.</li><li>Make use of the @ImmutableSessionPersistedObject annotation 
and OptimizedSessionPersistedObject interface (both described 
below).</li></ul><p>Again, Tapestry is a good citizen, but from the application 
server's point of view, it's just another servlet application. The heavy 
lifting here is application server specific.</p><p></p><h2 
id="PerformanceandClustering-ClusteringIssues">Clustering Issues</h2>
 
 <p>The Servlet API was designed with the intention that there would be only a 
modest amount of server-side state, and that the stored values would be 
individual numbers and strings, and thus, immutable.</p>
 

Modified: websites/production/tapestry/content/persistent-page-data.html
==============================================================================
--- websites/production/tapestry/content/persistent-page-data.html (original)
+++ websites/production/tapestry/content/persistent-page-data.html Tue Nov  8 
12:22:26 2016
@@ -46,7 +46,7 @@
 
   <div class="wrapper bs">
 
-        <div id="navigation"><div class="nav"><ul class="alternate"><li><a  
href="index.html">Home</a></li><li><a  href="getting-started.html">Getting 
Started</a></li><li><a  href="documentation.html">Documentation</a></li><li><a  
href="download.html">Download</a></li><li><a  
href="about.html">About</a></li><li><a  
href="community.html">Community</a></li><li><a  class="external-link" 
href="http://www.apache.org/";>Apache</a></li><li><a  class="external-link" 
href="http://www.apache.org/foundation/sponsorship.html";>Sponsorship</a></li><li><a
  class="external-link" 
href="http://www.apache.org/foundation/thanks.html";>Thanks</a></li></ul></div></div>
+        <div id="navigation"><div class="nav"><ul class="alternate"><li><a  
href="index.html">Home</a></li><li><a  href="getting-started.html">Getting 
Started</a></li><li><a  href="documentation.html">Documentation</a></li><li><a  
href="download.html">Download</a></li><li><a  
href="about.html">About</a></li><li><a  class="external-link" 
href="http://www.apache.org/licenses/LICENSE-2.0";>License</a></li><li><a  
href="community.html">Community</a></li><li><a  class="external-link" 
href="http://www.apache.org/security/";>Security</a></li><li><a  
class="external-link" href="http://www.apache.org/";>Apache</a></li><li><a  
class="external-link" 
href="http://www.apache.org/foundation/sponsorship.html";>Sponsorship</a></li><li><a
  class="external-link" 
href="http://www.apache.org/foundation/thanks.html";>Thanks</a></li></ul></div></div>
 
           <div id="top">
             <div id="smallbanner"><div class="searchbox" 
style="float:right;margin: .3em 1em .1em 1em"><span style="color: #999; 
font-size: 90%">Tapestry docs, issues, wikis &amp; blogs:</span><form 
enctype="application/x-www-form-urlencoded" method="get" 
action="http://tapestry.apache.org/search.html";> 

Modified: websites/production/tapestry/content/persistent-state.html
==============================================================================
--- websites/production/tapestry/content/persistent-state.html (original)
+++ websites/production/tapestry/content/persistent-state.html Tue Nov  8 
12:22:26 2016
@@ -36,18 +36,13 @@
 
   <div class="wrapper bs">
 
-        <div id="navigation"><div class="nav">
-<ul class="alternate"><li><a  href="index.html">Home</a></li><li><a  
href="getting-started.html">Getting Started</a></li><li><a  
href="documentation.html">Documentation</a></li><li><a  
href="download.html">Download</a></li><li><a  
href="about.html">About</a></li><li><a  
href="community.html">Community</a></li><li><a  class="external-link" 
href="http://www.apache.org/";>Apache</a></li><li><a  class="external-link" 
href="http://www.apache.org/foundation/sponsorship.html";>Sponsorship</a></li><li><a
  class="external-link" 
href="http://www.apache.org/foundation/thanks.html";>Thanks</a></li></ul>
-</div></div>
+        <div id="navigation"><div class="nav"><ul class="alternate"><li><a  
href="index.html">Home</a></li><li><a  href="getting-started.html">Getting 
Started</a></li><li><a  href="documentation.html">Documentation</a></li><li><a  
href="download.html">Download</a></li><li><a  
href="about.html">About</a></li><li><a  class="external-link" 
href="http://www.apache.org/licenses/LICENSE-2.0";>License</a></li><li><a  
href="community.html">Community</a></li><li><a  class="external-link" 
href="http://www.apache.org/security/";>Security</a></li><li><a  
class="external-link" href="http://www.apache.org/";>Apache</a></li><li><a  
class="external-link" 
href="http://www.apache.org/foundation/sponsorship.html";>Sponsorship</a></li><li><a
  class="external-link" 
href="http://www.apache.org/foundation/thanks.html";>Thanks</a></li></ul></div></div>
 
           <div id="top">
-            <div id="smallbanner"><div class="searchbox" 
style="float:right;margin: .3em 1em .1em 1em"><span style="color: #999; 
font-size: 90%">Tapestry docs, issues, wikis &amp; blogs:</span>
-<form enctype="application/x-www-form-urlencoded" method="get" 
action="http://tapestry.apache.org/search.html";>
-  <input type="text" name="q">
-  <input type="submit" value="Search">
-</form>
-
-</div><div class="emblem" style="float:left"><p><a  href="index.html"><span 
class="confluence-embedded-file-wrapper"><img class="confluence-embedded-image 
confluence-external-resource" 
src="http://tapestry.apache.org/images/tapestry_small.png"; 
data-image-src="http://tapestry.apache.org/images/tapestry_small.png";></span></a></p></div><div
 class="title" style="float:left; margin: 0 0 0 3em"><h1 
id="SmallBanner-PageTitle">Persistent State</h1></div></div>
+            <div id="smallbanner"><div class="searchbox" 
style="float:right;margin: .3em 1em .1em 1em"><span style="color: #999; 
font-size: 90%">Tapestry docs, issues, wikis &amp; blogs:</span><form 
enctype="application/x-www-form-urlencoded" method="get" 
action="http://tapestry.apache.org/search.html";> 
+ <input type="text" name="q"> 
+ <input type="submit" value="Search"> 
+</form></div><div class="emblem" style="float:left"><p><a  
href="index.html"><span class="confluence-embedded-file-wrapper"><img 
class="confluence-embedded-image confluence-external-resource" 
src="http://tapestry.apache.org/images/tapestry_small.png"; 
data-image-src="http://tapestry.apache.org/images/tapestry_small.png";></span></a></p></div><div
 class="title" style="float:left; margin: 0 0 0 3em"><h1 
id="SmallBanner-PageTitle">Persistent State</h1></div></div>
       <div class="clearer"></div>
       </div>
 

Modified: websites/production/tapestry/content/pipelinebuilder-service.html
==============================================================================
--- websites/production/tapestry/content/pipelinebuilder-service.html (original)
+++ websites/production/tapestry/content/pipelinebuilder-service.html Tue Nov  
8 12:22:26 2016
@@ -44,18 +44,13 @@
 
   <div class="wrapper bs">
 
-        <div id="navigation"><div class="nav">
-<ul class="alternate"><li><a  href="index.html">Home</a></li><li><a  
href="getting-started.html">Getting Started</a></li><li><a  
href="documentation.html">Documentation</a></li><li><a  
href="download.html">Download</a></li><li><a  
href="about.html">About</a></li><li><a  
href="community.html">Community</a></li><li><a  class="external-link" 
href="http://www.apache.org/";>Apache</a></li><li><a  class="external-link" 
href="http://www.apache.org/foundation/sponsorship.html";>Sponsorship</a></li><li><a
  class="external-link" 
href="http://www.apache.org/foundation/thanks.html";>Thanks</a></li></ul>
-</div></div>
+        <div id="navigation"><div class="nav"><ul class="alternate"><li><a  
href="index.html">Home</a></li><li><a  href="getting-started.html">Getting 
Started</a></li><li><a  href="documentation.html">Documentation</a></li><li><a  
href="download.html">Download</a></li><li><a  
href="about.html">About</a></li><li><a  class="external-link" 
href="http://www.apache.org/licenses/LICENSE-2.0";>License</a></li><li><a  
href="community.html">Community</a></li><li><a  class="external-link" 
href="http://www.apache.org/security/";>Security</a></li><li><a  
class="external-link" href="http://www.apache.org/";>Apache</a></li><li><a  
class="external-link" 
href="http://www.apache.org/foundation/sponsorship.html";>Sponsorship</a></li><li><a
  class="external-link" 
href="http://www.apache.org/foundation/thanks.html";>Thanks</a></li></ul></div></div>
 
           <div id="top">
-            <div id="smallbanner"><div class="searchbox" 
style="float:right;margin: .3em 1em .1em 1em"><span style="color: #999; 
font-size: 90%">Tapestry docs, issues, wikis &amp; blogs:</span>
-<form enctype="application/x-www-form-urlencoded" method="get" 
action="http://tapestry.apache.org/search.html";>
-  <input type="text" name="q">
-  <input type="submit" value="Search">
-</form>
-
-</div><div class="emblem" style="float:left"><p><a  href="index.html"><span 
class="confluence-embedded-file-wrapper"><img class="confluence-embedded-image 
confluence-external-resource" 
src="http://tapestry.apache.org/images/tapestry_small.png"; 
data-image-src="http://tapestry.apache.org/images/tapestry_small.png";></span></a></p></div><div
 class="title" style="float:left; margin: 0 0 0 3em"><h1 
id="SmallBanner-PageTitle">PipelineBuilder Service</h1></div></div>
+            <div id="smallbanner"><div class="searchbox" 
style="float:right;margin: .3em 1em .1em 1em"><span style="color: #999; 
font-size: 90%">Tapestry docs, issues, wikis &amp; blogs:</span><form 
enctype="application/x-www-form-urlencoded" method="get" 
action="http://tapestry.apache.org/search.html";> 
+ <input type="text" name="q"> 
+ <input type="submit" value="Search"> 
+</form></div><div class="emblem" style="float:left"><p><a  
href="index.html"><span class="confluence-embedded-file-wrapper"><img 
class="confluence-embedded-image confluence-external-resource" 
src="http://tapestry.apache.org/images/tapestry_small.png"; 
data-image-src="http://tapestry.apache.org/images/tapestry_small.png";></span></a></p></div><div
 class="title" style="float:left; margin: 0 0 0 3em"><h1 
id="SmallBanner-PageTitle">PipelineBuilder Service</h1></div></div>
       <div class="clearer"></div>
       </div>
 
@@ -67,55 +62,31 @@
       </div>
 
       <div id="content">
-                <div id="ConfluenceContent"><p>The <strong>PipelineBuilder 
Service</strong> is a service used to create pipelines, also known as 
<em>filter chains</em>. An example of this is the Filter and FilterChain 
interfaces inside the Servlet API.</p><div class="aui-label" 
style="float:right" title="Related Articles">
-
-
-
-
-
-
-
-
-<h3>Related Articles</h3>
-
-<ul class="content-by-label"><li>
-        <div>
-                <span class="icon aui-icon aui-icon-small 
aui-iconfont-page-default" title="Page">Page:</span>        </div>
-
-        <div class="details">
-                        <a  href="shadowbuilder-service.html">ShadowBuilder 
Service</a>
-                
-                        
-                    </div>
-    </li><li>
-        <div>
-                <span class="icon aui-icon aui-icon-small 
aui-iconfont-page-default" title="Page">Page:</span>        </div>
-
-        <div class="details">
-                        <a  
href="strategybuilder-service.html">StrategyBuilder Service</a>
-                
-                        
-                    </div>
-    </li><li>
-        <div>
-                <span class="icon aui-icon aui-icon-small 
aui-iconfont-page-default" title="Page">Page:</span>        </div>
-
-        <div class="details">
-                        <a  
href="pipelinebuilder-service.html">PipelineBuilder Service</a>
-                
-                        
-                    </div>
-    </li><li>
-        <div>
-                <span class="icon aui-icon aui-icon-small 
aui-iconfont-page-default" title="Page">Page:</span>        </div>
-
-        <div class="details">
-                        <a  href="chainbuilder-service.html">ChainBuilder 
Service</a>
-                
-                        
-                    </div>
-    </li></ul>
-</div><p>In this pattern, an existing service is decorated with a filter. The 
filter will delegate to the service, but has the chance to alter or replace 
parameters before invoking the method, and can perform operations before 
returning. This is similar to <a  href="chainbuilder-service.html">chain of 
responsibility</a>, but differs in that there are two interfaces (the service 
interface and the filter interface) and that each filter invokes the next 
filter via the service interface. In contrast, in the chain of responsibility, 
the chain invokes each method, which must return before the next command in the 
chain is invoked.</p><p>The service interface and the filter interface are 
closely related: the filter interface must match the service interface method 
for method, but each method of the filter interface must have an additional 
parameter whose type is the service interface. For example, a pipeline that 
performed string transformations might use the following interfaces:</p><div c
 lass="code panel pdl" style="border-width: 1px;"><div class="codeContent 
panelContent pdl">
+                <div id="ConfluenceContent"><p>The <strong>PipelineBuilder 
Service</strong> is a service used to create pipelines, also known as 
<em>filter chains</em>. An example of this is the Filter and FilterChain 
interfaces inside the Servlet API.</p><div class="aui-label" 
style="float:right" title="Related Articles"><h3>Related Articles</h3><ul 
class="content-by-label"><li> 
+  <div> 
+   <span class="icon aui-icon aui-icon-small aui-iconfont-page-default" 
title="Page">Page:</span> 
+  </div> 
+  <div class="details"> 
+   <a  href="shadowbuilder-service.html">ShadowBuilder Service</a> 
+  </div> </li><li> 
+  <div> 
+   <span class="icon aui-icon aui-icon-small aui-iconfont-page-default" 
title="Page">Page:</span> 
+  </div> 
+  <div class="details"> 
+   <a  href="strategybuilder-service.html">StrategyBuilder Service</a> 
+  </div> </li><li> 
+  <div> 
+   <span class="icon aui-icon aui-icon-small aui-iconfont-page-default" 
title="Page">Page:</span> 
+  </div> 
+  <div class="details"> 
+   <a  href="pipelinebuilder-service.html">PipelineBuilder Service</a> 
+  </div> </li><li> 
+  <div> 
+   <span class="icon aui-icon aui-icon-small aui-iconfont-page-default" 
title="Page">Page:</span> 
+  </div> 
+  <div class="details"> 
+   <a  href="chainbuilder-service.html">ChainBuilder Service</a> 
+  </div> </li></ul></div><p>In this pattern, an existing service is decorated 
with a filter. The filter will delegate to the service, but has the chance to 
alter or replace parameters before invoking the method, and can perform 
operations before returning. This is similar to <a  
href="chainbuilder-service.html">chain of responsibility</a>, but differs in 
that there are two interfaces (the service interface and the filter interface) 
and that each filter invokes the next filter via the service interface. In 
contrast, in the chain of responsibility, the chain invokes each method, which 
must return before the next command in the chain is invoked.</p><p>The service 
interface and the filter interface are closely related: the filter interface 
must match the service interface method for method, but each method of the 
filter interface must have an additional parameter whose type is the service 
interface. For example, a pipeline that performed string transformations might 
use the following in
 terfaces:</p><div class="code panel pdl" style="border-width: 1px;"><div 
class="codeContent panelContent pdl">
 <pre class="brush: java; gutter: false; theme: Default" 
style="font-size:12px;">public interface StringTransformService
 {
   String transform(String input);

Modified: websites/production/tapestry/content/presentations.html
==============================================================================
--- websites/production/tapestry/content/presentations.html (original)
+++ websites/production/tapestry/content/presentations.html Tue Nov  8 12:22:26 
2016
@@ -36,18 +36,13 @@
 
   <div class="wrapper bs">
 
-        <div id="navigation"><div class="nav">
-<ul class="alternate"><li><a  href="index.html">Home</a></li><li><a  
href="getting-started.html">Getting Started</a></li><li><a  
href="documentation.html">Documentation</a></li><li><a  
href="download.html">Download</a></li><li><a  
href="about.html">About</a></li><li><a  
href="community.html">Community</a></li><li><a  class="external-link" 
href="http://www.apache.org/";>Apache</a></li><li><a  class="external-link" 
href="http://www.apache.org/foundation/sponsorship.html";>Sponsorship</a></li><li><a
  class="external-link" 
href="http://www.apache.org/foundation/thanks.html";>Thanks</a></li></ul>
-</div></div>
+        <div id="navigation"><div class="nav"><ul class="alternate"><li><a  
href="index.html">Home</a></li><li><a  href="getting-started.html">Getting 
Started</a></li><li><a  href="documentation.html">Documentation</a></li><li><a  
href="download.html">Download</a></li><li><a  
href="about.html">About</a></li><li><a  class="external-link" 
href="http://www.apache.org/licenses/LICENSE-2.0";>License</a></li><li><a  
href="community.html">Community</a></li><li><a  class="external-link" 
href="http://www.apache.org/security/";>Security</a></li><li><a  
class="external-link" href="http://www.apache.org/";>Apache</a></li><li><a  
class="external-link" 
href="http://www.apache.org/foundation/sponsorship.html";>Sponsorship</a></li><li><a
  class="external-link" 
href="http://www.apache.org/foundation/thanks.html";>Thanks</a></li></ul></div></div>
 
           <div id="top">
-            <div id="smallbanner"><div class="searchbox" 
style="float:right;margin: .3em 1em .1em 1em"><span style="color: #999; 
font-size: 90%">Tapestry docs, issues, wikis &amp; blogs:</span>
-<form enctype="application/x-www-form-urlencoded" method="get" 
action="http://tapestry.apache.org/search.html";>
-  <input type="text" name="q">
-  <input type="submit" value="Search">
-</form>
-
-</div><div class="emblem" style="float:left"><p><a  href="index.html"><span 
class="confluence-embedded-file-wrapper"><img class="confluence-embedded-image 
confluence-external-resource" 
src="http://tapestry.apache.org/images/tapestry_small.png"; 
data-image-src="http://tapestry.apache.org/images/tapestry_small.png";></span></a></p></div><div
 class="title" style="float:left; margin: 0 0 0 3em"><h1 
id="SmallBanner-PageTitle">Presentations</h1></div></div>
+            <div id="smallbanner"><div class="searchbox" 
style="float:right;margin: .3em 1em .1em 1em"><span style="color: #999; 
font-size: 90%">Tapestry docs, issues, wikis &amp; blogs:</span><form 
enctype="application/x-www-form-urlencoded" method="get" 
action="http://tapestry.apache.org/search.html";> 
+ <input type="text" name="q"> 
+ <input type="submit" value="Search"> 
+</form></div><div class="emblem" style="float:left"><p><a  
href="index.html"><span class="confluence-embedded-file-wrapper"><img 
class="confluence-embedded-image confluence-external-resource" 
src="http://tapestry.apache.org/images/tapestry_small.png"; 
data-image-src="http://tapestry.apache.org/images/tapestry_small.png";></span></a></p></div><div
 class="title" style="float:left; margin: 0 0 0 3em"><h1 
id="SmallBanner-PageTitle">Presentations</h1></div></div>
       <div class="clearer"></div>
       </div>
 


Reply via email to