tapestry-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From build...@apache.org
Subject svn commit: r946241 [1/2] - in /websites/production/tapestry/content: ./ cache/ error-page-recipe.data/ overriding-exception-reporting.data/
Date Fri, 03 Apr 2015 22:19:43 GMT
Author: buildbot
Date: Fri Apr  3 22:19:42 2015
New Revision: 946241

Log:
Production update by buildbot for tapestry

Added:
    websites/production/tapestry/content/error-page-recipe.data/Resource_not_found_.png   (with props)
    websites/production/tapestry/content/overriding-exception-reporting.data/Application_Exception.png   (with props)
    websites/production/tapestry/content/overriding-exception-reporting.data/actionfail_-_top.png   (with props)
    websites/production/tapestry/content/overriding-exception-reporting.data/customer_exception_report_-_open_1.png   (with props)
    websites/production/tapestry/content/overriding-exception-reporting.data/index_as_excepton_report.png   (with props)
Modified:
    websites/production/tapestry/content/cache/main.pageCache
    websites/production/tapestry/content/component-libraries.html
    websites/production/tapestry/content/error-page-recipe.html
    websites/production/tapestry/content/forms-and-form-components-faq.html
    websites/production/tapestry/content/general-questions.html
    websites/production/tapestry/content/overriding-exception-reporting.html
    websites/production/tapestry/content/security-faq.html
    websites/production/tapestry/content/templating-and-markup-faq.html

Modified: websites/production/tapestry/content/cache/main.pageCache
==============================================================================
Binary files - no diff available.

Modified: websites/production/tapestry/content/component-libraries.html
==============================================================================
--- websites/production/tapestry/content/component-libraries.html (original)
+++ websites/production/tapestry/content/component-libraries.html Fri Apr  3 22:19:42 2015
@@ -75,7 +75,13 @@ table.ScrollbarTable td.ScrollbarParent
 table.ScrollbarTable td.ScrollbarNextName {text-align: right;border: none;}
 table.ScrollbarTable td.ScrollbarNextIcon {text-align: center;width: 16px;border: none;}
 
-/*]]>*/</style><div class="Scrollbar"><table class="ScrollbarTable"><tr><td colspan="1" rowspan="1" class="ScrollbarPrevIcon"><a shape="rect" href="supporting-informal-parameters.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/back_16.gif" width="16" height="16"></a></td><td colspan="1" rowspan="1" class="ScrollbarPrevName" width="33%"><a shape="rect" href="supporting-informal-parameters.html">Supporting Informal Parameters</a>&#160;</td><td colspan="1" rowspan="1" class="ScrollbarParent" width="33%"><sup><a shape="rect" href="cookbook.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/up_16.gif" width="8" height="8"></a></sup><a shape="rect" href="cookbook.html">Cookbook</a></td><td colspan="1" rowspan="1" class="ScrollbarNextName" width="33%">&#160;<a shape="rect" href="switching-cases.html">Switching Cases</a></td><td colspan="1" rowspan="1" class="ScrollbarNextIcon"><a shape="rect" href="switching
 -cases.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/forwd_16.gif" width="16" height="16"></a></td></tr></table></div><h1 id="ComponentLibraries-CreatingComponentLibraries">Creating Component Libraries</h1><p>Nearly every Tapestry application includes a least a couple of custom components, specific to the application. What's exciting about Tapestry is how easy it is to package components for reuse across many applications ... and the fact that applications using a component library need no special configuration.</p><p>A Tapestry component library consists of components (and optionally mixins, pages and component base classes). In addition, a component library will have a module that can define new services (needed by the components) or configure other services present in Tapestry. Finally, components can be packaged with <em>assets</em>: resources such as images, stylesheets and JavaScript libraries that need to be provided to the client 
 web browser.</p><p>We're going to create a somewhat insipid component that displays a large happy face icon.</p><p>Tapestry doesn't mandate that you use any build system, but we'll assume for the moment that you are using Maven 2. In that case, you'll have a pom.xml file something like the following:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>pom.xml</b></div><div class="codeContent panelContent pdl">
+/*]]>*/</style><div class="Scrollbar"><table class="ScrollbarTable"><tr><td colspan="1" rowspan="1" class="ScrollbarPrevIcon"><a shape="rect" href="supporting-informal-parameters.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/back_16.gif" width="16" height="16"></a></td><td colspan="1" rowspan="1" class="ScrollbarPrevName" width="33%"><a shape="rect" href="supporting-informal-parameters.html">Supporting Informal Parameters</a>&#160;</td><td colspan="1" rowspan="1" class="ScrollbarParent" width="33%"><sup><a shape="rect" href="cookbook.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/up_16.gif" width="8" height="8"></a></sup><a shape="rect" href="cookbook.html">Cookbook</a></td><td colspan="1" rowspan="1" class="ScrollbarNextName" width="33%">&#160;<a shape="rect" href="switching-cases.html">Switching Cases</a></td><td colspan="1" rowspan="1" class="ScrollbarNextIcon"><a shape="rect" href="switching
 -cases.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/forwd_16.gif" width="16" height="16"></a></td></tr></table></div>    <div class="aui-message problem shadowed information-macro">
+                            <span class="aui-icon icon-problem">Icon</span>
+                <div class="message-content">
+                            <p>This page has not yet been fully updated for Tapestry 5.4. Things are different and simpler in 5.4 than in previous releases.</p>
+                    </div>
+    </div>
+<h1 id="ComponentLibraries-CreatingComponentLibraries">Creating Component Libraries</h1><p>Nearly every Tapestry application includes a least a couple of custom components, specific to the application. What's exciting about Tapestry is how easy it is to package components for reuse across many applications ... and the fact that applications using a component library need no special configuration.</p><p>A Tapestry component library consists of components (and optionally mixins, pages and component base classes). In addition, a component library will have a module that can define new services (needed by the components) or configure other services present in Tapestry. Finally, components can be packaged with <em>assets</em>: resources such as images, stylesheets and JavaScript libraries that need to be provided to the client web browser.</p><p>We're going to create a somewhat insipid component that displays a large happy face icon.</p><p>Tapestry doesn't mandate that you use any build 
 system, but we'll assume for the moment that you are using Maven 2. In that case, you'll have a pom.xml file something like the following:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>pom.xml</b></div><div class="codeContent panelContent pdl">
 <script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[&lt;project&gt;
   &lt;modelVersion&gt;4.0.0&lt;/modelVersion&gt;
   &lt;groupId&gt;org.example&lt;/groupId&gt;
@@ -140,7 +146,7 @@ table.ScrollbarTable td.ScrollbarNextIco
   &lt;/repositories&gt;
 
   &lt;properties&gt;
-    &lt;tapestry-release-version&gt;5.2.0&lt;/tapestry-release-version&gt;
+    &lt;tapestry-release-version&gt;5.4-beta-28&lt;/tapestry-release-version&gt;
   &lt;/properties&gt;
 &lt;/project&gt;
 ]]></script>

Added: websites/production/tapestry/content/error-page-recipe.data/Resource_not_found_.png
==============================================================================
Binary file - no diff available.

Propchange: websites/production/tapestry/content/error-page-recipe.data/Resource_not_found_.png
------------------------------------------------------------------------------
    svn:mime-type = image/png

Modified: websites/production/tapestry/content/error-page-recipe.html
==============================================================================
--- websites/production/tapestry/content/error-page-recipe.html (original)
+++ websites/production/tapestry/content/error-page-recipe.html Fri Apr  3 22:19:42 2015
@@ -91,7 +91,7 @@ table.ScrollbarTable td.ScrollbarNextIco
                     <span class="icon icon-page" title="Page">Page:</span>            </div>
 
             <div class="details">
-                            <a shape="rect" href="error-page-recipe.html">Error Page Recipe</a>
+                            <a shape="rect" href="overriding-exception-reporting.html">Overriding Exception Reporting</a>
                     
                 
                             </div>
@@ -100,7 +100,7 @@ table.ScrollbarTable td.ScrollbarNextIco
                     <span class="icon icon-page" title="Page">Page:</span>            </div>
 
             <div class="details">
-                            <a shape="rect" href="overriding-exception-reporting.html">Overriding Exception Reporting</a>
+                            <a shape="rect" href="error-page-recipe.html">Error Page Recipe</a>
                     
                 
                             </div>
@@ -115,7 +115,7 @@ table.ScrollbarTable td.ScrollbarNextIco
   &lt;display-name&gt;Cookbook&lt;/display-name&gt;
   &lt;context-param&gt;
     &lt;param-name&gt;tapestry.app-package&lt;/param-name&gt;
-    &lt;param-value&gt;com.example.cookbook&lt;/param-value&gt;
+    &lt;param-value&gt;com.example.newapp&lt;/param-value&gt;
   &lt;/context-param&gt;
 
   &lt;filter&gt;
@@ -137,23 +137,26 @@ table.ScrollbarTable td.ScrollbarNextIco
 &lt;/web-app&gt;
 ]]></script>
 </div></div><p>Tapestry's filter must be marked as a handler for both standard requests and errors. That's accomplished with the <code>&lt;dispatcher&gt;</code> elements inside the <code>&lt;filter-mapping&gt;</code> section.</p><p>You must then map error codes to Tapestry URLs. In this case, the 404 error is send to the <code>/error404</code> resource, which is really the "Error404" Tapestry page.</p><p>We'll create a simple Error404 page, one that displays a message and (in development mode) displays the details about the incoming request.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>Error404.tml</b></div><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[&lt;html xmlns:t=&quot;http://tapestry.apache.org/schema/tapestry_5_1_0.xsd&quot;&gt;
-  &lt;head&gt;
-    &lt;title&gt;Resource not found.&lt;/title&gt;
-  &lt;/head&gt;
-  &lt;body&gt;
-
-    &lt;h1&gt;Page or resource not found.&lt;/h1&gt;
-
-    &lt;t:if test=&quot;! productionMode&quot;&gt;
-      &lt;t:renderobject object=&quot;request&quot;/&gt;
-    &lt;/t:if&gt;
+<script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[&lt;html xmlns:t=&quot;http://tapestry.apache.org/schema/tapestry_5_4.xsd&quot;&gt;
+ &lt;head&gt;
 
-  &lt;/body&gt;
-&lt;/html&gt;
-]]></script>
+        &lt;title&gt;Resource not found.&lt;/title&gt;
+    &lt;/head&gt;
+    &lt;body&gt;
+
+        &lt;div class=&quot;container&quot;&gt;
+
+            &lt;h1&gt;Page or resource not found.&lt;/h1&gt;
+
+            &lt;t:if test=&quot;! productionMode&quot;&gt;
+                &lt;t:renderobject object=&quot;request&quot;/&gt;
+            &lt;/t:if&gt;
+        &lt;/div&gt;
+
+    &lt;/body&gt;
+&lt;/html&gt;]]></script>
 </div></div><p>The page simply makes the request and productionMode properties available:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>Error404.java</b></div><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[package com.example.cookbook.pages;
+<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[package com.example.newapp.pages;
 
 import org.apache.tapestry5.SymbolConstants;
 import org.apache.tapestry5.annotations.Property;
@@ -172,8 +175,10 @@ public class Error404
     @Symbol(SymbolConstants.PRODUCTION_MODE)
     private boolean productionMode;
 }
+
+
 ]]></script>
-</div></div><p>The end-result, in when <em>not</em> in production mode, looks like this:</p><p><img class="confluence-embedded-image" src="error-page-recipe.data/error404-screenshot.png" data-image-src="/confluence/download/attachments/23336861/error404-screenshot.png?version=1&amp;modificationDate=1419044898000&amp;api=v2"></p>    <div class="aui-message hint shadowed information-macro">
+</div></div><p>The end-result, in when <em>not</em> in production mode, looks like this:</p><p><img class="confluence-embedded-image confluence-content-image-border image-center" width="500" src="error-page-recipe.data/Resource_not_found_.png" data-image-src="/confluence/download/attachments/23336861/Resource_not_found_.png?version=1&amp;modificationDate=1428099193877&amp;api=v2"></p>    <div class="aui-message hint shadowed information-macro">
                             <span class="aui-icon icon-hint">Icon</span>
                 <div class="message-content">
                             <p>An issue with an application that has a root Index page is that any invalid path, which would normally generate a 404 error, is instead routed to the Index page (because the invalid path looks like page's activation context). See <a shape="rect" class="external-link" href="https://issues.apache.org/jira/browse/TAP5-2070">Issue TAP5-2070</a>.</p>

Modified: websites/production/tapestry/content/forms-and-form-components-faq.html
==============================================================================
--- websites/production/tapestry/content/forms-and-form-components-faq.html (original)
+++ websites/production/tapestry/content/forms-and-form-components-faq.html Fri Apr  3 22:19:42 2015
@@ -75,25 +75,8 @@ table.ScrollbarTable td.ScrollbarParent
 table.ScrollbarTable td.ScrollbarNextName {text-align: right;border: none;}
 table.ScrollbarTable td.ScrollbarNextIcon {text-align: center;width: 16px;border: none;}
 
-/*]]>*/</style><div class="Scrollbar"><table class="ScrollbarTable"><tr><td colspan="1" rowspan="1" class="ScrollbarPrevIcon"><a shape="rect" href="page-and-component-classes-faq.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/back_16.gif" width="16" height="16"></a></td><td colspan="1" rowspan="1" class="ScrollbarPrevName" width="33%"><a shape="rect" href="page-and-component-classes-faq.html">Page And Component Classes FAQ</a>&#160;</td><td colspan="1" rowspan="1" class="ScrollbarParent" width="33%"><sup><a shape="rect" href="frequently-asked-questions.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/up_16.gif" width="8" height="8"></a></sup><a shape="rect" href="frequently-asked-questions.html">Frequently Asked Questions</a></td><td colspan="1" rowspan="1" class="ScrollbarNextName" width="33%">&#160;<a shape="rect" href="beaneditform-faq.html">BeanEditForm FAQ</a></td><td colspan="1" rowspan="1" c
 lass="ScrollbarNextIcon"><a shape="rect" href="beaneditform-faq.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/forwd_16.gif" width="16" height="16"></a></td></tr></table></div>
-
-<h2 id="FormsandFormComponentsFAQ-FormsandFormComponents">Forms and Form Components</h2>
-
-<p>Main article: <a shape="rect" href="forms-and-validation.html">Forms and Validation</a></p>
-
-<h3 id="FormsandFormComponentsFAQ-Whatisthet:formdatahiddenfieldfor?">What is the <code>t:formdata</code> hidden field for?</h3>
-
-<p>In Tapestry, rendering a form can be a complicated process; inside the body of the Form component are many of field components: TextField, Select, TextArea, and so forth. Each of these must pull data out of your data model and convert it to the string form used inside the client web browser.  In addition, JavaScript to support client-side validation must be generated.  This can be further complicated by the use of Loop and If components, or made really complicated by the use of Block (to render portions of other pages: this is what the BeanEditForm component does).</p>
-
-<p>Along the way, the Form is generating unique form control names for each field component, as it renders.</p>
-
-<p>When the client-side Form is submitted, an event is triggered on the server-side Form component. It now needs to locate each component, in turn, inform the component of its control name, and allow the component to read the corresponding query parameter. The component then converts the client-side string back into a server-side value and performs validations before updating the data model.</p>
-
-<p>That's where <code>t:formdata</code> comes in.  While components are rendering, they are using the FormSupport environmental object to record callbacks:</p>
-
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>FormSupport.java (partial)</b></div><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: java; gutter: true" type="syntaxhighlighter"><![CDATA[
-public interface FormSupport extends ClientElement
+/*]]>*/</style><div class="Scrollbar"><table class="ScrollbarTable"><tr><td colspan="1" rowspan="1" class="ScrollbarPrevIcon"><a shape="rect" href="page-and-component-classes-faq.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/back_16.gif" width="16" height="16"></a></td><td colspan="1" rowspan="1" class="ScrollbarPrevName" width="33%"><a shape="rect" href="page-and-component-classes-faq.html">Page And Component Classes FAQ</a>&#160;</td><td colspan="1" rowspan="1" class="ScrollbarParent" width="33%"><sup><a shape="rect" href="frequently-asked-questions.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/up_16.gif" width="8" height="8"></a></sup><a shape="rect" href="frequently-asked-questions.html">Frequently Asked Questions</a></td><td colspan="1" rowspan="1" class="ScrollbarNextName" width="33%">&#160;<a shape="rect" href="beaneditform-faq.html">BeanEditForm FAQ</a></td><td colspan="1" rowspan="1" c
 lass="ScrollbarNextIcon"><a shape="rect" href="beaneditform-faq.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/forwd_16.gif" width="16" height="16"></a></td></tr></table></div><h2 id="FormsandFormComponentsFAQ-FormsandFormComponents">Forms and Form Components</h2><p>Main article: <a shape="rect" href="forms-and-validation.html">Forms and Validation</a></p><h3 id="FormsandFormComponentsFAQ-Whatisthet:formdatahiddenfieldfor?">What is the <code>t:formdata</code> hidden field for?</h3><p>In Tapestry, rendering a form can be a complicated process; inside the body of the Form component are many of field components: TextField, Select, TextArea, and so forth. Each of these must pull data out of your data model and convert it to the string form used inside the client web browser. In addition, JavaScript to support client-side validation must be generated. This can be further complicated by the use of Loop and If components, or made really complicat
 ed by the use of Block (to render portions of other pages: this is what the BeanEditForm component does).</p><p>Along the way, the Form is generating unique form control names for each field component, as it renders.</p><p>When the client-side Form is submitted, an event is triggered on the server-side Form component. It now needs to locate each component, in turn, inform the component of its control name, and allow the component to read the corresponding query parameter. The component then converts the client-side string back into a server-side value and performs validations before updating the data model.</p><p>That's where <code>t:formdata</code> comes in. While components are rendering, they are using the FormSupport environmental object to record callbacks:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>FormSupport.java (partial)</b></div><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: java; gutter: true" type="syntaxhighlighter"><![CDATA[public interface FormSupport extends ClientElement
 {
     /**
      * Stores an action for execution during a later request.  If the action contains any mutable state, it should be in
@@ -111,86 +94,24 @@ public interface FormSupport extends Cli
      */
     &lt;T&gt; void storeAndExecute(T component, ComponentAction&lt;T&gt; action);
 ]]></script>
-</div></div>
-
-<p>The <code>ComponentAction</code> objects are the callbacks.  <code>t:formdata</code> is simply an object stream of these callbacks, compressed and encoded in Base64.  When using Ajax, you may see multiple <code>t:formdata</code> hidden fields (they are processed one after another).</p>
-
-
-<h3 id="FormsandFormComponentsFAQ-HowdoIchangethelabelforafieldonthefly?">How do I change the label for a field on the fly?</h3>
-
-
-<p>Tapestry tries to be smart about generating the label string for a field.  It has some smart default logic, first checking for the <em>component-id</em><code>-label</code> in the container's message catalog, then ultimately converting the component's id into a user-presentable label.</p>
-
-<p>You can override the label in two ways:</p>
-
-<p>First, you can supply a body to the <code>Label</code> component:</p>
-
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: java; gutter: true" type="syntaxhighlighter"><![CDATA[
-  &lt;t:label for=&quot;username&quot;&gt;${usernameLabel}&lt;/t:label&gt;
+</div></div><p>The <code>ComponentAction</code> objects are the callbacks. <code>t:formdata</code> is simply an object stream of these callbacks, compressed and encoded in Base64. When using Ajax, you may see multiple <code>t:formdata</code> hidden fields (they are processed one after another).</p><h3 id="FormsandFormComponentsFAQ-HowdoIchangethelabelforafieldonthefly?">How do I change the label for a field on the fly?</h3><p>Tapestry tries to be smart about generating the label string for a field. It has some smart default logic, first checking for the <em>component-id</em><code>-label</code> in the container's message catalog, then ultimately converting the component's id into a user-presentable label.</p><p>You can override the label in two ways:</p><p>First, you can supply a body to the <code>Label</code> component:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: java; gutter: true" type="syntaxhighlighter"><![CDATA[  &lt;t:label for=&quot;username&quot;&gt;${usernameLabel}&lt;/t:label&gt;
   &lt;t:textfield t:id=&quot;username&quot;/&gt;
 ]]></script>
-</div></div>
-
-<p>Here, the component class must provide a <code>usernameLabel</code> property. That property becomes the text of the label. An implementation of the property might look something like:</p>
-
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: java; gutter: true" type="syntaxhighlighter"><![CDATA[
-  public String getUsernameLabel()
+</div></div><p>Here, the component class must provide a <code>usernameLabel</code> property. That property becomes the text of the label. An implementation of the property might look something like:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: java; gutter: true" type="syntaxhighlighter"><![CDATA[  public String getUsernameLabel()
   {
     return systemPreferences.useEmailAddressForUserName() ? &quot;Email address&quot; : &quot;User name&quot;;
   }
 ]]></script>
-</div></div>
-
-<p>However, if there are any validations on the field, the error message will include the default label (as discussed above).</p>
-
-<p>To uniformly update the label both on the page, and in any validation messages, bind the TextField's <code>label</code> parameter:</p>
-
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: java; gutter: true" type="syntaxhighlighter"><![CDATA[
-  &lt;t:label for=&quot;username&quot;/&gt;
+</div></div><p>However, if there are any validations on the field, the error message will include the default label (as discussed above).</p><p>To uniformly update the label both on the page, and in any validation messages, bind the TextField's <code>label</code> parameter:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: java; gutter: true" type="syntaxhighlighter"><![CDATA[  &lt;t:label for=&quot;username&quot;/&gt;
   &lt;t:textfield t:id=&quot;username&quot; label=&quot;prop:usernameLabel&quot;/&gt;
 ]]></script>
-</div></div>
-
-<p>The "prop:" prefix identifies that "usernameLabel" is to be interpreted as a property expression (normally, the binding for the <code>label</code> parameter is interpreted as a string literal).  The Label component gets the text it displays from the TextField component, and the TextField component uses the same text when generating server-side and client-side validation messages.</p>
-
-
-<h3 id="FormsandFormComponentsFAQ-Tapestryfocusesonthewrongfieldinmyform,howdoIfixthat?">Tapestry focuses on the wrong field in my form, how do I fix that?</h3>
-
-<p>Tapestry normally figures out the correct field in your form to initially receive focus; this is based on assigning a <a shape="rect" class="external-link" href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/FieldFocusPriority.html">FieldFocusPriority</a> to each field as it renders, which works out to the following logic:</p>
-
-<ul><li>The first field which has an error</li><li>Or, the first field which is required</li><li>Or, the first field</li></ul>
-
-
-<p>Occasionally, due a wide range of factors beyond Tapestry's control, it's selection will not be quite what you want, and it is necessary to supply an override.  The information is tracked inside the <a shape="rect" class="external-link" href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/services/javascript/JavaScriptSupport.html">JavaScriptSupport</a> environmental. It's just a matter of injecting the component so that you can determine its client id, then informing JavaScriptSupport about your override.  </p>
-
-<p>Here's an example</p>
-
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[
-  &lt;t:textfield t:id=&quot;email&quot; .../&gt;
+</div></div><p>The "prop:" prefix identifies that "usernameLabel" is to be interpreted as a property expression (normally, the binding for the <code>label</code> parameter is interpreted as a string literal). The Label component gets the text it displays from the TextField component, and the TextField component uses the same text when generating server-side and client-side validation messages.</p><h3 id="FormsandFormComponentsFAQ-Tapestryfocusesonthewrongfieldinmyform,howdoIfixthat?">Tapestry focuses on the wrong field in my form, how do I fix that?</h3><p>Tapestry normally figures out the correct field in your form to initially receive focus; this is based on assigning a <a shape="rect" class="external-link" href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/FieldFocusPriority.html">FieldFocusPriority</a> to each field as it renders, which works out to the following logic:</p><ul><li>The first field which has an error</li><li>Or, the first field which is required
 </li><li>Or, the first field</li></ul><p>Occasionally, due a wide range of factors beyond Tapestry's control, it's selection will not be quite what you want, and it is necessary to supply an override. The information is tracked inside the <a shape="rect" class="external-link" href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/services/javascript/JavaScriptSupport.html">JavaScriptSupport</a> environmental. It's just a matter of injecting the component so that you can determine its client id, then informing JavaScriptSupport about your override.</p><p>Here's an example</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[  &lt;t:textfield t:id=&quot;email&quot; t:mixins=&quot;OverrideFieldFocus&quot; .../&gt;
 ]]></script>
-</div></div>
-
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[
-  @InjectComponent
-  private Field email;
-
-  @Environmental
-  private JavaScriptSupport javaScriptSupport;
-
-  void afterRender() {
-    javaScriptSupport.autofocus(FieldFocusPriority.OVERRIDE, email.getClientId());
-  }
-]]></script>
-</div></div>
-
-<p>In addition, there's a <a shape="rect" class="external-link" href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/corelib/mixins/FormFieldFocus.html">FormFieldFocus</a> mixin, however at the time of writing, it had a <a shape="rect" class="external-link" href="https://issues.apache.org/jira/browse/TAP5-1773">specific bug</a> and should not be used.</p>
-
-<style type="text/css">/*<![CDATA[*/
+</div></div><p>The <a shape="rect" class="external-link" href="http://tapestry.apache.org/5.4/apidocs/org/apache/tapestry5/corelib/mixins/OverrideFieldFocus.html">OverrideFieldFocus</a> mixin forces the email field to be the focus field, regardless.</p><style type="text/css">/*<![CDATA[*/
 table.ScrollbarTable  {border: none;padding: 3px;width: 100%;padding: 3px;margin: 0px;background-color: #f0f0f0}
 table.ScrollbarTable td.ScrollbarPrevIcon {text-align: center;width: 16px;border: none;}
 table.ScrollbarTable td.ScrollbarPrevName {text-align: left;border: none;}
@@ -198,8 +119,7 @@ table.ScrollbarTable td.ScrollbarParent
 table.ScrollbarTable td.ScrollbarNextName {text-align: right;border: none;}
 table.ScrollbarTable td.ScrollbarNextIcon {text-align: center;width: 16px;border: none;}
 
-/*]]>*/</style><div class="Scrollbar"><table class="ScrollbarTable"><tr><td colspan="1" rowspan="1" class="ScrollbarPrevIcon"><a shape="rect" href="page-and-component-classes-faq.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/back_16.gif" width="16" height="16"></a></td><td colspan="1" rowspan="1" class="ScrollbarPrevName" width="33%"><a shape="rect" href="page-and-component-classes-faq.html">Page And Component Classes FAQ</a>&#160;</td><td colspan="1" rowspan="1" class="ScrollbarParent" width="33%"><sup><a shape="rect" href="frequently-asked-questions.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/up_16.gif" width="8" height="8"></a></sup><a shape="rect" href="frequently-asked-questions.html">Frequently Asked Questions</a></td><td colspan="1" rowspan="1" class="ScrollbarNextName" width="33%">&#160;<a shape="rect" href="beaneditform-faq.html">BeanEditForm FAQ</a></td><td colspan="1" rowspan="1" c
 lass="ScrollbarNextIcon"><a shape="rect" href="beaneditform-faq.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/forwd_16.gif" width="16" height="16"></a></td></tr></table></div>
-</div>
+/*]]>*/</style><div class="Scrollbar"><table class="ScrollbarTable"><tr><td colspan="1" rowspan="1" class="ScrollbarPrevIcon"><a shape="rect" href="page-and-component-classes-faq.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/back_16.gif" width="16" height="16"></a></td><td colspan="1" rowspan="1" class="ScrollbarPrevName" width="33%"><a shape="rect" href="page-and-component-classes-faq.html">Page And Component Classes FAQ</a>&#160;</td><td colspan="1" rowspan="1" class="ScrollbarParent" width="33%"><sup><a shape="rect" href="frequently-asked-questions.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/up_16.gif" width="8" height="8"></a></sup><a shape="rect" href="frequently-asked-questions.html">Frequently Asked Questions</a></td><td colspan="1" rowspan="1" class="ScrollbarNextName" width="33%">&#160;<a shape="rect" href="beaneditform-faq.html">BeanEditForm FAQ</a></td><td colspan="1" rowspan="1" c
 lass="ScrollbarNextIcon"><a shape="rect" href="beaneditform-faq.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/forwd_16.gif" width="16" height="16"></a></td></tr></table></div></div>
 </div>
 
 <div class="clearer"></div>

Modified: websites/production/tapestry/content/general-questions.html
==============================================================================
--- websites/production/tapestry/content/general-questions.html (original)
+++ websites/production/tapestry/content/general-questions.html Fri Apr  3 22:19:42 2015
@@ -76,15 +76,15 @@ table.ScrollbarTable td.ScrollbarNextNam
 table.ScrollbarTable td.ScrollbarNextIcon {text-align: center;width: 16px;border: none;}
 
 /*]]>*/</style><div class="Scrollbar"><table class="ScrollbarTable"><tr><td colspan="1" rowspan="1" class="ScrollbarPrevName" width="33%">&#160;</td><td colspan="1" rowspan="1" class="ScrollbarParent" width="33%"><sup><a shape="rect" href="frequently-asked-questions.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/up_16.gif" width="8" height="8"></a></sup><a shape="rect" href="frequently-asked-questions.html">Frequently Asked Questions</a></td><td colspan="1" rowspan="1" class="ScrollbarNextName" width="33%">&#160;<a shape="rect" href="templating-and-markup-faq.html">Templating and Markup FAQ</a></td><td colspan="1" rowspan="1" class="ScrollbarNextIcon"><a shape="rect" href="templating-and-markup-faq.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/forwd_16.gif" width="16" height="16"></a></td></tr></table></div><h2 id="GeneralQuestions-GeneralQuestions">General Questions</h2><p><style type="text/css
 ">/*<![CDATA[*/
-div.rbtoc1427879988437 {padding: 0px;}
-div.rbtoc1427879988437 ul {list-style: disc;margin-left: 0px;}
-div.rbtoc1427879988437 li {margin-left: 0px;padding-left: 0px;}
+div.rbtoc1428099563766 {padding: 0px;}
+div.rbtoc1428099563766 ul {list-style: disc;margin-left: 0px;}
+div.rbtoc1428099563766 li {margin-left: 0px;padding-left: 0px;}
 
-/*]]>*/</style></p><div class="toc-macro rbtoc1427879988437">
+/*]]>*/</style></p><div class="toc-macro rbtoc1428099563766">
 <ul class="toc-indentation"><li><a shape="rect" href="#GeneralQuestions-GeneralQuestions">General Questions</a>
-<ul class="toc-indentation"><li><a shape="rect" href="#GeneralQuestions-HowdoIgetstartedwithTapestry?">How do I get started with Tapestry?</a></li><li><a shape="rect" href="#GeneralQuestions-WhydoesTapestryusePrototype?WhynotinsertfavoriteJavaScriptlibraryhere?">Why does Tapestry use Prototype? Why not insert favorite JavaScript library here?</a></li><li><a shape="rect" href="#GeneralQuestions-WhydoesTapestryhaveitsownInversionofControlContainer?WhynotSpringorGuice?">Why does Tapestry have its own Inversion of Control Container? Why not Spring or Guice?</a></li><li><a shape="rect" href="#GeneralQuestions-HowdoIupgradefromTapestry4toTapestry5?">How do I upgrade from Tapestry 4 to Tapestry 5?</a></li><li><a shape="rect" href="#GeneralQuestions-HowdoIupgradefromoneversionofTapestry5toanother?">How do I upgrade from one version of Tapestry 5 to another?</a></li><li><a shape="rect" href="#GeneralQuestions-WhyaretherebothRequestandHttpServletRequest?">Why are there both Request and HttpSe
 rvletRequest?</a></li></ul>
+<ul class="toc-indentation"><li><a shape="rect" href="#GeneralQuestions-HowdoIgetstartedwithTapestry?">How do I get started with Tapestry?</a></li><li><a shape="rect" href="#GeneralQuestions-WhydoesTapestryusePrototype?WhynotinsertfavoriteJavaScriptlibraryhere?">Why does Tapestry use Prototype? Why not insert favorite JavaScript library here?</a></li><li><a shape="rect" href="#GeneralQuestions-WhydoesTapestryhaveitsownInversionofControlContainer?WhynotSpringorGuice?">Why does Tapestry have its own Inversion of Control Container? Why not Spring or Guice?</a></li><li><a shape="rect" href="#GeneralQuestions-HowdoIupgradefromTapestry4toTapestry5?">How do I upgrade from Tapestry 4 to Tapestry 5?</a></li><li><a shape="rect" href="#GeneralQuestions-HowdoIupgradefromoneversionofTapestry5toanother?">How do I upgrade from one version of Tapestry 5 to another?</a></li></ul>
 </li></ul>
-</div><h3 id="GeneralQuestions-HowdoIgetstartedwithTapestry?">How do I get started with Tapestry?</h3><p>The easiest way to get started is to use <a shape="rect" class="external-link" href="http://maven.apache.org">Apache Maven</a> to create your initial project; Maven can use an <em>archetype</em> (a kind of project template) to create a bare-bones Tapestry application for you. See the <a shape="rect" href="getting-started.html">Getting Started</a> page for more details.</p><p>Even without Maven, Tapestry is quite easy to set up. You just need to <a shape="rect" href="download.html">download</a> the binaries and setup your build to place them inside your WAR's WEB-INF/lib folder. The rest is just some one-time <a shape="rect" href="configuration.html">configuration of the web.xml deployment descriptor</a>.</p><h3 id="GeneralQuestions-WhydoesTapestryusePrototype?WhynotinsertfavoriteJavaScriptlibraryhere?">Why does Tapestry use Prototype? Why not <em>insert favorite JavaScript librar
 y here</em>?</h3><p>An important goal for Tapestry is seamless DHTML and Ajax integration. To serve that goal, it was important that the built in components be capable of Ajax operations, such as dynamically re-rendering parts of the page. Because of that, it made sense to bundle a well-known JavaScript library as part of Tapestry.</p><p>At the time (this would be 2006-ish), Prototype and Scriptaculous were well known and well documented, and jQuery was just getting started.</p><p>The intent has always been to make this aspect of Tapestry pluggable. Work is underway to <a shape="rect" href="javascript-rewrite.html">reboot Tapestry's JavaScript</a> as part of 5.4. This will introduce a modern layer of modularization, and tease apart the entrenched dependency on Prototype.</p><h3 id="GeneralQuestions-WhydoesTapestryhaveitsownInversionofControlContainer?WhynotSpringorGuice?">Why does Tapestry have its own Inversion of Control Container? Why not Spring or Guice?</h3><p>An Inversion of C
 ontrol Container is <em>the</em> key piece of Tapestry's infrastructure. It is absolutely necessary to create software as robust, performant and extensible as Tapestry.</p><p>Tapestry IoC includes a number of features that distinguish itself from other containers:</p><ul><li>Configured in code, not XML</li><li>Built-in extension mechanism for services: configurations and contributions</li><li>Built-in aspect oriented programming model (service decorations and advice)</li><li>Easy modularization</li><li>Best-of-breed exception reporting</li></ul><p>Because Tapestry is implemented on top of its IoC container, and because the container makes it easy to extend or replace any service inside the container, it is possible to make the small changes to Tapestry needed to customize it to any project's needs.</p><h3 id="GeneralQuestions-HowdoIupgradefromTapestry4toTapestry5?">How do I upgrade from Tapestry 4 to Tapestry 5?</h3><p>There is no existing tool that supports upgrading from Tapestry 
 4 to Tapestry 5; Tapestry 5 is a complete rewrite.</p><p>Many of the basic concepts in Tapestry 4 are still present in Tapestry 5, but refactored, improved, streamlined, and simplified. The basic concept of pages, templates and components are largely the same. Other aspects, such as server-side event handling, is markedly different.</p><h3 id="GeneralQuestions-HowdoIupgradefromoneversionofTapestry5toanother?">How do I upgrade from one version of Tapestry 5 to another?</h3><p>A lot of effort goes into making an upgrade from one Tapestry 5 release to another go smoothly. In the general case, it is just a matter of updating the version number in your Maven <code>build.xml</code> or Gradle <code>build.gradle</code> file and executing the appropriate commands (e.g., <code>gradle idea</code> or <code>mvn eclipse:eclipse</code>) to bring your local workspace up to date with the latest binaries.</p><p>After changing dependencies, you should always perform a clean recompile of your applicati
 on.</p><p>We make every effort to ensure backwards-compatibility. Tapestry is mostly coded in terms of interfaces; those interfaces are stable to a point: interfaces your code is expected to implement are usually completely frozen; interfaces your code is expected to invoke, such as the interfaces to IoC services, are stable, but may have new methods added in a release; existing methods are not changed.</p><p>In <em>rare</em> cases a choice is necessary between fixing bugs (or adding essential functionality) and maintaining complete backwards compatibility; in those cases, an incompatible change may be introduced. These are always discussed in detail in the <a shape="rect" href="release-notes.html">Release Notes</a> for the specific release. You should always read the release notes before attempting an upgrade, and always (really, <em>always</em>) be prepared to retest your application afterwards.</p><p>Note that you should be careful any time you make use of <strong>internal</stron
 g> APIs (you can tell an API is internal by the package name, <code>org.apache.tapestry5.internal...</code>. Internal APIs may change <em>at any time</em>; there's no guarantee of backwards compatibility. Please always check on the documentation, or consult the user mailing list, to see if there's a stable, public alternative. If you do make use of internal APIs, be sure to get a discussion going so that your needs can be met in the future by a stable, public API.</p><p>A final note: Tapestry incorporates your application's version number into the URLs for JavaScript, CSS, and other assets exposed to the browser; these assets are cached on the browser with the assumption that when the server-side assets are changed, the version number (and thus the URL) will change as well. This version number applies to framework-provided assets as well as those specific to your application.</p><p>Thus, whenever you upgrade, you must change the <code>tapestry.application-version</code> <a shape="re
 ct" href="configuration.html">configuration symbol</a> as well. If you fail to do so, you will see odd behavior in some clients who may be running a mix of old and new assets. This can result in execution errors or incorrect behavior in your clients.</p><p>Again, after an upgrade to a new version of Tapestry, change your application version number as well to ensure that the latest version of all assets are downloaded into your client's browsers.</p><h3 id="GeneralQuestions-WhyaretherebothRequestandHttpServletRequest?">Why are there both Request and HttpServletRequest?</h3><p>Tapestry's Request interface is <em>very</em> close to the standard HttpServletRequest interface. It differs in a few ways, omitting some unneeded methods, and adding a couple of new methods (such as <code>isXHR()</code>), as well as changing how some existing methods operate. For example, <code>getParameterNames()</code> returns a sorted List of Strings; HttpServletRequest returns an Enumeration, which is a ver
 y dated approach.</p><p>However, the stronger reason for Request (and the related interfaces Response and Session) is to enable the support for Portlets at some point in the future. By writing code in terms of Tapestry's Request, and not HttpServletRequest, you can be assured that the same code will operate in both Servlet Tapestry and Portlet Tapestry.</p><style type="text/css">/*<![CDATA[*/
+</div><h3 id="GeneralQuestions-HowdoIgetstartedwithTapestry?">How do I get started with Tapestry?</h3><p>The easiest way to get started is to use <a shape="rect" class="external-link" href="http://maven.apache.org">Apache Maven</a> to create your initial project; Maven can use an <em>archetype</em> (a kind of project template) to create a bare-bones Tapestry application for you. See the <a shape="rect" href="getting-started.html">Getting Started</a> page for more details.</p><p>Even without Maven, Tapestry is quite easy to set up. You just need to <a shape="rect" href="download.html">download</a> the binaries and setup your build to place them inside your WAR's WEB-INF/lib folder. The rest is just some one-time <a shape="rect" href="configuration.html">configuration of the web.xml deployment descriptor</a>.</p><h3 id="GeneralQuestions-WhydoesTapestryusePrototype?WhynotinsertfavoriteJavaScriptlibraryhere?">Why does Tapestry use Prototype? Why not <em>insert favorite JavaScript librar
 y here</em>?</h3><p>An important goal for Tapestry is seamless DHTML and Ajax integration. To serve that goal, it was important that the built in components be capable of Ajax operations, such as dynamically re-rendering parts of the page. Because of that, it made sense to bundle a well-known JavaScript library as part of Tapestry.</p><p>At the time (this would be 2006-ish), Prototype and Scriptaculous were well known and well documented, and jQuery was just getting started.</p><p>The intent has always been to make this aspect of Tapestry pluggable. Tapestry 5.4 includes the option of either Prototype or jQuery Tapestry 5.5 will remove Prototype as an option..</p><h3 id="GeneralQuestions-WhydoesTapestryhaveitsownInversionofControlContainer?WhynotSpringorGuice?">Why does Tapestry have its own Inversion of Control Container? Why not Spring or Guice?</h3><p>An Inversion of Control Container is <em>the</em> key piece of Tapestry's infrastructure. It is absolutely necessary to create sof
 tware as robust, performant ,and extensible as Tapestry.</p><p>Tapestry IoC includes a number of features that distinguish itself from other containers:</p><ul><li>Configured in code, not XML</li><li>Built-in extension mechanism for services: configurations and contributions</li><li>Built-in aspect oriented programming model (service decorations and advice)</li><li>Easy modularization</li><li>Best-of-breed exception reporting</li></ul><p>Because Tapestry is implemented on top of its IoC container, and because the container makes it easy to extend or replace any service inside the container, it is possible to make the small changes to Tapestry needed to customize it to any project's needs.</p><h3 id="GeneralQuestions-HowdoIupgradefromTapestry4toTapestry5?">How do I upgrade from Tapestry 4 to Tapestry 5?</h3><p>There is no existing tool that supports upgrading from Tapestry 4 to Tapestry 5; Tapestry 5 is a complete rewrite.</p><p>Many of the basic concepts in Tapestry 4 are still pres
 ent in Tapestry 5, but refactored, improved, streamlined, and simplified. The basic concept of pages, templates and components are largely the same. Other aspects, such as server-side event handling, is markedly different.</p><h3 id="GeneralQuestions-HowdoIupgradefromoneversionofTapestry5toanother?">How do I upgrade from one version of Tapestry 5 to another?</h3><p>A lot of effort goes into making an upgrade from one Tapestry 5 release to another go smoothly. In the general case, it is just a matter of updating the version number in your Maven <code>build.xml</code> or Gradle <code>build.gradle</code> file and executing the appropriate commands (e.g., <code>gradle idea</code> or <code>mvn eclipse:eclipse</code>) to bring your local workspace up to date with the latest binaries.</p><p>After changing dependencies, you should always perform a clean recompile of your application.</p><p>We make every effort to ensure backwards-compatibility. Tapestry is mostly coded in terms of interface
 s; those interfaces are stable to a point: interfaces your code is expected to implement are usually completely frozen; interfaces your code is expected to invoke, such as the interfaces to IoC services, are stable, but may have new methods added in a release; existing methods are not changed.</p><p>In <em>rare</em> cases a choice is necessary between fixing bugs (or adding essential functionality) and maintaining complete backwards compatibility; in those cases, an incompatible change may be introduced. These are always discussed in detail in the <a shape="rect" href="release-notes.html">Release Notes</a> for the specific release. You should always read the release notes before attempting an upgrade, and always (really, <em>always</em>) be prepared to retest your application afterwards.</p><p>Note that you should be careful any time you make use of <strong>internal</strong> APIs (you can tell an API is internal by the package name, <code>org.apache.tapestry5.internal...</code>. Int
 ernal APIs may change <em>at any time</em>; there's no guarantee of backwards compatibility. Please always check on the documentation, or consult the user mailing list, to see if there's a stable, public alternative. If you do make use of internal APIs, be sure to get a discussion going so that your needs can be met in the future by a stable, public API.</p><p><span style="color: rgb(83,145,38);font-size: 16.0px;line-height: 1.5625;">Why are there both Request and HttpServletRequest?</span></p><p>Tapestry's Request interface is <em>very</em> close to the standard HttpServletRequest interface. It differs in a few ways, omitting some unneeded methods, and adding a couple of new methods (such as <code>isXHR()</code>), as well as changing how some existing methods operate. For example, <code>getParameterNames()</code> returns a sorted List of Strings; HttpServletRequest returns an Enumeration, which is a very dated approach.</p><p>However, the stronger reason for Request (and the relate
 d interfaces Response and Session) is to enable the support for Portlets at some point in the future. By writing code in terms of Tapestry's Request, and not HttpServletRequest, you can be assured that the same code will operate in both Servlet Tapestry and Portlet Tapestry.</p><style type="text/css">/*<![CDATA[*/
 table.ScrollbarTable  {border: none;padding: 3px;width: 100%;padding: 3px;margin: 0px;background-color: #f0f0f0}
 table.ScrollbarTable td.ScrollbarPrevIcon {text-align: center;width: 16px;border: none;}
 table.ScrollbarTable td.ScrollbarPrevName {text-align: left;border: none;}

Added: websites/production/tapestry/content/overriding-exception-reporting.data/Application_Exception.png
==============================================================================
Binary file - no diff available.

Propchange: websites/production/tapestry/content/overriding-exception-reporting.data/Application_Exception.png
------------------------------------------------------------------------------
    svn:mime-type = image/png

Added: websites/production/tapestry/content/overriding-exception-reporting.data/actionfail_-_top.png
==============================================================================
Binary file - no diff available.

Propchange: websites/production/tapestry/content/overriding-exception-reporting.data/actionfail_-_top.png
------------------------------------------------------------------------------
    svn:mime-type = image/png

Added: websites/production/tapestry/content/overriding-exception-reporting.data/customer_exception_report_-_open_1.png
==============================================================================
Binary file - no diff available.

Propchange: websites/production/tapestry/content/overriding-exception-reporting.data/customer_exception_report_-_open_1.png
------------------------------------------------------------------------------
    svn:mime-type = image/png

Added: websites/production/tapestry/content/overriding-exception-reporting.data/index_as_excepton_report.png
==============================================================================
Binary file - no diff available.

Propchange: websites/production/tapestry/content/overriding-exception-reporting.data/index_as_excepton_report.png
------------------------------------------------------------------------------
    svn:mime-type = image/png

Modified: websites/production/tapestry/content/overriding-exception-reporting.html
==============================================================================
--- websites/production/tapestry/content/overriding-exception-reporting.html (original)
+++ websites/production/tapestry/content/overriding-exception-reporting.html Fri Apr  3 22:19:42 2015
@@ -91,7 +91,7 @@ table.ScrollbarTable td.ScrollbarNextIco
                     <span class="icon icon-page" title="Page">Page:</span>            </div>
 
             <div class="details">
-                            <a shape="rect" href="error-page-recipe.html">Error Page Recipe</a>
+                            <a shape="rect" href="overriding-exception-reporting.html">Overriding Exception Reporting</a>
                     
                 
                             </div>
@@ -100,20 +100,17 @@ table.ScrollbarTable td.ScrollbarNextIco
                     <span class="icon icon-page" title="Page">Page:</span>            </div>
 
             <div class="details">
-                            <a shape="rect" href="overriding-exception-reporting.html">Overriding Exception Reporting</a>
+                            <a shape="rect" href="error-page-recipe.html">Error Page Recipe</a>
                     
                 
                             </div>
         </li></ul>
-</div><p>One of Tapestry's best features is its comprehensive exception reporting. The level of detail is impressive and useful.</p><p>Of course, one of the first questions anyone asks is "How do I turn it off?" This exception reporting is very helpful for developers but its easy to see it as terrifying for potential users. Not that you'd have have runtime exceptions in production, of course, but even so ...</p><h2 id="OverridingExceptionReporting-Version1:ReplacingtheExceptionReportPage">Version 1: Replacing the Exception Report Page</h2><p>Let's start with a page that fires an exception from an event handler method.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>Index.tml</b></div><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[&lt;html xmlns:t=&quot;http://tapestry.apache.org/schema/tapestry_5_4.xsd&quot;&gt;
-    &lt;body&gt;
+</div><p>One of Tapestry's best features is its comprehensive exception reporting. The level of detail is impressive and useful.</p><p>Of course, one of the first questions anyone asks is "How do I turn it off?" This exception reporting is very helpful for developers but its easy to see it as terrifying for potential users. Not that you'd have have runtime exceptions in production, of course, but even so ...</p><h2 id="OverridingExceptionReporting-Version1:ReplacingtheExceptionReportPage">Version 1: Replacing the Exception Report Page</h2><p>Let's start with a page that fires an exception from an event handler method.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>ActionFail.tml</b></div><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[ &lt;html xmlns:t=&quot;http://tapestry.apache.org/schema/tapestry_5_4.xsd&quot; t:type=&quot;layout&quot; title=&quot;Action Fail&quot;&gt;
         &lt;p&gt;
-            &lt;t:actionlink t:id=&quot;fail&quot;&gt;click for exception&lt;/t:actionlink&gt;
+            &lt;t:actionlink t:id=&quot;fail&quot; class=&quot;btn btn-large btn-warning&quot;&gt;Click for Exception&lt;/t:actionlink&gt;
         &lt;/p&gt;
-    &lt;/body&gt;
-&lt;/html&gt;
-]]></script>
+&lt;/html&gt;]]></script>
 </div></div><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>Index.java</b></div><div class="codeContent panelContent pdl">
 <script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[package com.example.newapp.pages;
 
@@ -123,71 +120,71 @@ public class ActionFail {
     }
 }
 ]]></script>
-</div></div><p>With production mode disabled, clicking the link displays the default exception report page:</p><p><img class="confluence-embedded-image" src="overriding-exception-reporting.data/error1.png" data-image-src="/confluence/download/attachments/20645557/error1.png?version=1&amp;modificationDate=1273638562000&amp;api=v2" title="Default exception report"></p><p>The easy way to override the exception report is to provide an ExceptionReport page that overrides the one provided with the framework.</p><p>This is as easy as providing a page named "ExceptionReport". It must implement the <a shape="rect" class="external-link" href="http://tapestry.apache.org/tapestry5/apidocs/org/apache/tapestry5/services/ExceptionReporter.html">ExceptionReporter</a> interface.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>ExceptionReport.tml</b></div><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[&lt;html xmlns:t=&quot;http://tapestry.apache.org/schema/tapestry_5_1_0.xsd&quot;&gt;
-    &lt;head&gt;
-        &lt;title&gt;Exception&lt;/title&gt;
-    &lt;/head&gt;
+</div></div><p>With production mode disabled, clicking the link displays the default exception report page:</p><p><img class="confluence-embedded-image confluence-content-image-border image-center" width="500" src="overriding-exception-reporting.data/actionfail_-_top.png" data-image-src="/confluence/download/attachments/20645557/actionfail_-_top.png?version=1&amp;modificationDate=1428096039285&amp;api=v2"></p><p><img class="confluence-embedded-image confluence-content-image-border image-center" width="500" src="overriding-exception-reporting.data/Application_Exception.png" data-image-src="/confluence/download/attachments/20645557/Application_Exception.png?version=1&amp;modificationDate=1428096098319&amp;api=v2"></p><p>&#160;</p><p>The easy way to override the exception report is to provide an ExceptionReport page that overrides the one provided with the framework.</p><p>This is as easy as providing a page named "ExceptionReport". It must implement the <a shape="rect" class="external
 -link" href="http://tapestry.apache.org/tapestry5/apidocs/org/apache/tapestry5/services/ExceptionReporter.html">ExceptionReporter</a> interface.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>ExceptionReport.tml</b></div><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[&lt;html t:type=&quot;layout&quot; title=&quot;Exception&quot;
+      xmlns:t=&quot;http://tapestry.apache.org/schema/tapestry_5_4.xsd&quot;&gt;
 
-    &lt;body&gt;
 
-        &lt;p&gt;An exception has occurred:
-            &lt;strong&gt;${exception.message}&lt;/strong&gt;
-        &lt;/p&gt;
+    &lt;div class=&quot;panel panel-danger&quot;&gt;
+        &lt;div class=&quot;panel-heading&quot;&gt;An exception has occurred.&lt;/div&gt;
+        &lt;div class=&quot;panel-body&quot;&gt;
+            ${message}
+        &lt;/div&gt;
+        &lt;div class=&quot;panel-footer&quot;&gt;
+            &lt;t:pagelink page=&quot;index&quot; class=&quot;btn btn-default&quot;&gt;Home&lt;/t:pagelink&gt;
+        &lt;/div&gt;
 
-        &lt;p&gt;
-            Click
-            &lt;t:pagelink page=&quot;index&quot;&gt;here&lt;/t:pagelink&gt;
-            to restart.
-        &lt;/p&gt;
+    &lt;/div&gt;
 
-    &lt;/body&gt;
 
 &lt;/html&gt;
 ]]></script>
 </div></div><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>ExceptionReport.java</b></div><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[package com.example.tapestry2523.pages;
+<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[package com.example.newapp.pages;
 
 import org.apache.tapestry5.annotations.Property;
 import org.apache.tapestry5.services.ExceptionReporter;
 
-public class ExceptionReport implements ExceptionReporter
-{
+public class ExceptionReport implements ExceptionReporter {
+
     @Property
-    private Throwable exception;
+    private String message;
 
-    public void reportException(Throwable exception)
-    {
-        this.exception = exception;
+    @Override
+    public void reportException(Throwable exception) {
+        message = exception.getMessage();
+
+        if (message == null)
+            message = exception.getClass().getName();
     }
 }
 ]]></script>
-</div></div><p>The end result is a customized exception report page.</p><p><img class="confluence-embedded-image" src="overriding-exception-reporting.data/error2.png" data-image-src="/confluence/download/attachments/20645557/error2.png?version=1&amp;modificationDate=1273638562000&amp;api=v2" title="Customized Exception Report Page"></p><h2 id="OverridingExceptionReporting-Version2:OverridingtheRequestExceptionHandler">Version 2: Overriding the RequestExceptionHandler</h2><p>The previous example will display a link back to the Index page of the application. Another alternative is to display the error &lt;on&gt; the Index page. This requires a different approach: overriding the service responsible for reporting request exceptions.</p><p>The service <a shape="rect" class="external-link" href="http://tapestry.apache.org/tapestry5/apidocs/org/apache/tapestry5/services/RequestExceptionHandler.html">RequestExceptionHandler</a> is responsible for this.</p><p>By replacing the default impleme
 ntation of this service with our own implementation, we can take control over exactly what happens when a request exception occurs.</p><p>We'll do this in two steps. First, we'll extend the Index page to serve as an ExceptionReporter. Second, we'll override the default RequestExceptionHandler to use the Index page instead of the ExceptionReport page. Of course, this is just one approach.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>Index.tml (partial)</b></div><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[    &lt;t:if test=&quot;message&quot;&gt;
-        &lt;p&gt;
-            An unexpected exception has occurred:
-            &lt;strong&gt;${message}&lt;/strong&gt;
-        &lt;/p&gt;
-    &lt;/t:if&gt;
-]]></script>
+</div></div><p>The end result is a customized exception report page.</p><p><img class="confluence-embedded-image confluence-content-image-border image-center" width="500" src="overriding-exception-reporting.data/customer_exception_report_-_open_1.png" data-image-src="/confluence/download/attachments/20645557/customer_exception_report_-_open_1.png?version=1&amp;modificationDate=1428096581764&amp;api=v2"></p><h2 id="OverridingExceptionReporting-Version2:OverridingtheRequestExceptionHandler">Version 2: Overriding the RequestExceptionHandler</h2><p>The previous example will display a link back to the Index page of the application. Another alternative is to display the error &lt;on&gt; the Index page. This requires a different approach: overriding the service responsible for reporting request exceptions.</p><p>The service <a shape="rect" class="external-link" href="http://tapestry.apache.org/tapestry5/apidocs/org/apache/tapestry5/services/RequestExceptionHandler.html">RequestExceptionHan
 dler</a> is responsible for this.</p><p>By replacing the default implementation of this service with our own implementation, we can take control over exactly what happens when a request exception occurs.</p><p>We'll do this in two steps. First, we'll extend the Index page to serve as an ExceptionReporter. Second, we'll override the default RequestExceptionHandler to use the Index page instead of the ExceptionReport page. Of course, this is just one approach.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>Index.tml (partial)</b></div><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[ &lt;t:if test=&quot;message&quot;&gt;
+    &lt;div class=&quot;panel panel-danger&quot;&gt;
+        &lt;div class=&quot;panel-heading&quot;&gt;An exception has occurred.&lt;/div&gt;
+        &lt;div class=&quot;panel-body&quot;&gt;
+            ${message}
+        &lt;/div&gt;
+    &lt;/div&gt;
+ &lt;/t:if&gt;]]></script>
 </div></div><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>Index.java</b></div><div class="codeContent panelContent pdl">
 <script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[public class Index implements ExceptionReporter
 {
-    @Property
-    @Persist(PersistenceConstants.FLASH)
-    private String message;
+	@Property
+	private String message;
 
-    public void reportException(Throwable exception)
-    {
-        message = exception.getMessage();
-    }
+	public void reportException(Throwable exception)
+	{
+   		message = exception.getMessage();
+
+	   if (message == null) {
+    	  message = exception.getClass().getName();
+	   }
+	}
 
-    void onActionFromFail()
-    {
-        throw new RuntimeException(&quot;Failure inside action event handler.&quot;);
-    }
-}
-]]></script>
+  ...
+}]]></script>
 </div></div><p>The above defines a new property, message, on the Index page. The @Persist annotation indicates that values assigned to the field will persist from one request to another. The use of FLASH for the persistence strategy indicates that the value will be used until the next time the page renders, then the value will be discarded.</p><p>The message property is set from the thrown runtime exception.</p><p>The remaining changes take place inside AppModule.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>AppModule.java (partial)</b></div><div class="codeContent panelContent pdl">
 <script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[    public RequestExceptionHandler buildAppRequestExceptionHandler(
             final Logger logger,
@@ -218,7 +215,7 @@ public class ExceptionReport implements
         configuration.add(RequestExceptionHandler.class, handler);
     }
 ]]></script>
-</div></div><p>First we define the new service using a service builder method. This is an alternative to the <code>bind()</code> method; we define the service, its interface type (the return type of the method) and the service id (the part that follows "build" is the method name) and provide the implementation inline. A service builder method must return the service implementation, here implemented as an inner class.</p><p>The Logger resource that is passed into the builder method is the Logger appropriate for the service. ResponseRenderer and ComponentSource are two services defined by Tapestry.</p><p>With this in place, there are now two different services that implement the RequestExceptionHandler interface: the default one built into Tapestry (whose service id is "RequestExceptionHandler") and the new one defined in this module, "AppRequestExceptionHandler"). Without a little more work, Tapestry will be unable to determine which one to use when an exception does occur.</p><p>Tap
 estry has a pipeline for resolving injected dependencies; the ServiceOverride service is one part of that pipeline. Contributions to it are used to override an existing service, when the injection is exclusively by type.</p><p>Here we inject the AppRequestExceptionHandler service and contribute it as the override for type RequestExceptionHandler. The @Local annotation is used to select the RequestHandler service defined by this module, AppModule. Once contributed into ServiceOverride, it becomes the default service injected throughout the Registry.</p><p>This finally brings us to the point where we can see the result:</p><p><img class="confluence-embedded-image" src="overriding-exception-reporting.data/error3.png" data-image-src="/confluence/download/attachments/20645557/error3.png?version=1&amp;modificationDate=1273638562000&amp;api=v2" title="Errors show on Index page"></p><h2 id="OverridingExceptionReporting-Version3:DecoratingtheRequestExceptionHandler">Version 3: Decorating the
  RequestExceptionHandler</h2><p>A third option is available: we don't define a <em>new</em> service, but instead <em>decorate</em> the existing RequestExceptionHandler service. This approach means we don't have to make a contribution to the ServiceOverride service.</p><p>Service decoration is a powerful facility of Tapestry that is generally used to "wrap" an existing service with an interceptor that provides new functionality such as logging, security, transaction management or other cross-cutting concerns. The interceptor is an object that implements the same interface as the service being decorated, and usually delegates method invocations to it.</p><p>However, there's no requirement that an interceptor for a service actually invoke methods on the service; here we contribute a new implementation that <em>replaces</em> the original:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>AppModule.java 
 (partial)</b></div><div class="codeContent panelContent pdl">
+</div></div><p>First we define the new service using a service builder method. This is an alternative to the <code>bind()</code> method; we define the service, its interface type (the return type of the method) and the service id (the part that follows "build" is the method name) and provide the implementation inline. A service builder method must return the service implementation, here implemented as an inner class.</p><p>The Logger resource that is passed into the builder method is the Logger appropriate for the service. ResponseRenderer and ComponentSource are two services defined by Tapestry.</p><p>With this in place, there are now two different services that implement the RequestExceptionHandler interface: the default one built into Tapestry (whose service id is "RequestExceptionHandler") and the new one defined in this module, "AppRequestExceptionHandler"). Without a little more work, Tapestry will be unable to determine which one to use when an exception does occur.</p><p>Tap
 estry has a pipeline for resolving injected dependencies; the ServiceOverride service is one part of that pipeline. Contributions to it are used to override an existing service, when the injection is exclusively by type.</p><p>Here we inject the AppRequestExceptionHandler service and contribute it as the override for type RequestExceptionHandler. The @Local annotation is used to select the RequestHandler service defined by this module, AppModule. Once contributed into ServiceOverride, it becomes the default service injected throughout the Registry.</p><p>This finally brings us to the point where we can see the result:</p><p><img class="confluence-embedded-image confluence-content-image-border image-center" height="375" width="500" src="overriding-exception-reporting.data/index_as_excepton_report.png" data-image-src="/confluence/download/attachments/20645557/index_as_excepton_report.png?version=1&amp;modificationDate=1428096947818&amp;api=v2"></p><h2 id="OverridingExceptionReporting-
 Version3:DecoratingtheRequestExceptionHandler">Version 3: Decorating the RequestExceptionHandler</h2><p>A third option is available: we don't define a <em>new</em> service, but instead <em>decorate</em> the existing RequestExceptionHandler service. This approach means we don't have to make a contribution to the ServiceOverride service.</p><p>Service decoration is a powerful facility of Tapestry that is generally used to "wrap" an existing service with an interceptor that provides new functionality such as logging, security, transaction management or other cross-cutting concerns. The interceptor is an object that implements the same interface as the service being decorated, and usually delegates method invocations to it.</p><p>However, there's no requirement that an interceptor for a service actually invoke methods on the service; here we contribute a new implementation that <em>replaces</em> the original:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHead
 er panelHeader pdl" style="border-bottom-width: 1px;"><b>AppModule.java (partial)</b></div><div class="codeContent panelContent pdl">
 <script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[    public RequestExceptionHandler decorateRequestExceptionHandler(
             final Logger logger,
             final ResponseRenderer renderer,

Modified: websites/production/tapestry/content/security-faq.html
==============================================================================
--- websites/production/tapestry/content/security-faq.html (original)
+++ websites/production/tapestry/content/security-faq.html Fri Apr  3 22:19:42 2015
@@ -82,7 +82,7 @@ table.ScrollbarTable td.ScrollbarNextIco
                     <span class="icon icon-page" title="Page">Page:</span>            </div>
 
             <div class="details">
-                            <a shape="rect" href="security-faq.html">Security FAQ</a>
+                            <a shape="rect" href="https.html">HTTPS</a>
                     
                 
                             </div>
@@ -100,12 +100,12 @@ table.ScrollbarTable td.ScrollbarNextIco
                     <span class="icon icon-page" title="Page">Page:</span>            </div>
 
             <div class="details">
-                            <a shape="rect" href="https.html">HTTPS</a>
+                            <a shape="rect" href="security-faq.html">Security FAQ</a>
                     
                 
                             </div>
         </li></ul>
-</div><h3 id="SecurityFAQ-Thebuilt-inPageCatalogandServiceStatuspagesarevisibleinmyproductionapplicationandIdon'twantthemtobe,whatcanIdo?">The built-in PageCatalog and ServiceStatus pages are visible in my production application and I don't want them to be, what can I do?</h3><p>First off all, don't panic: these pages are marked with the @<a shape="rect" class="external-link" href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/annotations/WhitelistAccessOnly.html">WhitelistAccessOnly</a> annotation, which makes them invisible to clients that are not on the whitelist. Try accessing the page from a different workstation and you may find that the pages are not visible after all.</p><p>Sometimes, in production, a firewall or proxy may make it look like the client web browser originates from localhost; in that situation, you may want to disable the logic that puts localhost onto the whitelist. This determination is made by the contributions to the <a shape="rect" class=
 "external-link" href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/services/security/ClientWhitelist.html">ClientWhitelist</a> service. Tapestry makes a contribution with id "LocalhostOnly", which one of your modules can override:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+</div><h3 id="SecurityFAQ-Thebuilt-inDashboardpagearevisibleinmyproductionapplicationandIdon'twantthemtobe,whatcanIdo?">The built-in Dashboard page are visible in my production application and I don't want them to be, what can I do?</h3><p>First off all, don't panic: the <a shape="rect" href="development-dashboard.html">Developer Dashboard</a> page is marked with the @<a shape="rect" class="external-link" href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/annotations/WhitelistAccessOnly.html">WhitelistAccessOnly</a> annotation, which makes it invisible to clients that are not on the whitelist. Try accessing the page from a different workstation and you may find that the pages are not visible after all.</p><p>Sometimes, in production, a firewall or proxy may make it look like the client web browser originates from localhost; in that situation, you may want to disable the logic that puts localhost onto the whitelist. This determination is made by the contributions t
 o the <a shape="rect" class="external-link" href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/services/security/ClientWhitelist.html">ClientWhitelist</a> service. Tapestry makes a contribution with id "LocalhostOnly", which one of your modules can override:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
 <script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[  @Contribute(ClientWhitelist.class)
   public static void turnOffLocalhostInProduction(OrderedConfiguration&lt;WhitelistAnalyzer&gt; configuration, 
                                                  @Symbol(SymbolConstants.PRODUCTION_MODE) boolean productionMode) {



Mime
View raw message