[jira] Created: (TAP5-556) Fix TranslatorSourceImplTest
Fix TranslatorSourceImplTest Key: TAP5-556 URL: https://issues.apache.org/jira/browse/TAP5-556 Project: Tapestry 5 Issue Type: Bug Components: tapestry-core Reporter: Igor Drobiazko SInce TAP5-540 is fixed I can't run TranslatorSourceImplTest. to_client(org.apache.tapestry5.internal.services.TranslatorSourceImplTest) Time elapsed: 0.031 sec <<< FAILURE! java.lang.AssertionError: expected:<3.143> but was:<3,143> at org.testng.Assert.fail(Assert.java:84) at org.testng.Assert.failNotEquals(Assert.java:438) at org.testng.Assert.assertEquals(Assert.java:108) at org.testng.Assert.assertEquals(Assert.java:129) at org.testng.Assert.assertEquals(Assert.java:139) at org.apache.tapestry5.internal.services.TranslatorSourceImplTest.to_client(TranslatorSourceImplTest.java:130) to_client(org.apache.tapestry5.internal.services.TranslatorSourceImplTest) Time elapsed: 0 sec <<< FAILURE! java.lang.AssertionError: expected:<-22.7> but was:<-22,7> at org.testng.Assert.fail(Assert.java:84) at org.testng.Assert.failNotEquals(Assert.java:438) at org.testng.Assert.assertEquals(Assert.java:108) at org.testng.Assert.assertEquals(Assert.java:129) at org.testng.Assert.assertEquals(Assert.java:139) at org.apache.tapestry5.internal.services.TranslatorSourceImplTest.to_client(TranslatorSourceImplTest.java:130) to_client(org.apache.tapestry5.internal.services.TranslatorSourceImplTest) Time elapsed: 0 sec <<< FAILURE! java.lang.AssertionError: expected:<-9876543219876543321987654321.12345123451234512345> but was:<-9876543219876543321987654321,12345123451234512345> at org.testng.Assert.fail(Assert.java:84) at org.testng.Assert.failNotEquals(Assert.java:438) at org.testng.Assert.assertEquals(Assert.java:108) at org.testng.Assert.assertEquals(Assert.java:129) at org.testng.Assert.assertEquals(Assert.java:139) at org.apache.tapestry5.internal.services.TranslatorSourceImplTest.to_client(TranslatorSourceImplTest.java:130) parse_client(org.apache.tapestry5.internal.services.TranslatorSourceImplTest) Time elapsed: 0.016 sec <<< FAILURE! java.lang.AssertionError: expected:<2> but was:<20> at org.testng.Assert.fail(Assert.java:84) at org.testng.Assert.failNotEquals(Assert.java:438) at org.testng.Assert.assertEquals(Assert.java:108) at org.testng.Assert.assertEquals(Assert.java:118) at org.apache.tapestry5.internal.services.TranslatorSourceImplTest.parse_client(TranslatorSourceImplTest.java:169) parse_client(org.apache.tapestry5.internal.services.TranslatorSourceImplTest) Time elapsed: 0 sec <<< FAILURE! java.lang.AssertionError: expected:<3.1428571429> but was:<3.1428571429E10> at org.testng.Assert.fail(Assert.java:84) at org.testng.Assert.failNotEquals(Assert.java:438) at org.testng.Assert.assertEquals(Assert.java:108) at org.testng.Assert.assertEquals(Assert.java:118) at org.apache.tapestry5.internal.services.TranslatorSourceImplTest.parse_client(TranslatorSourceImplTest.java:169) parse_client(org.apache.tapestry5.internal.services.TranslatorSourceImplTest) Time elapsed: 0 sec <<< FAILURE! java.lang.AssertionError: expected:<28.95> but was:<2895.0> at org.testng.Assert.fail(Assert.java:84) at org.testng.Assert.failNotEquals(Assert.java:438) at org.testng.Assert.assertEquals(Assert.java:108) at org.testng.Assert.assertEquals(Assert.java:118) at org.apache.tapestry5.internal.services.TranslatorSourceImplTest.parse_client(TranslatorSourceImplTest.java:169) -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Closed: (TAP5-520) Using regular expressions with the @Validate annotation causes odd parse errors if the regexp includes common characters (including commas)
[ https://issues.apache.org/jira/browse/TAP5-520?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Igor Drobiazko closed TAP5-520. --- Resolution: Fixed Fix Version/s: 5.1.0.1 > Using regular expressions with the @Validate annotation causes odd parse > errors if the regexp includes common characters (including commas) > --- > > Key: TAP5-520 > URL: https://issues.apache.org/jira/browse/TAP5-520 > Project: Tapestry 5 > Issue Type: Bug > Components: tapestry-core >Affects Versions: 5.0.18 >Reporter: Konstantin Miklevskiy >Assignee: Igor Drobiazko >Priority: Minor > Fix For: 5.1.0.1 > > > Try adding this field to your form: > @Validate("regexp=^([a-zA-Z0-9]{2,4})+$") > private String somefield; > Page will fail to render with exception saying: > Render queue error in BeginRender[mypage.somefield]: Failure reading > parameter 'validate' of component mypage.somefield: Coercion of > ^([a-zA-Z0-9]{2 to type java.util.regex.Pattern (via String --> > java.util.regex.Pattern) failed: Unclosed counted closure near index 15 > ^([a-zA-Z0-9]{2 ^ -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
svn commit: r750355 - in /tapestry/tapestry5/trunk/tapestry-core/src: main/java/org/apache/tapestry5/internal/beaneditor/ test/java/org/apache/tapestry5/internal/beaneditor/
Author: drobiazko Date: Thu Mar 5 07:40:27 2009 New Revision: 750355 URL: http://svn.apache.org/viewvc?rev=750355&view=rev Log: TAP5-520: Using regular expressions with the @Validate annotation causes odd parse errors if the regexp includes common characters (including commas) Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/beaneditor/ValidateAnnotationConstraintGenerator.java tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/internal/beaneditor/ValidateAnnotationConstraintGeneratorTest.java Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/beaneditor/ValidateAnnotationConstraintGenerator.java URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/beaneditor/ValidateAnnotationConstraintGenerator.java?rev=750355&r1=750354&r2=750355&view=diff == --- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/beaneditor/ValidateAnnotationConstraintGenerator.java (original) +++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/beaneditor/ValidateAnnotationConstraintGenerator.java Thu Mar 5 07:40:27 2009 @@ -34,7 +34,11 @@ if (annotation == null) return null; -return Arrays.asList(annotation.value().split(",")); +//TAP5-520: Commas within regular expressions like {n,m} or {n,} or a\,b . +//We use Negative Lookahead to avoid matching the case a\,b . +//We use Positive Lookahead to avoid matching cases {n,m} and {n,}. +//http://www.regular-expressions.info/lookaround.html +return Arrays.asList(annotation.value().split("(?http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/internal/beaneditor/ValidateAnnotationConstraintGeneratorTest.java?rev=750355&r1=750354&r2=750355&view=diff == --- tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/internal/beaneditor/ValidateAnnotationConstraintGeneratorTest.java (original) +++ tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/internal/beaneditor/ValidateAnnotationConstraintGeneratorTest.java Thu Mar 5 07:40:27 2009 @@ -61,7 +61,7 @@ public void multiple_constraints() { PropertyConduit conduit = mockPropertyConduit(); -Validate validate = newValidate("required,minlength=3"); +Validate validate = newValidate("required,minlength=3,regexp=^([a-zA-Z0-9]{2,4})+$"); train_getAnnotation(conduit, Validate.class, validate); @@ -69,7 +69,26 @@ ValidationConstraintGenerator gen = new ValidateAnnotationConstraintGenerator(); -assertEquals(gen.buildConstraints(null, conduit), Arrays.asList("required", "minlength=3")); +assertEquals(gen.buildConstraints(null, conduit), Arrays.asList("required", "minlength=3", "regexp=^([a-zA-Z0-9]{2,4})+$")); + +verify(); +} + + +@Test +public void regex_ranges_constraints() +{ +PropertyConduit conduit = mockPropertyConduit(); +Validate validate = newValidate("regexp=^([a]{50,125}[0-9]{2,4})+$,required,567matcher,regexp=a\\,b,regexp=a{1,}"); + +train_getAnnotation(conduit, Validate.class, validate); + +replay(); + +ValidationConstraintGenerator gen = new ValidateAnnotationConstraintGenerator(); + +assertEquals(gen.buildConstraints(null, conduit), +Arrays.asList("regexp=^([a]{50,125}[0-9]{2,4})+$","required", "567matcher", "regexp=a\\,b", "regexp=a{1,}")); verify(); }
[jira] Created: (TAP5-555) Tapestry.ScriptManager.contains throws error when element doesn't have the prop param
Tapestry.ScriptManager.contains throws error when element doesn't have the prop param - Key: TAP5-555 URL: https://issues.apache.org/jira/browse/TAP5-555 Project: Tapestry 5 Issue Type: Bug Components: tapestry-core Affects Versions: 5.0.18 Reporter: Raul Montes Tapestry.ScriptManager.contains firsts lines are: return $A(collection).any(function (element) { var existing = element[prop]; if (existing.blank()) return false; If element doesn't have the prop, then the existing var is null and existing.blank() throws an exception because the call of a method to a null variable. This problem happens for example (because of this i detected it) when i want to update a zone with a block that also loads stylesheets and scripts and, in the original page, there are script and or style tags embedded (
[jira] Closed: (TAP5-545) Upgrade to Scriptaculous 1.8.2 (released Nov 2008)
[ https://issues.apache.org/jira/browse/TAP5-545?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship closed TAP5-545. - Resolution: Fixed Fix Version/s: 5.1.0.1 > Upgrade to Scriptaculous 1.8.2 (released Nov 2008) > -- > > Key: TAP5-545 > URL: https://issues.apache.org/jira/browse/TAP5-545 > Project: Tapestry 5 > Issue Type: Improvement > Components: tapestry-core >Affects Versions: 5.1.0.1 >Reporter: Howard M. Lewis Ship >Assignee: Howard M. Lewis Ship >Priority: Minor > Fix For: 5.1.0.1 > > > http://script.aculo.us/ -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Updated: (TAP5-545) Upgrade to Scriptaculous 1.8.2 (released Nov 2008)
[ https://issues.apache.org/jira/browse/TAP5-545?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship updated TAP5-545: -- Summary: Upgrade to Scriptaculous 1.8.2 (released Nov 2008) (was: Uprade to Scriptaculous 1.8.2 (released Nov 2008)) > Upgrade to Scriptaculous 1.8.2 (released Nov 2008) > -- > > Key: TAP5-545 > URL: https://issues.apache.org/jira/browse/TAP5-545 > Project: Tapestry 5 > Issue Type: Improvement > Components: tapestry-core >Affects Versions: 5.1.0.1 >Reporter: Howard M. Lewis Ship >Assignee: Howard M. Lewis Ship >Priority: Minor > Fix For: 5.1.0.1 > > > http://script.aculo.us/ -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
svn commit: r750301 [4/4] - in /tapestry/tapestry5/trunk/tapestry-core/src/main: java/org/apache/tapestry5/services/ resources/org/apache/tapestry5/ resources/org/apache/tapestry5/scriptaculous_1_8_1/
Added: tapestry/tapestry5/trunk/tapestry-core/src/main/resources/org/apache/tapestry5/scriptaculous_1_8_2/scriptaculous.js URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/resources/org/apache/tapestry5/scriptaculous_1_8_2/scriptaculous.js?rev=750301&view=auto == --- tapestry/tapestry5/trunk/tapestry-core/src/main/resources/org/apache/tapestry5/scriptaculous_1_8_2/scriptaculous.js (added) +++ tapestry/tapestry5/trunk/tapestry-core/src/main/resources/org/apache/tapestry5/scriptaculous_1_8_2/scriptaculous.js Thu Mar 5 02:54:30 2009 @@ -0,0 +1,62 @@ +// script.aculo.us scriptaculous.js v1.8.2, Tue Nov 18 18:30:58 +0100 2008 + +// Copyright (c) 2005-2008 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us) +// +// Permission is hereby granted, free of charge, to any person obtaining +// a copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to +// permit persons to whom the Software is furnished to do so, subject to +// the following conditions: +// +// The above copyright notice and this permission notice shall be +// included in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +// +// For details, see the script.aculo.us web site: http://script.aculo.us/ + +var Scriptaculous = { + Version: '1.8.2', + require: function(libraryName) { +// inserting via DOM fails in Safari 2.0, so brute force approach +document.write('
svn commit: r750301 [2/4] - in /tapestry/tapestry5/trunk/tapestry-core/src/main: java/org/apache/tapestry5/services/ resources/org/apache/tapestry5/ resources/org/apache/tapestry5/scriptaculous_1_8_1/
Added: tapestry/tapestry5/trunk/tapestry-core/src/main/resources/org/apache/tapestry5/scriptaculous_1_8_2/effects.js URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/resources/org/apache/tapestry5/scriptaculous_1_8_2/effects.js?rev=750301&view=auto == --- tapestry/tapestry5/trunk/tapestry-core/src/main/resources/org/apache/tapestry5/scriptaculous_1_8_2/effects.js (added) +++ tapestry/tapestry5/trunk/tapestry-core/src/main/resources/org/apache/tapestry5/scriptaculous_1_8_2/effects.js Thu Mar 5 02:54:30 2009 @@ -0,0 +1,1130 @@ +// script.aculo.us effects.js v1.8.2, Tue Nov 18 18:30:58 +0100 2008 + +// Copyright (c) 2005-2008 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us) +// Contributors: +// Justin Palmer (http://encytemedia.com/) +// Mark Pilgrim (http://diveintomark.org/) +// Martin Bialasinki +// +// script.aculo.us is freely distributable under the terms of an MIT-style license. +// For details, see the script.aculo.us web site: http://script.aculo.us/ + +// converts rgb() and #xxx to #xx format, +// returns self (or first argument) if not convertable +String.prototype.parseColor = function() { + var color = '#'; + if (this.slice(0,4) == 'rgb(') { +var cols = this.slice(4,this.length-1).split(','); +var i=0; do { color += parseInt(cols[i]).toColorPart() } while (++i<3); + } else { +if (this.slice(0,1) == '#') { + if (this.length==4) for(var i=1;i<4;i++) color += (this.charAt(i) + this.charAt(i)).toLowerCase(); + if (this.length==7) color = this.toLowerCase(); +} + } + return (color.length==7 ? color : (arguments[0] || this)); +}; + +/*--*/ + +Element.collectTextNodes = function(element) { + return $A($(element).childNodes).collect( function(node) { +return (node.nodeType==3 ? node.nodeValue : + (node.hasChildNodes() ? Element.collectTextNodes(node) : '')); + }).flatten().join(''); +}; + +Element.collectTextNodesIgnoreClass = function(element, className) { + return $A($(element).childNodes).collect( function(node) { +return (node.nodeType==3 ? node.nodeValue : + ((node.hasChildNodes() && !Element.hasClassName(node,className)) ? +Element.collectTextNodesIgnoreClass(node, className) : '')); + }).flatten().join(''); +}; + +Element.setContentZoom = function(element, percent) { + element = $(element); + element.setStyle({fontSize: (percent/100) + 'em'}); + if (Prototype.Browser.WebKit) window.scrollBy(0,0); + return element; +}; + +Element.getInlineOpacity = function(element){ + return $(element).style.opacity || ''; +}; + +Element.forceRerendering = function(element) { + try { +element = $(element); +var n = document.createTextNode(' '); +element.appendChild(n); +element.removeChild(n); + } catch(e) { } +}; + +/*--*/ + +var Effect = { + _elementDoesNotExistError: { +name: 'ElementDoesNotExistError', +message: 'The specified DOM element does not exist, but is required for this effect to operate' + }, + Transitions: { +linear: Prototype.K, +sinoidal: function(pos) { + return (-Math.cos(pos*Math.PI)/2) + .5; +}, +reverse: function(pos) { + return 1-pos; +}, +flicker: function(pos) { + var pos = ((-Math.cos(pos*Math.PI)/4) + .75) + Math.random()/4; + return pos > 1 ? 1 : pos; +}, +wobble: function(pos) { + return (-Math.cos(pos*Math.PI*(9*pos))/2) + .5; +}, +pulse: function(pos, pulses) { + return (-Math.cos((pos*((pulses||5)-.5)*2)*Math.PI)/2) + .5; +}, +spring: function(pos) { + return 1 - (Math.cos(pos * 4.5 * Math.PI) * Math.exp(-pos * 6)); +}, +none: function(pos) { + return 0; +}, +full: function(pos) { + return 1; +} + }, + DefaultOptions: { +duration: 1.0, // seconds +fps:100, // 100= assume 66fps max. +sync: false, // true for combining +from: 0.0, +to: 1.0, +delay: 0.0, +queue: 'parallel' + }, + tagifyText: function(element) { +var tagifyStyle = 'position:relative'; +if (Prototype.Browser.IE) tagifyStyle += ';zoom:1'; + +element = $(element); +$A(element.childNodes).each( function(child) { + if (child.nodeType==3) { +child.nodeValue.toArray().each( function(character) { + element.insertBefore( +new Element('span', {style: tagifyStyle}).update( + character == ' ' ? String.fromCharCode(160) : character), + child); +}); +Element.remove(child); + } +}); + }, + multiple: function(element, effect) { +var elements; +if (((typeof element == 'object') || +Object.isFunction(element)) && + (element.length)) + elements = element;
[jira] Commented: (TAP5-554) NPE when click addRow within AjaxFormLoop
[ https://issues.apache.org/jira/browse/TAP5-554?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12679037#action_12679037 ] Yunhua Sang commented on TAP5-554: -- To reproduce: 1) edit FormInjectorDemo.tml, replace HTML element to http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";> http://www.w3.org/1999/xhtml"; xmlns:t="http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";> 2) add anything in front of in > NPE when click addRow within AjaxFormLoop > - > > Key: TAP5-554 > URL: https://issues.apache.org/jira/browse/TAP5-554 > Project: Tapestry 5 > Issue Type: Bug > Components: tapestry-core >Affects Versions: 5.1.0.0, 5.1.0.1 >Reporter: Yunhua Sang >Priority: Minor > > On the screen: > Ajax failure: Status 500 for > /tapestry/forminjectordemo.loop.rowinjector:inject/1236217007110?t:ac=FakePageActivationContextValue&t:formcomponentid=FormInjectorDemo:form&t:formid=form: > java.lang.NullPointerException > In console: > ERROR] RequestExceptionHandler Processing of request failed with uncaught > exception: java.lang.NullPointerException > java.lang.NullPointerException > at > org.apache.tapestry5.dom.Element.createNamespaceURIToPrefix(Element.java:678) > at org.apache.tapestry5.dom.Element.toMarkup(Element.java:335) > at org.apache.tapestry5.dom.Element.writeChildMarkup(Element.java:872) > at org.apache.tapestry5.dom.Element.getChildMarkup(Element.java:885) > at > org.apache.tapestry5.internal.services.PageRenderQueueImpl.renderPartial(PageRenderQueueImpl.java:163) > at > $PageRenderQueue_11fd441d050.renderPartial($PageRenderQueue_11fd441d050.java) > at > $PageRenderQueue_11fd441d04f.renderPartial($PageRenderQueue_11fd441d04f.java) > at > org.apache.tapestry5.internal.services.PartialMarkupRendererTerminator.renderMarkup(PartialMarkupRendererTerminator.java:39) > at > org.apache.tapestry5.services.TapestryModule$31.renderMarkup(TapestryModule.java:1821) > at > $PartialMarkupRenderer_11fd441d129.renderMarkup($PartialMarkupRenderer_11fd441d129.java) > at > org.apache.tapestry5.services.TapestryModule$30.renderMarkup(TapestryModule.java:1802) > at > $PartialMarkupRenderer_11fd441d129.renderMarkup($PartialMarkupRenderer_11fd441d129.java) > at > org.apache.tapestry5.services.TapestryModule$29.renderMarkup(TapestryModule.java:1784) > at > $PartialMarkupRenderer_11fd441d129.renderMarkup($PartialMarkupRenderer_11fd441d129.java) > at > org.apache.tapestry5.services.TapestryModule$28.renderMarkup(TapestryModule.java:1766) > at > $PartialMarkupRenderer_11fd441d129.renderMarkup($PartialMarkupRenderer_11fd441d129.java) > at > org.apache.tapestry5.services.TapestryModule$27.renderMarkup(TapestryModule.java:1740) > at > $PartialMarkupRenderer_11fd441d129.renderMarkup($PartialMarkupRenderer_11fd441d129.java) > at > $PartialMarkupRenderer_11fd441d128.renderMarkup($PartialMarkupRenderer_11fd441d128.java) > at > org.apache.tapestry5.internal.services.AjaxPartialResponseRendererImpl.renderPartialPageMarkup(AjaxPartialResponseRendererImpl.java:79) > at > $AjaxPartialResponseRenderer_11fd441d126.renderPartialPageMarkup($AjaxPartialResponseRenderer_11fd441d126.java) > at > org.apache.tapestry5.internal.services.AjaxComponentEventRequestHandler.handle(AjaxComponentEventRequestHandler.java:118) > at > $ComponentEventRequestHandler_11fd441d123.handle($ComponentEventRequestHandler_11fd441d123.java) > at > org.apache.tapestry5.internal.services.AjaxFilter.handle(AjaxFilter.java:42) > at > $ComponentEventRequestHandler_11fd441d125.handle($ComponentEventRequestHandler_11fd441d125.java) > at > org.apache.tapestry5.services.TapestryModule$35.handle(TapestryModule.java:2109) > at > $ComponentEventRequestHandler_11fd441d125.handle($ComponentEventRequestHandler_11fd441d125.java) > at > $ComponentEventRequestHandler_11fd441cffd.handle($ComponentEventRequestHandler_11fd441cffd.java) > at > org.apache.tapestry5.internal.services.ComponentRequestHandlerTerminator.handleComponentEvent(ComponentRequestHandlerTerminator.java:43) > at > $ComponentRequestHandler_11fd441cff6.handleComponentEvent($ComponentRequestHandler_11fd441cff6.java) > at > org.apache.tapestry5.internal.services.ComponentEventDispatcher.dispatch(ComponentEventDispatcher.java:138) > at $Dispatcher_11fd441cff7.dispatch($Dispatcher_11fd441cff7.java) > at $Dispatcher_11fd441cfed.dispatch($Dispatcher_11fd441cfed.java) > at > org.apache.tapestry5.services.TapestryModule$RequestHandlerTerminator.service(TapestryModule.java:246) > at > org.apache.tapestry5.internal.services.RequestErrorFilter.service(RequestErrorFilter.java:26) > at
[jira] Created: (TAP5-554) NPE when click addRow within AjaxFormLoop
NPE when click addRow within AjaxFormLoop - Key: TAP5-554 URL: https://issues.apache.org/jira/browse/TAP5-554 Project: Tapestry 5 Issue Type: Bug Components: tapestry-core Affects Versions: 5.1.0.0, 5.1.0.1 Reporter: Yunhua Sang Priority: Minor On the screen: Ajax failure: Status 500 for /tapestry/forminjectordemo.loop.rowinjector:inject/1236217007110?t:ac=FakePageActivationContextValue&t:formcomponentid=FormInjectorDemo:form&t:formid=form: java.lang.NullPointerException In console: ERROR] RequestExceptionHandler Processing of request failed with uncaught exception: java.lang.NullPointerException java.lang.NullPointerException at org.apache.tapestry5.dom.Element.createNamespaceURIToPrefix(Element.java:678) at org.apache.tapestry5.dom.Element.toMarkup(Element.java:335) at org.apache.tapestry5.dom.Element.writeChildMarkup(Element.java:872) at org.apache.tapestry5.dom.Element.getChildMarkup(Element.java:885) at org.apache.tapestry5.internal.services.PageRenderQueueImpl.renderPartial(PageRenderQueueImpl.java:163) at $PageRenderQueue_11fd441d050.renderPartial($PageRenderQueue_11fd441d050.java) at $PageRenderQueue_11fd441d04f.renderPartial($PageRenderQueue_11fd441d04f.java) at org.apache.tapestry5.internal.services.PartialMarkupRendererTerminator.renderMarkup(PartialMarkupRendererTerminator.java:39) at org.apache.tapestry5.services.TapestryModule$31.renderMarkup(TapestryModule.java:1821) at $PartialMarkupRenderer_11fd441d129.renderMarkup($PartialMarkupRenderer_11fd441d129.java) at org.apache.tapestry5.services.TapestryModule$30.renderMarkup(TapestryModule.java:1802) at $PartialMarkupRenderer_11fd441d129.renderMarkup($PartialMarkupRenderer_11fd441d129.java) at org.apache.tapestry5.services.TapestryModule$29.renderMarkup(TapestryModule.java:1784) at $PartialMarkupRenderer_11fd441d129.renderMarkup($PartialMarkupRenderer_11fd441d129.java) at org.apache.tapestry5.services.TapestryModule$28.renderMarkup(TapestryModule.java:1766) at $PartialMarkupRenderer_11fd441d129.renderMarkup($PartialMarkupRenderer_11fd441d129.java) at org.apache.tapestry5.services.TapestryModule$27.renderMarkup(TapestryModule.java:1740) at $PartialMarkupRenderer_11fd441d129.renderMarkup($PartialMarkupRenderer_11fd441d129.java) at $PartialMarkupRenderer_11fd441d128.renderMarkup($PartialMarkupRenderer_11fd441d128.java) at org.apache.tapestry5.internal.services.AjaxPartialResponseRendererImpl.renderPartialPageMarkup(AjaxPartialResponseRendererImpl.java:79) at $AjaxPartialResponseRenderer_11fd441d126.renderPartialPageMarkup($AjaxPartialResponseRenderer_11fd441d126.java) at org.apache.tapestry5.internal.services.AjaxComponentEventRequestHandler.handle(AjaxComponentEventRequestHandler.java:118) at $ComponentEventRequestHandler_11fd441d123.handle($ComponentEventRequestHandler_11fd441d123.java) at org.apache.tapestry5.internal.services.AjaxFilter.handle(AjaxFilter.java:42) at $ComponentEventRequestHandler_11fd441d125.handle($ComponentEventRequestHandler_11fd441d125.java) at org.apache.tapestry5.services.TapestryModule$35.handle(TapestryModule.java:2109) at $ComponentEventRequestHandler_11fd441d125.handle($ComponentEventRequestHandler_11fd441d125.java) at $ComponentEventRequestHandler_11fd441cffd.handle($ComponentEventRequestHandler_11fd441cffd.java) at org.apache.tapestry5.internal.services.ComponentRequestHandlerTerminator.handleComponentEvent(ComponentRequestHandlerTerminator.java:43) at $ComponentRequestHandler_11fd441cff6.handleComponentEvent($ComponentRequestHandler_11fd441cff6.java) at org.apache.tapestry5.internal.services.ComponentEventDispatcher.dispatch(ComponentEventDispatcher.java:138) at $Dispatcher_11fd441cff7.dispatch($Dispatcher_11fd441cff7.java) at $Dispatcher_11fd441cfed.dispatch($Dispatcher_11fd441cfed.java) at org.apache.tapestry5.services.TapestryModule$RequestHandlerTerminator.service(TapestryModule.java:246) at org.apache.tapestry5.internal.services.RequestErrorFilter.service(RequestErrorFilter.java:26) at $RequestHandler_11fd441cfee.service($RequestHandler_11fd441cfee.java) at org.apache.tapestry5.services.TapestryModule$4.service(TapestryModule.java:765) at $RequestHandler_11fd441cfee.service($RequestHandler_11fd441cfee.java) at org.apache.tapestry5.services.TapestryModule$3.service(TapestryModule.java:755) at $RequestHandler_11fd441cfee.service($RequestHandler_11fd441cfee.java) at org.apache.tapestry5.internal.services.StaticFilesFilter.service(StaticFilesFilter.java:85) at $RequestHandler_11fd441cfee.service($RequestHandler_11
[jira] Assigned: (TAP5-545) Uprade to Scriptaculous 1.8.2 (released Nov 2008)
[ https://issues.apache.org/jira/browse/TAP5-545?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship reassigned TAP5-545: - Assignee: Howard M. Lewis Ship > Uprade to Scriptaculous 1.8.2 (released Nov 2008) > - > > Key: TAP5-545 > URL: https://issues.apache.org/jira/browse/TAP5-545 > Project: Tapestry 5 > Issue Type: Improvement > Components: tapestry-core >Affects Versions: 5.1.0.1 >Reporter: Howard M. Lewis Ship >Assignee: Howard M. Lewis Ship >Priority: Minor > > http://script.aculo.us/ -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Commented: (TAP5-469) ResponseCompressionAnalyzer: application/json responses should be uncompressable by default
[ https://issues.apache.org/jira/browse/TAP5-469?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12679034#action_12679034 ] Howard M. Lewis Ship commented on TAP5-469: --- I'm still not convinced this is necessary, but a workaround is: public static void contributeResponseCompressionAnalyzer(Configuration configuration) { configuration.add("application/json"); } > ResponseCompressionAnalyzer: application/json responses should be > uncompressable by default > --- > > Key: TAP5-469 > URL: https://issues.apache.org/jira/browse/TAP5-469 > Project: Tapestry 5 > Issue Type: Bug > Components: tapestry-core >Affects Versions: 5.1.0.0 >Reporter: Paudi Moriarty > > GZip compressed responses with Content-Type: application/json are not handled > correctly by at least Firefox or IE and should be configured as > uncompressable by default > When the response is received in prototype's Ajax.Request > response.responseText is "". -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Closed: (TAP5-540) Allow exact parsing of numeric client input by creating a BigDecimal Translator and enabling parseBigDecimal in DecimalFormat
[ https://issues.apache.org/jira/browse/TAP5-540?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship closed TAP5-540. - Resolution: Fixed Fix Version/s: 5.1.0.1 > Allow exact parsing of numeric client input by creating a BigDecimal > Translator and enabling parseBigDecimal in DecimalFormat > - > > Key: TAP5-540 > URL: https://issues.apache.org/jira/browse/TAP5-540 > Project: Tapestry 5 > Issue Type: Improvement > Components: tapestry-core >Affects Versions: 5.1.0.1 >Reporter: Paudi Moriarty >Assignee: Howard M. Lewis Ship > Fix For: 5.1.0.1 > > > The current NumericTranslator is great but it is not easy to build on it > since the classes are internal. > Tapestry should provide a BigDecimal Translator which uses the infrastructure > created for TAP5-211 but parses client input directly to BigDecimal retaining > the full precision of that input. > For example, I need a client input of 100.00 to be translated to a BigDecimal > with value 100.00. Contributing a NumericTranslator results in a > BigDecimal with value 100 because the input is parsed to a long by the > NumberFormat before being type coerced. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
svn commit: r750246 - in /tapestry/tapestry5/trunk/tapestry-core/src: main/java/org/apache/tapestry5/internal/translator/ main/java/org/apache/tapestry5/services/ test/java/org/apache/tapestry5/intern
Author: hlship Date: Thu Mar 5 00:08:09 2009 New Revision: 750246 URL: http://svn.apache.org/viewvc?rev=750246&view=rev Log: TAP5-540: Allow exact parsing of numeric client input by creating a BigDecimal Translator and enabling parseBigDecimal in DecimalFormat Added: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/translator/BigDecimalNumericFormatter.java tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/translator/BigIntegerNumericFormatter.java tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/translator/BigTypesFormatter.java tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/translator/NumericFormatter.java tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/translator/NumericFormatterImpl.java Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/translator/NumericTranslator.java tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/translator/NumericTranslatorSupport.java tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/translator/NumericTranslatorSupportImpl.java tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/TapestryModule.java tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/internal/services/TranslatorSourceImplTest.java Added: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/translator/BigDecimalNumericFormatter.java URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/translator/BigDecimalNumericFormatter.java?rev=750246&view=auto == --- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/translator/BigDecimalNumericFormatter.java (added) +++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/translator/BigDecimalNumericFormatter.java Thu Mar 5 00:08:09 2009 @@ -0,0 +1,31 @@ +// Copyright 2009 The Apache Software Foundation +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package org.apache.tapestry5.internal.translator; + +import java.math.BigDecimal; +import java.text.DecimalFormatSymbols; + +public class BigDecimalNumericFormatter extends BigTypesFormatter +{ +public BigDecimalNumericFormatter(DecimalFormatSymbols symbols) +{ +super(symbols); +} + +protected Number parseConvertedValue(String converted) +{ +return new BigDecimal(converted); +} +} Added: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/translator/BigIntegerNumericFormatter.java URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/translator/BigIntegerNumericFormatter.java?rev=750246&view=auto == --- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/translator/BigIntegerNumericFormatter.java (added) +++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/translator/BigIntegerNumericFormatter.java Thu Mar 5 00:08:09 2009 @@ -0,0 +1,32 @@ +// Copyright 2009 The Apache Software Foundation +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package org.apache.tapestry5.internal.translator; + +import java.math.BigInteger; +import java.text.DecimalFormatSymbols; + +public class BigIntegerNumericFormatter extends BigTypesFormatter +{ +public BigIntegerNumericFormatter(DecimalFormatSymbols symbols) +{ +super(symbols); +} + + +protected Number parseConvertedValue(String fixedNeg) +{ +
[jira] Commented: (TAP5-520) Using regular expressions with the @Validate annotation causes odd parse errors if the regexp includes common characters (including commas)
[ https://issues.apache.org/jira/browse/TAP5-520?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12678992#action_12678992 ] Igor Drobiazko commented on TAP5-520: - Why "invalid" or "won't fix"? This is a bug. I have already a fix using positive and negative lookahead. Was just thinking about test cases. Shall I commit the fix? > Using regular expressions with the @Validate annotation causes odd parse > errors if the regexp includes common characters (including commas) > --- > > Key: TAP5-520 > URL: https://issues.apache.org/jira/browse/TAP5-520 > Project: Tapestry 5 > Issue Type: Bug > Components: tapestry-core >Affects Versions: 5.0.18 >Reporter: Konstantin Miklevskiy >Assignee: Igor Drobiazko >Priority: Minor > > Try adding this field to your form: > @Validate("regexp=^([a-zA-Z0-9]{2,4})+$") > private String somefield; > Page will fail to render with exception saying: > Render queue error in BeginRender[mypage.somefield]: Failure reading > parameter 'validate' of component mypage.somefield: Coercion of > ^([a-zA-Z0-9]{2 to type java.util.regex.Pattern (via String --> > java.util.regex.Pattern) failed: Unclosed counted closure near index 15 > ^([a-zA-Z0-9]{2 ^ -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Commented: (TAP5-540) Allow exact parsing of numeric client input by creating a BigDecimal Translator and enabling parseBigDecimal in DecimalFormat
[ https://issues.apache.org/jira/browse/TAP5-540?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12678982#action_12678982 ] Thiago H. de Paula Figueiredo commented on TAP5-540: Tip: BigDecimal.scale() retuns the number of digits to the right of the decimal point. Then use DecimalFormat.setMinimumFractionDigits() to define the number of digits to the right of the decimal point when formatting. > Allow exact parsing of numeric client input by creating a BigDecimal > Translator and enabling parseBigDecimal in DecimalFormat > - > > Key: TAP5-540 > URL: https://issues.apache.org/jira/browse/TAP5-540 > Project: Tapestry 5 > Issue Type: Improvement > Components: tapestry-core >Affects Versions: 5.1.0.1 >Reporter: Paudi Moriarty >Assignee: Howard M. Lewis Ship > > The current NumericTranslator is great but it is not easy to build on it > since the classes are internal. > Tapestry should provide a BigDecimal Translator which uses the infrastructure > created for TAP5-211 but parses client input directly to BigDecimal retaining > the full precision of that input. > For example, I need a client input of 100.00 to be translated to a BigDecimal > with value 100.00. Contributing a NumericTranslator results in a > BigDecimal with value 100 because the input is parsed to a long by the > NumberFormat before being type coerced. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Commented: (TAP5-540) Allow exact parsing of numeric client input by creating a BigDecimal Translator and enabling parseBigDecimal in DecimalFormat
[ https://issues.apache.org/jira/browse/TAP5-540?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12678974#action_12678974 ] Howard M. Lewis Ship commented on TAP5-540: --- I'm struggling with generating a proper number of right-of-the-decimal digits. It looks like Java's default numberformatter uses three digits of precision. For BigDecimal, we should have infinite digits ... but then we're back to use toString() to parse. > Allow exact parsing of numeric client input by creating a BigDecimal > Translator and enabling parseBigDecimal in DecimalFormat > - > > Key: TAP5-540 > URL: https://issues.apache.org/jira/browse/TAP5-540 > Project: Tapestry 5 > Issue Type: Improvement > Components: tapestry-core >Affects Versions: 5.1.0.1 >Reporter: Paudi Moriarty >Assignee: Howard M. Lewis Ship > > The current NumericTranslator is great but it is not easy to build on it > since the classes are internal. > Tapestry should provide a BigDecimal Translator which uses the infrastructure > created for TAP5-211 but parses client input directly to BigDecimal retaining > the full precision of that input. > For example, I need a client input of 100.00 to be translated to a BigDecimal > with value 100.00. Contributing a NumericTranslator results in a > BigDecimal with value 100 because the input is parsed to a long by the > NumberFormat before being type coerced. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Assigned: (TAP5-540) Allow exact parsing of numeric client input by creating a BigDecimal Translator and enabling parseBigDecimal in DecimalFormat
[ https://issues.apache.org/jira/browse/TAP5-540?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship reassigned TAP5-540: - Assignee: Howard M. Lewis Ship > Allow exact parsing of numeric client input by creating a BigDecimal > Translator and enabling parseBigDecimal in DecimalFormat > - > > Key: TAP5-540 > URL: https://issues.apache.org/jira/browse/TAP5-540 > Project: Tapestry 5 > Issue Type: Improvement > Components: tapestry-core >Affects Versions: 5.1.0.1 >Reporter: Paudi Moriarty >Assignee: Howard M. Lewis Ship > > The current NumericTranslator is great but it is not easy to build on it > since the classes are internal. > Tapestry should provide a BigDecimal Translator which uses the infrastructure > created for TAP5-211 but parses client input directly to BigDecimal retaining > the full precision of that input. > For example, I need a client input of 100.00 to be translated to a BigDecimal > with value 100.00. Contributing a NumericTranslator results in a > BigDecimal with value 100 because the input is parsed to a long by the > NumberFormat before being type coerced. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Commented: (TAP5-508) Same reporting behaviour between unchecked and checked Exceptions
[ https://issues.apache.org/jira/browse/TAP5-508?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12678910#action_12678910 ] Howard M. Lewis Ship commented on TAP5-508: --- Filtering out the duplicate exceptions is intentional, otherwise the exception report page gets overwhelmingly cluttered with redundant data. > Same reporting behaviour between unchecked and checked Exceptions > - > > Key: TAP5-508 > URL: https://issues.apache.org/jira/browse/TAP5-508 > Project: Tapestry 5 > Issue Type: Bug > Components: tapestry-core >Affects Versions: 5.0.18 >Reporter: manuel aldana >Priority: Trivial > Fix For: 5.1 > > Attachments: TAP509.patch, uncheckedExceptionTypeNotPrinted.png, > uncheckExceptionSwallowedIfChainingUsed.png > > > Unchecked exceptions are reported differently on Exception reporting page. > This should be changed, because many applications have convention to use an > unchecked exception hierachy. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Commented: (TAP5-508) Same reporting behaviour between unchecked and checked Exceptions
[ https://issues.apache.org/jira/browse/TAP5-508?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12678911#action_12678911 ] Howard M. Lewis Ship commented on TAP5-508: --- Perhaps I could change presentation of "duplicate" exceptions to work like the new approach to stack frames: initially hidden (but still present), revealed via a checkbox. > Same reporting behaviour between unchecked and checked Exceptions > - > > Key: TAP5-508 > URL: https://issues.apache.org/jira/browse/TAP5-508 > Project: Tapestry 5 > Issue Type: Bug > Components: tapestry-core >Affects Versions: 5.0.18 >Reporter: manuel aldana >Priority: Trivial > Fix For: 5.1 > > Attachments: TAP509.patch, uncheckedExceptionTypeNotPrinted.png, > uncheckExceptionSwallowedIfChainingUsed.png > > > Unchecked exceptions are reported differently on Exception reporting page. > This should be changed, because many applications have convention to use an > unchecked exception hierachy. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Closed: (TAP5-517) Link from Type coercion guide page to TypeCoercer Service is broken
[ https://issues.apache.org/jira/browse/TAP5-517?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship closed TAP5-517. - Resolution: Cannot Reproduce This appears to have been fixed at some point in 5.1. > Link from Type coercion guide page to TypeCoercer Service is broken > --- > > Key: TAP5-517 > URL: https://issues.apache.org/jira/browse/TAP5-517 > Project: Tapestry 5 > Issue Type: Bug > Components: documentation >Affects Versions: 5.0.18 >Reporter: Borut Bolcina >Assignee: Kevin Menard >Priority: Trivial > > At http://tapestry.apache.org/tapestry5/guide/coercion.html a link > http://tapestry.apache.org/tapestry-ioc/coerce.html (documented here) should > be http://tapestry.apache.org/tapestry5/tapestry-ioc/coerce.html. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Closed: (TAP5-267) BeanDisplay formatting can be off in IE7 with short values
[ https://issues.apache.org/jira/browse/TAP5-267?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship closed TAP5-267. - Resolution: Duplicate Assignee: Howard M. Lewis Ship Please reopen if you can see this behavior with the lastest 5.1 snapshot. > BeanDisplay formatting can be off in IE7 with short values > -- > > Key: TAP5-267 > URL: https://issues.apache.org/jira/browse/TAP5-267 > Project: Tapestry 5 > Issue Type: Bug >Reporter: Geoff Callender >Assignee: Howard M. Lewis Ship >Priority: Minor > > I'm seeing strange formatting of BeanDisplay by IE7. An example is the "Id" > line of this page, in which the dd element value is 1: > http://202.177.217.122:8080/jumpstart/examples/output/easy > I'm guessing IE7 has formatting issues with the dt/dd elements. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Commented: (TAP5-518) MarkupWriter.write() writes to deleted nodes
[ https://issues.apache.org/jira/browse/TAP5-518?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12678904#action_12678904 ] Howard M. Lewis Ship commented on TAP5-518: --- The DOM modifiying methods were intended to operate after the MarkupWriter, not in concert with it. Still a bug, but pretty minor. > MarkupWriter.write() writes to deleted nodes > > > Key: TAP5-518 > URL: https://issues.apache.org/jira/browse/TAP5-518 > Project: Tapestry 5 > Issue Type: Bug > Components: tapestry-core >Affects Versions: 5.0.16 > Environment: tested on Tapestry versions 5.0.18, 5.0.17 (could not > select in list for this issue) > Windows Vista Service Pack 1, Eclipse 3.4.1 Build M20080911-1700, Run Jetty > Run Plugin 1.0.1 >Reporter: Daniel Beck >Priority: Minor > > Description > When removing a child text node from the current element, subsequent write()s > ware still written to the removed node. > Reproduce: > public void test(MarkupWriter writer) { > writer.element("a"); > writer.write("foo"); > writer.getElement().removeChildren(); > writer.write("bar"); > writer.end(); > } > Expected Result: > bar > Actual Result: > (5.0.18) > (5.0.17) > Notes > MarkupWriter.write() is documented as: "Writes the text as a child of the > current element" (5.0.17), suggesting that if there is no child text node, a > new one is created. > MarkupWriterImpl (in 5.0.17) holds a reference to the text node, but does not > verify the node is still a child of the current node when write()ing to it. > Workaround: Create a child or other element which is basically ignored > when rendering, but modifying the document might not work for everyone. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Commented: (TAP5-520) Using regular expressions with the @Validate annotation causes odd parse errors if the regexp includes common characters (including commas)
[ https://issues.apache.org/jira/browse/TAP5-520?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12678903#action_12678903 ] Howard M. Lewis Ship commented on TAP5-520: --- I'd like to see this closed as "invalid" or "won't fix" ... but that's up to Igor as he's taken ownership. > Using regular expressions with the @Validate annotation causes odd parse > errors if the regexp includes common characters (including commas) > --- > > Key: TAP5-520 > URL: https://issues.apache.org/jira/browse/TAP5-520 > Project: Tapestry 5 > Issue Type: Bug > Components: tapestry-core >Affects Versions: 5.0.18 >Reporter: Konstantin Miklevskiy >Assignee: Igor Drobiazko >Priority: Minor > > Try adding this field to your form: > @Validate("regexp=^([a-zA-Z0-9]{2,4})+$") > private String somefield; > Page will fail to render with exception saying: > Render queue error in BeginRender[mypage.somefield]: Failure reading > parameter 'validate' of component mypage.somefield: Coercion of > ^([a-zA-Z0-9]{2 to type java.util.regex.Pattern (via String --> > java.util.regex.Pattern) failed: Unclosed counted closure near index 15 > ^([a-zA-Z0-9]{2 ^ -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Closed: (TAP5-389) Linksubmit doesn't work inside a form with Zone parameter set
[ https://issues.apache.org/jira/browse/TAP5-389?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship closed TAP5-389. - Resolution: Cannot Reproduce Cannot reproduce this in 5.1.0.1; I have added specific tests for this scenario. > Linksubmit doesn't work inside a form with Zone parameter set > - > > Key: TAP5-389 > URL: https://issues.apache.org/jira/browse/TAP5-389 > Project: Tapestry 5 > Issue Type: Bug > Components: tapestry-core >Affects Versions: 5.0.17 >Reporter: Henry Chen >Assignee: Howard M. Lewis Ship > > When LinkSubmit is placed inside a form with Zone parameter, the following > part of linksubmit.js will not do the right thing. > if (onsubmit == undefined || onsubmit.call(window.document, event)) > { > this.createHidden(); > this.form.submit(); > } > createHidden() is not called so no hidden field is thus inserted. > Removing 'zone' parameter from Form component fixed this immediately. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
svn commit: r750139 - in /tapestry/tapestry5/trunk/tapestry-core/src/test: app1/ java/org/apache/tapestry5/integration/ java/org/apache/tapestry5/integration/app1/pages/
Author: hlship Date: Wed Mar 4 20:22:44 2009 New Revision: 750139 URL: http://svn.apache.org/viewvc?rev=750139&view=rev Log: TAP5-389: Linksubmit doesn't work inside a form with Zone parameter set Added: tapestry/tapestry5/trunk/tapestry-core/src/test/app1/LinkSubmitInZoneDemo.tml tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/integration/app1/pages/LinkSubmitInZoneDemo.java Modified: tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/integration/IntegrationTests.java tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/integration/app1/pages/Index.java Added: tapestry/tapestry5/trunk/tapestry-core/src/test/app1/LinkSubmitInZoneDemo.tml URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/test/app1/LinkSubmitInZoneDemo.tml?rev=750139&view=auto == --- tapestry/tapestry5/trunk/tapestry-core/src/test/app1/LinkSubmitInZoneDemo.tml (added) +++ tapestry/tapestry5/trunk/tapestry-core/src/test/app1/LinkSubmitInZoneDemo.tml Wed Mar 4 20:22:44 2009 @@ -0,0 +1,27 @@ +http://tapestry.apache.org/schema/tapestry_5_0_0.xsd"; + xmlns:p="tapestry:parameter"> + +LinkSubmit inside Zone + +Current time: +${now} + + + + + +You entered +${value} + + + + + + + + + +submit + + + \ No newline at end of file Modified: tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/integration/IntegrationTests.java URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/integration/IntegrationTests.java?rev=750139&r1=750138&r2=750139&view=diff == --- tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/integration/IntegrationTests.java (original) +++ tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/integration/IntegrationTests.java Wed Mar 4 20:22:44 2009 @@ -2762,4 +2762,29 @@ assertText("zoneOutput", "Updated via form submission."); } + +/** + * TAP5-389 + */ +public void link_submit_inside_form_that_updates_a_zone() +{ +start("LinkSubmit inside Zone"); + +String now = getText("now"); + +click("link=submit"); + +waitForElementToAppear("value:errorpopup"); + +type("value", "robot chicken"); + +click("link=submit"); + +waitForElementToAppear("outputvalue"); + +assertText("outputvalue", "robot chicken"); + +// Make sure it was a partial update +assertText("now", now); +} } \ No newline at end of file Modified: tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/integration/app1/pages/Index.java URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/integration/app1/pages/Index.java?rev=750139&r1=750138&r2=750139&view=diff == --- tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/integration/app1/pages/Index.java (original) +++ tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/integration/app1/pages/Index.java Wed Mar 4 20:22:44 2009 @@ -65,6 +65,9 @@ private static final List ITEMS = CollectionFactory.newList( +new Item("LinkSubmitInZoneDemo", "LinkSubmit inside Zone", + "Ensure that a LinkSubmit works correctly when its containing Form updates a Zone"), + new Item("SlowAjaxDemo", "Slow Ajax Demo", "Handling of client-side Ajax before the page is fully loaded"), new Item("ProgressiveDemo", "ProgressiveDisplay Demo", "Progressive Enhancement via a component"), Added: tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/integration/app1/pages/LinkSubmitInZoneDemo.java URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/integration/app1/pages/LinkSubmitInZoneDemo.java?rev=750139&view=auto == --- tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/integration/app1/pages/LinkSubmitInZoneDemo.java (added) +++ tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/integration/app1/pages/LinkSubmitInZoneDemo.java Wed Mar 4 20:22:44 2009 @@ -0,0 +1,42 @@ +// Copyright 2009 The Apache Software Foundation +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2
[jira] Created: (TAP5-553) Tapestry should include a new binding prefix, "clientId:", that extracts the clientId of a component
Tapestry should include a new binding prefix, "clientId:", that extracts the clientId of a component Key: TAP5-553 URL: https://issues.apache.org/jira/browse/TAP5-553 Project: Tapestry 5 Issue Type: New Feature Components: tapestry-core Affects Versions: 5.1.0.1 Reporter: Howard M. Lewis Ship It is quite frequently desirable to get a component (that implements ClientElement) and extract the component's clientId property. Currently you have to inject the component into the page to expose it as a property to extract the clientId. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Closed: (TAP5-552) Common compressed image files should be configured to not re-compress when sent to client: GIF, PNG
[ https://issues.apache.org/jira/browse/TAP5-552?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship closed TAP5-552. - Resolution: Fixed Fix Version/s: 5.1.0.1 > Common compressed image files should be configured to not re-compress when > sent to client: GIF, PNG > --- > > Key: TAP5-552 > URL: https://issues.apache.org/jira/browse/TAP5-552 > Project: Tapestry 5 > Issue Type: Bug > Components: tapestry-core >Affects Versions: 5.1.0.0 >Reporter: Howard M. Lewis Ship >Assignee: Howard M. Lewis Ship > Fix For: 5.1.0.1 > > > Tapestry's gzip compression logic should know not to try and compress GIF and > PNG files are already compressed and should not be re-compressed. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
svn commit: r750124 - in /tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5: corelib/components/AjaxFormLoop.java internal/services/ResourceStreamer.java services/TapestryModul
Author: hlship Date: Wed Mar 4 19:49:31 2009 New Revision: 750124 URL: http://svn.apache.org/viewvc?rev=750124&view=rev Log: TAP5-552: Common compressed image files should be configured to not re-compress when sent to client: GIF, PNG Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/corelib/components/AjaxFormLoop.java tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/ResourceStreamer.java tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/TapestryModule.java Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/corelib/components/AjaxFormLoop.java URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/corelib/components/AjaxFormLoop.java?rev=750124&r1=750123&r2=750124&view=diff == --- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/corelib/components/AjaxFormLoop.java (original) +++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/corelib/components/AjaxFormLoop.java Wed Mar 4 19:49:31 2009 @@ -32,10 +32,14 @@ /** * A special form of the {...@link org.apache.tapestry5.corelib.components.Loop} component that adds Ajax support to * handle adding new rows and removing existing rows dynamically. Expects that the values being iterated over are - * entities that can be identified via a {...@link org.apache.tapestry5.PrimaryKeyEncoder}. + * entities that can be identified via a {...@link org.apache.tapestry5.ValueEncoder}. * * Works with {...@link org.apache.tapestry5.corelib.components.AddRowLink} and {...@link * org.apache.tapestry5.corelib.components.RemoveRowLink} components. + * + * The addRow event will receive the context specified by the context parameter. + * + * The removeRow event will receive the client-side value for the row being iterated. * * @see org.apache.tapestry5.EventConstants#ADD_ROW * @see org.apache.tapestry5.EventConstants#REMOVE_ROW Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/ResourceStreamer.java URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/ResourceStreamer.java?rev=750124&r1=750123&r2=750124&view=diff == --- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/ResourceStreamer.java (original) +++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/ResourceStreamer.java Wed Mar 4 19:49:31 2009 @@ -23,7 +23,10 @@ * Responsible for streaming the contents of a resource to the client. The {...@link org.apache.tapestry5.ioc.Resource} to * stream is almost always a {...@link org.apache.tapestry5.ioc.internal.util.ClasspathResource}. * - * The service's configuration is used to map file extensions to content types. + * The service's configuration is used to map file extensions to content types. Note: this only works for simple + * extensions (i.e., "jpg") not for complex extensions (i.e., "tar.gz"). + * + * @since 5.1.0.0 */ @UsesMappedConfiguration(String.class) public interface ResourceStreamer @@ -39,7 +42,6 @@ * @param resource to analyze * @return content type * @throws IOException - * @since 5.1.0.0 */ String getContentType(Resource resource) throws IOException; } Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/TapestryModule.java URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/TapestryModule.java?rev=750124&r1=750123&r2=750124&view=diff == --- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/TapestryModule.java (original) +++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/services/TapestryModule.java Wed Mar 4 19:49:31 2009 @@ -2022,13 +2022,19 @@ /** - * Adds content types for "css" and "js" file extensions. css text/css js - * text/javascript + * Adds content types: css text/css js text/javascript jpg, jpeg + * image/jpeg gif image/gif png image/png + * + * */ public void contributeResourceStreamer(MappedConfiguration configuration) { configuration.add("css", "text/css"); configuration.add("js", "text/javascript"); +configuration.add("gif", "image/gif"); +configuration.add("jpg", "image/jpeg"); +configuration.add("jpeg", "image/jpeg"); +configuration.add("png", "image/png"); } /** @@ -2234,13 +2240,1
[jira] Commented: (TAP5-552) Common compressed image files should be configured to not re-compress when sent to client: GIF, PNG
[ https://issues.apache.org/jira/browse/TAP5-552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12678878#action_12678878 ] Thiago H. de Paula Figueiredo commented on TAP5-552: What about JPG? Isn't it compressed enough? > Common compressed image files should be configured to not re-compress when > sent to client: GIF, PNG > --- > > Key: TAP5-552 > URL: https://issues.apache.org/jira/browse/TAP5-552 > Project: Tapestry 5 > Issue Type: Bug > Components: tapestry-core >Affects Versions: 5.1.0.0 >Reporter: Howard M. Lewis Ship >Assignee: Howard M. Lewis Ship > > Tapestry's gzip compression logic should know not to try and compress GIF and > PNG files are already compressed and should not be re-compressed. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Updated: (TAP5-552) Common compressed image files should be configured to not re-compress when sent to client: GIF, PNG
[ https://issues.apache.org/jira/browse/TAP5-552?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship updated TAP5-552: -- Summary: Common compressed image files should be configured to not re-compress when sent to client: GIF, PNG (was: Common compressed image files should be configured to not compress: GIF, PNG) > Common compressed image files should be configured to not re-compress when > sent to client: GIF, PNG > --- > > Key: TAP5-552 > URL: https://issues.apache.org/jira/browse/TAP5-552 > Project: Tapestry 5 > Issue Type: Bug > Components: tapestry-core >Affects Versions: 5.1.0.0 >Reporter: Howard M. Lewis Ship >Assignee: Howard M. Lewis Ship > > Tapestry's gzip compression logic should know not to try and compress GIF and > PNG files are already compressed and should not be re-compressed. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Assigned: (TAP5-552) Common compressed image files should be configured to not compress: GIF, PNG
[ https://issues.apache.org/jira/browse/TAP5-552?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship reassigned TAP5-552: - Assignee: Howard M. Lewis Ship > Common compressed image files should be configured to not compress: GIF, PNG > > > Key: TAP5-552 > URL: https://issues.apache.org/jira/browse/TAP5-552 > Project: Tapestry 5 > Issue Type: Bug > Components: tapestry-core >Affects Versions: 5.1.0.0 >Reporter: Howard M. Lewis Ship >Assignee: Howard M. Lewis Ship > > Tapestry's gzip compression logic should know not to try and compress GIF and > PNG files are already compressed and should not be re-compressed. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Created: (TAP5-552) Common compressed image files should be configured to not compress: GIF, PNG
Common compressed image files should be configured to not compress: GIF, PNG Key: TAP5-552 URL: https://issues.apache.org/jira/browse/TAP5-552 Project: Tapestry 5 Issue Type: Bug Components: tapestry-core Affects Versions: 5.1.0.0 Reporter: Howard M. Lewis Ship Tapestry's gzip compression logic should know not to try and compress GIF and PNG files are already compressed and should not be re-compressed. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Closed: (TAP5-410) FormFragment validates non-displayed fragments
[ https://issues.apache.org/jira/browse/TAP5-410?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship closed TAP5-410. - Resolution: Invalid Please re-test with the 5.1 snapshot and re-open if the behavior is still broken. You should see the new "please wait for page to load" message instead of the incorrect behavior. > FormFragment validates non-displayed fragments > -- > > Key: TAP5-410 > URL: https://issues.apache.org/jira/browse/TAP5-410 > Project: Tapestry 5 > Issue Type: Bug > Components: tapestry-core >Affects Versions: 5.0.17, 5.0.18 >Reporter: Geoff Callender > > A user of JumpStart pointed this out in the wizard that uses FormFragments > http://jumpstart.doublenegative.com.au:8080/jumpstart/examples/wizard/usingformfragments > In this wizard each step is a separate FormFragment. The sequence to make it > fail in IE 7 is: in step 1 enter a value and press Next, in step 2 (which is > a different fragment) press Prev without entering a value, in step 1 press > Next. Kaboom! The validation error that is displayed belongs to step 2, not > step 1. > This works fine in Safari 3.2.1 and Firefox 3.0.4 but not in IE 7.0.5730.13. > [This statement is not true - see later comments]. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Assigned: (TAP5-389) Linksubmit doesn't work inside a form with Zone parameter set
[ https://issues.apache.org/jira/browse/TAP5-389?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship reassigned TAP5-389: - Assignee: Howard M. Lewis Ship > Linksubmit doesn't work inside a form with Zone parameter set > - > > Key: TAP5-389 > URL: https://issues.apache.org/jira/browse/TAP5-389 > Project: Tapestry 5 > Issue Type: Bug > Components: tapestry-core >Affects Versions: 5.0.17 >Reporter: Henry Chen >Assignee: Howard M. Lewis Ship > > When LinkSubmit is placed inside a form with Zone parameter, the following > part of linksubmit.js will not do the right thing. > if (onsubmit == undefined || onsubmit.call(window.document, event)) > { > this.createHidden(); > this.form.submit(); > } > createHidden() is not called so no hidden field is thus inserted. > Removing 'zone' parameter from Form component fixed this immediately. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Closed: (TAP5-421) AjaxFormLoop event methods with context parameters are not called
[ https://issues.apache.org/jira/browse/TAP5-421?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship closed TAP5-421. - Resolution: Cannot Reproduce I can see that this code change in July 2008 to address this need; it works, there are specific tests to ensure that the AjaxFormLoop context parameter is propogated to the addRow event handler method. > AjaxFormLoop event methods with context parameters are not called > - > > Key: TAP5-421 > URL: https://issues.apache.org/jira/browse/TAP5-421 > Project: Tapestry 5 > Issue Type: Bug > Components: tapestry-core >Affects Versions: 5.0.17 >Reporter: Toby >Assignee: Howard M. Lewis Ship > > An AjaxFormLoop "onAddRow" is called, even if a context parameter is not set: > public ValueHolder onAddRow() { > } > is called here: > t:encoder="encoder"> > ... > But when a context parameter is passed: > t:encoder="encoder" t:context="category"> > ... > public ValueHolder onAddRow(Category category) { > } > is not called. > This prevents for example adding rows that depend on another selction (e.g. > what kind of field). > In this case a Value rows which is selectable using a dropdown box - but the > values to be displayed in this dropdown box should depend on the category > that was selected when "add row" is pressed. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Commented: (TAP5-421) AjaxFormLoop event methods with context parameters are not called
[ https://issues.apache.org/jira/browse/TAP5-421?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12678849#action_12678849 ] Howard M. Lewis Ship commented on TAP5-421: --- I can see partly what's happening; there just so much context! I think the context parameter will only apply to the addRow event. > AjaxFormLoop event methods with context parameters are not called > - > > Key: TAP5-421 > URL: https://issues.apache.org/jira/browse/TAP5-421 > Project: Tapestry 5 > Issue Type: Bug > Components: tapestry-core >Affects Versions: 5.0.17 >Reporter: Toby >Assignee: Howard M. Lewis Ship > > An AjaxFormLoop "onAddRow" is called, even if a context parameter is not set: > public ValueHolder onAddRow() { > } > is called here: > t:encoder="encoder"> > ... > But when a context parameter is passed: > t:encoder="encoder" t:context="category"> > ... > public ValueHolder onAddRow(Category category) { > } > is not called. > This prevents for example adding rows that depend on another selction (e.g. > what kind of field). > In this case a Value rows which is selectable using a dropdown box - but the > values to be displayed in this dropdown box should depend on the category > that was selected when "add row" is pressed. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Assigned: (TAP5-421) AjaxFormLoop event methods with context parameters are not called
[ https://issues.apache.org/jira/browse/TAP5-421?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship reassigned TAP5-421: - Assignee: Howard M. Lewis Ship > AjaxFormLoop event methods with context parameters are not called > - > > Key: TAP5-421 > URL: https://issues.apache.org/jira/browse/TAP5-421 > Project: Tapestry 5 > Issue Type: Bug > Components: tapestry-core >Affects Versions: 5.0.17 >Reporter: Toby >Assignee: Howard M. Lewis Ship > > An AjaxFormLoop "onAddRow" is called, even if a context parameter is not set: > public ValueHolder onAddRow() { > } > is called here: > t:encoder="encoder"> > ... > But when a context parameter is passed: > t:encoder="encoder" t:context="category"> > ... > public ValueHolder onAddRow(Category category) { > } > is not called. > This prevents for example adding rows that depend on another selction (e.g. > what kind of field). > In this case a Value rows which is selectable using a dropdown box - but the > values to be displayed in this dropdown box should depend on the category > that was selected when "add row" is pressed. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Commented: (TAP5-511) I have a form in a zone that refers to that zone to refresh content. When there are 3 or less form elements, the form is submitted as an ajax request. When I add a fourth
[ https://issues.apache.org/jira/browse/TAP5-511?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12678840#action_12678840 ] Fernando commented on TAP5-511: --- I'm from the same company, and I just saw this behavior on another page.. :( I'll try to get more information, but it's really hard to debug.. it looks like it's being initialized properly.. but it keeps submitting without ajax.. very weird :( not sure where it gets confused. maybe we have some javascript that is breaking zone support.. (but weird that it's only for forms with more than two fields.. I believe someone else in our team brought up an issue that some form submit was being fired, but the event object was null for some reason ( firefox maybe ), so when you tried to do a event.cancel(), it threw and exception and normal zone handling would break.. i can't remember the bug. > I have a form in a zone that refers to that zone to refresh content. When > there are 3 or less form elements, the form is submitted as an ajax request. > When I add a fourth element (textarea, textfield, radio, hidden), the form > submits as a non-ajax request > --- > > Key: TAP5-511 > URL: https://issues.apache.org/jira/browse/TAP5-511 > Project: Tapestry 5 > Issue Type: Bug > Components: tapestry-core >Affects Versions: 5.1.0.0 >Reporter: Mike Taylor > > I have a form in a zone that refers to that zone to refresh content. When > there are 3 or less form elements, the form is submitted as an ajax request > and updates the referred zone. When I add a fourth element (textarea, > textfield, radio, hidden -- does not matter what type), the form submits as a > non-ajax request and refreshes the entire page, not just the zone. I've tried > all sorts of combinations, and it all hinges upon the number of elements in > the form -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Closed: (TAP5-502) Improve the description of parameter passing and binding in the documentation
[ https://issues.apache.org/jira/browse/TAP5-502?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship closed TAP5-502. - Resolution: Fixed Fix Version/s: 5.1.0.1 > Improve the description of parameter passing and binding in the documentation > - > > Key: TAP5-502 > URL: https://issues.apache.org/jira/browse/TAP5-502 > Project: Tapestry 5 > Issue Type: Improvement > Components: documentation >Affects Versions: 5.0.18 >Reporter: Francois Armand >Assignee: Howard M. Lewis Ship >Priority: Minor > Fix For: 5.1.0.1 > > > It seem that the documentation for parameter is milseading. > The way parameter are defined and passed between a parent component and its > child use to be really well explained (I think it was in the "Parameter" > page, but I'm not sure). It seems that the introduction text which use to > deal with the concept is no more in the Parameter documentation, what leads > to really big miscomprehension from user. > It would be really great to add again something about that at the beginning > of the parameter page (before the loop example). > That is the text in the T5 refcard on that topic, which seems quite good: > === > A page binds the parameters of its child components. For example, a TextField > properties > component's value parameter is bound to a property, or property expression, > indicating what object property it will > read (when rendering) or update (when the containing form is submitted). > === > And there used to be something about parameter being a conduit, both read and > write, between a component and it's container that was quite nice too. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
svn commit: r750100 - /tapestry/tapestry5/trunk/src/site/apt/guide/parameters.apt
Author: hlship Date: Wed Mar 4 18:56:42 2009 New Revision: 750100 URL: http://svn.apache.org/viewvc?rev=750100&view=rev Log: TAP5-502: Improve the description of parameter passing and binding in the documentation Modified: tapestry/tapestry5/trunk/src/site/apt/guide/parameters.apt Modified: tapestry/tapestry5/trunk/src/site/apt/guide/parameters.apt URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/src/site/apt/guide/parameters.apt?rev=750100&r1=750099&r2=750100&view=diff == --- tapestry/tapestry5/trunk/src/site/apt/guide/parameters.apt (original) +++ tapestry/tapestry5/trunk/src/site/apt/guide/parameters.apt Wed Mar 4 18:56:42 2009 @@ -14,7 +14,20 @@ Parameters are defined by placing a {{{../apidocs/org/apache/tapestry5/annotations/Parameter.html}Parameter}} annotation onto a private field. - + + In Tapestry, a parameter is not a slot into which data is pushed: it is a between + a field of the component (marked with the @Parameter annotation) and a property or resource + of the component's container. In most simple examples, the container is the page, but since components + can have themselves have templates, sometime the container of a component is another component. + + The connection is called a . The binding is two-way: the component can read the bound property + by reading its parameter field. Likewise, a component that updates its parameter field will update + the bound property. + + This is important in a lot of cases; for example a TextField component can read the property + bound to its value parameter. It reads the value when rendering, but updates the value when + the form is submitted. + The component listed below is a looping component; it renders its body a number of times, defined by its start and end parameters (which set the boundaries of the loop). The component can update a value parameter bound to a property of its container, @@ -138,8 +151,16 @@ | var| Allows a render variable of the component to be read or updated. | *+--+ + + Most of these binding prefixes allow parameters to be bound to read-only values; for instance + a parameter bound to "message:some-key" will see the message for "some-key" from its container's + message catalog in the field. If the component tries to update the parameter (by setting the value + of the field), a runtime exception will be thrown to indicate that the value is read-only. + + Only prop: and var: binding prefixes are updateable. + Parameters have a default prefix, usually "prop:", that is used when the prefix is not provided. - + A , "inherit:", is used to support {{{#Inherited Parameter Bindings}Inherted Parameter Bindings}}. Render Variables @@ -252,8 +273,8 @@ --- Tapestry will adjust the URL of the image so that it is processed by Tapestry, not the servlet container. - It will gain a URL that includes the applications version number, it will have a far-future expires header, - and (if the client supports it) it will be compressed before being sent to the client. + It will gain a URL that includes the application's version number, it will have a far-future expires header, + and (if the client supports it) its content will be compressed before being sent to the client. Supporting Informal Parameters @@ -500,7 +521,7 @@ In Tapestry 5.1, you may use the publishParameters attribute of the {{{../../apidocs/org/apache/tapestry5/annotations/Component.html}Component}}} annotation. List one or more parameters seperated by commas: those parameters of the inner/embedded component become - parameters of the outer component. You should not define a parameter field in the outer component. + parameters of the outer component. You should <> define a parameter field in the outer component. There are still cases where you want to use the "inherit:" binding prefix. For example, if you have several components that need to share a parameter, then you must do it the Tapestry 5.0 way: a true parameter
[jira] Updated: (TAP5-502) Improve the description of parameter passing and binding in the documentation
[ https://issues.apache.org/jira/browse/TAP5-502?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship updated TAP5-502: -- Priority: Minor (was: Major) Issue Type: Improvement (was: Bug) Summary: Improve the description of parameter passing and binding in the documentation (was: Parameter passing between components is not well explain) > Improve the description of parameter passing and binding in the documentation > - > > Key: TAP5-502 > URL: https://issues.apache.org/jira/browse/TAP5-502 > Project: Tapestry 5 > Issue Type: Improvement > Components: documentation >Affects Versions: 5.0.18 >Reporter: Francois Armand >Assignee: Howard M. Lewis Ship >Priority: Minor > > It seem that the documentation for parameter is milseading. > The way parameter are defined and passed between a parent component and its > child use to be really well explained (I think it was in the "Parameter" > page, but I'm not sure). It seems that the introduction text which use to > deal with the concept is no more in the Parameter documentation, what leads > to really big miscomprehension from user. > It would be really great to add again something about that at the beginning > of the parameter page (before the loop example). > That is the text in the T5 refcard on that topic, which seems quite good: > === > A page binds the parameters of its child components. For example, a TextField > properties > component's value parameter is bound to a property, or property expression, > indicating what object property it will > read (when rendering) or update (when the containing form is submitted). > === > And there used to be something about parameter being a conduit, both read and > write, between a component and it's container that was quite nice too. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Assigned: (TAP5-502) Parameter passing between components is not well explain
[ https://issues.apache.org/jira/browse/TAP5-502?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship reassigned TAP5-502: - Assignee: Howard M. Lewis Ship > Parameter passing between components is not well explain > > > Key: TAP5-502 > URL: https://issues.apache.org/jira/browse/TAP5-502 > Project: Tapestry 5 > Issue Type: Bug > Components: documentation >Affects Versions: 5.0.18 >Reporter: Francois Armand >Assignee: Howard M. Lewis Ship > > It seem that the documentation for parameter is milseading. > The way parameter are defined and passed between a parent component and its > child use to be really well explained (I think it was in the "Parameter" > page, but I'm not sure). It seems that the introduction text which use to > deal with the concept is no more in the Parameter documentation, what leads > to really big miscomprehension from user. > It would be really great to add again something about that at the beginning > of the parameter page (before the loop example). > That is the text in the T5 refcard on that topic, which seems quite good: > === > A page binds the parameters of its child components. For example, a TextField > properties > component's value parameter is bound to a property, or property expression, > indicating what object property it will > read (when rendering) or update (when the containing form is submitted). > === > And there used to be something about parameter being a conduit, both read and > write, between a component and it's container that was quite nice too. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Closed: (TAP5-511) I have a form in a zone that refers to that zone to refresh content. When there are 3 or less form elements, the form is submitted as an ajax request. When I add a fourth ele
[ https://issues.apache.org/jira/browse/TAP5-511?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship closed TAP5-511. - Resolution: Cannot Reproduce Please provide a real test case; Tapestry's test suite includes forms with fewer than and more than 3 fields that update zones so I have nothing to go on here. > I have a form in a zone that refers to that zone to refresh content. When > there are 3 or less form elements, the form is submitted as an ajax request. > When I add a fourth element (textarea, textfield, radio, hidden), the form > submits as a non-ajax request > --- > > Key: TAP5-511 > URL: https://issues.apache.org/jira/browse/TAP5-511 > Project: Tapestry 5 > Issue Type: Bug > Components: tapestry-core >Affects Versions: 5.1.0.0 >Reporter: Mike Taylor > > I have a form in a zone that refers to that zone to refresh content. When > there are 3 or less form elements, the form is submitted as an ajax request > and updates the referred zone. When I add a fourth element (textarea, > textfield, radio, hidden -- does not matter what type), the form submits as a > non-ajax request and refreshes the entire page, not just the zone. I've tried > all sorts of combinations, and it all hinges upon the number of elements in > the form -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Closed: (TAP5-541) Regression: Parameter namespacePrefix was null
[ https://issues.apache.org/jira/browse/TAP5-541?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship closed TAP5-541. - Resolution: Cannot Reproduce I created standalone pages and couldn't see this behavior; Tapestry's built in test suite already uses the xmlns="http://www.w3.org/1999/xhtml"; namespace so this gets tested all the time. I'm not sure what it is that triggered your issue. Perhaps a complete page rather than a snippet? > Regression: Parameter namespacePrefix was null > -- > > Key: TAP5-541 > URL: https://issues.apache.org/jira/browse/TAP5-541 > Project: Tapestry 5 > Issue Type: Bug > Components: tapestry-core >Affects Versions: 5.1 > Environment: Windows XP 5.1,x86, Java HotSpot(TM) Client VM > 1.5.0_15-b04,Sun Microsystems Inc., JBoss 4.2.3 >Reporter: Andrej Aschenbrenner >Assignee: Howard M. Lewis Ship > > I get an exception after switching to the new Tapestry 5.1.0.0 Version. > Relevant Template snippet: > http://www.w3.org/1999/xhtml"; > xmlns:t="http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";> > > > ${title} > > href="${asset:context:css/global.css}"/> > href="${asset:context:css/standard/style.css}"/> > > ... > Exception StackTrace snippet: > 16:18:38,581 ERROR [Login] Render queue error in > CompositeRenderCommand[Start[http://www.w3.org/1999/xhtml html], > DefineNamespace[null http://www.w3.org/1999/xhtml], Text[ > ], Start[http://www.w3.org/1999/xhtml head], Text[ > ], Start[http://www.w3.org/1999/xhtml meta], AttributeNS[ http-equiv > "Content-Type"], AttributeNS[ content "text/html; charset=UTF-8"], End, Text[ > ], Start[http://www.w3.org/1999/xhtml title]]: Parameter namespacePrefix > was null. > java.lang.IllegalArgumentException: Parameter namespacePrefix was null. > at > org.apache.tapestry5.ioc.internal.util.Defense.notNull(Defense.java:37) > at org.apache.tapestry5.dom.Element.defineNamespace(Element.java:519) > at > org.apache.tapestry5.internal.services.MarkupWriterImpl.defineNamespace(MarkupWriterImpl.java:221) > at > org.apache.tapestry5.internal.pageload.PageLoaderImpl$4.render(PageLoaderImpl.java:341) > at > org.apache.tapestry5.internal.pageload.CompositeRenderCommand.render(CompositeRenderCommand.java:68) > at > org.apache.tapestry5.internal.services.RenderQueueImpl.run(RenderQueueImpl.java:74) > at > org.apache.tapestry5.internal.services.PageRenderQueueImpl.render(PageRenderQueueImpl.java:121) > at > $PageRenderQueue_11fb85075e4.render($PageRenderQueue_11fb85075e4.java) > at > $PageRenderQueue_11fb85075db.render($PageRenderQueue_11fb85075db.java) > at > org.apache.tapestry5.internal.services.MarkupRendererTerminator.renderMarkup(MarkupRendererTerminator.java:37) > ... > For me it seems that Tapestry requires a namespace declaration on the > tag. But I have already the default namespace declaration on > the http://www.w3.org/1999/xhtml";> tag. > P.S. with only xmlns:t="http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";> it fails > also. But it did work on Tapestry 5.0.18 > Thanks, > Andrej Aschenbrenner -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Assigned: (TAP5-541) Regression: Parameter namespacePrefix was null
[ https://issues.apache.org/jira/browse/TAP5-541?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship reassigned TAP5-541: - Assignee: Howard M. Lewis Ship > Regression: Parameter namespacePrefix was null > -- > > Key: TAP5-541 > URL: https://issues.apache.org/jira/browse/TAP5-541 > Project: Tapestry 5 > Issue Type: Bug > Components: tapestry-core >Affects Versions: 5.1 > Environment: Windows XP 5.1,x86, Java HotSpot(TM) Client VM > 1.5.0_15-b04,Sun Microsystems Inc., JBoss 4.2.3 >Reporter: Andrej Aschenbrenner >Assignee: Howard M. Lewis Ship > > I get an exception after switching to the new Tapestry 5.1.0.0 Version. > Relevant Template snippet: > http://www.w3.org/1999/xhtml"; > xmlns:t="http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";> > > > ${title} > > href="${asset:context:css/global.css}"/> > href="${asset:context:css/standard/style.css}"/> > > ... > Exception StackTrace snippet: > 16:18:38,581 ERROR [Login] Render queue error in > CompositeRenderCommand[Start[http://www.w3.org/1999/xhtml html], > DefineNamespace[null http://www.w3.org/1999/xhtml], Text[ > ], Start[http://www.w3.org/1999/xhtml head], Text[ > ], Start[http://www.w3.org/1999/xhtml meta], AttributeNS[ http-equiv > "Content-Type"], AttributeNS[ content "text/html; charset=UTF-8"], End, Text[ > ], Start[http://www.w3.org/1999/xhtml title]]: Parameter namespacePrefix > was null. > java.lang.IllegalArgumentException: Parameter namespacePrefix was null. > at > org.apache.tapestry5.ioc.internal.util.Defense.notNull(Defense.java:37) > at org.apache.tapestry5.dom.Element.defineNamespace(Element.java:519) > at > org.apache.tapestry5.internal.services.MarkupWriterImpl.defineNamespace(MarkupWriterImpl.java:221) > at > org.apache.tapestry5.internal.pageload.PageLoaderImpl$4.render(PageLoaderImpl.java:341) > at > org.apache.tapestry5.internal.pageload.CompositeRenderCommand.render(CompositeRenderCommand.java:68) > at > org.apache.tapestry5.internal.services.RenderQueueImpl.run(RenderQueueImpl.java:74) > at > org.apache.tapestry5.internal.services.PageRenderQueueImpl.render(PageRenderQueueImpl.java:121) > at > $PageRenderQueue_11fb85075e4.render($PageRenderQueue_11fb85075e4.java) > at > $PageRenderQueue_11fb85075db.render($PageRenderQueue_11fb85075db.java) > at > org.apache.tapestry5.internal.services.MarkupRendererTerminator.renderMarkup(MarkupRendererTerminator.java:37) > ... > For me it seems that Tapestry requires a namespace declaration on the > tag. But I have already the default namespace declaration on > the http://www.w3.org/1999/xhtml";> tag. > P.S. with only xmlns:t="http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";> it fails > also. But it did work on Tapestry 5.0.18 > Thanks, > Andrej Aschenbrenner -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Closed: (TAP5-84) Change proxy generation to use volatile fields rather than synchronized blocks
[ https://issues.apache.org/jira/browse/TAP5-84?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship closed TAP5-84. Resolution: Fixed Fix Version/s: 5.1.0.1 > Change proxy generation to use volatile fields rather than synchronized blocks > -- > > Key: TAP5-84 > URL: https://issues.apache.org/jira/browse/TAP5-84 > Project: Tapestry 5 > Issue Type: Improvement >Affects Versions: 5.0.15 >Reporter: Howard M. Lewis Ship >Assignee: Howard M. Lewis Ship >Priority: Minor > Fix For: 5.1.0.1 > > > As currently coded, the service proxies used for Tapestry services use a > synchronized block to a) check to see if the Registry has shut down and b) > obtain (if needed) the realized service implementation (wrapped by > interceptors, etc.). > It seems that with some juggling, these could largely be replaced with > AtomicBoolean and AtomicReferences. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
svn commit: r750087 - in /tapestry/tapestry5/trunk/tapestry-ioc/src: main/java/org/apache/tapestry5/ioc/internal/services/ test/java/org/apache/tapestry5/ioc/ test/java/org/apache/tapestry5/ioc/intern
Author: hlship Date: Wed Mar 4 17:33:25 2009 New Revision: 750087 URL: http://svn.apache.org/viewvc?rev=750087&view=rev Log: TAP5-84: Change proxy generation to use volatile fields rather than synchronized blocks Modified: tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/internal/services/JustInTimeObjectCreator.java tapestry/tapestry5/trunk/tapestry-ioc/src/test/java/org/apache/tapestry5/ioc/IntegrationTest.java tapestry/tapestry5/trunk/tapestry-ioc/src/test/java/org/apache/tapestry5/ioc/internal/services/JustInTimeObjectCreatorTest.java Modified: tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/internal/services/JustInTimeObjectCreator.java URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/internal/services/JustInTimeObjectCreator.java?rev=750087&r1=750086&r2=750087&view=diff == --- tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/internal/services/JustInTimeObjectCreator.java (original) +++ tapestry/tapestry5/trunk/tapestry-ioc/src/main/java/org/apache/tapestry5/ioc/internal/services/JustInTimeObjectCreator.java Wed Mar 4 17:33:25 2009 @@ -1,4 +1,4 @@ -// Copyright 2007 The Apache Software Foundation +// Copyright 2007, 2009 The Apache Software Foundation // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -31,11 +31,9 @@ { private final ServiceActivityTracker tracker; -private ObjectCreator creator; +private volatile ObjectCreator creator; -private boolean shutdown; - -private Object object; +private volatile Object object; private final String serviceId; @@ -53,30 +51,32 @@ * * @throws IllegalStateException if the registry has been shutdown */ -public synchronized Object createObject() +public Object createObject() { -if (shutdown) -throw new IllegalStateException(ServiceMessages.registryShutdown(serviceId)); - if (object == null) +obtainObjectFromCreator(); + +return object; +} + +private synchronized void obtainObjectFromCreator() +{ +if (object != null) return; + +try { -try -{ -object = creator.createObject(); +object = creator.createObject(); -// And if that's successful ... +// And if that's successful ... -tracker.setStatus(serviceId, Status.REAL); +tracker.setStatus(serviceId, Status.REAL); -creator = null; -} -catch (RuntimeException ex) -{ -throw new RuntimeException(ServiceMessages.serviceBuildFailure(serviceId, ex), ex); -} +creator = null; +} +catch (RuntimeException ex) +{ +throw new RuntimeException(ServiceMessages.serviceBuildFailure(serviceId, ex), ex); } - -return object; } /** @@ -92,11 +92,17 @@ /** * Sets the shutdown flag and releases the object and the creator. */ -public synchronized void registryDidShutdown() +public void registryDidShutdown() { -shutdown = true; +creator = new ObjectCreator() +{ +public Object createObject() +{ +throw new IllegalStateException(ServiceMessages.registryShutdown(serviceId)); +} +}; + object = null; -creator = null; } } Modified: tapestry/tapestry5/trunk/tapestry-ioc/src/test/java/org/apache/tapestry5/ioc/IntegrationTest.java URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-ioc/src/test/java/org/apache/tapestry5/ioc/IntegrationTest.java?rev=750087&r1=750086&r2=750087&view=diff == --- tapestry/tapestry5/trunk/tapestry-ioc/src/test/java/org/apache/tapestry5/ioc/IntegrationTest.java (original) +++ tapestry/tapestry5/trunk/tapestry-ioc/src/test/java/org/apache/tapestry5/ioc/IntegrationTest.java Wed Mar 4 17:33:25 2009 @@ -124,10 +124,10 @@ service.run(); unreachable(); } -catch (IllegalStateException ex) +catch (RuntimeException ex) { -assertEquals(ex.getMessage(), - "Proxy for service Fred is no longer active because the IOC Registry has been shut down."); +assertMessageContains(ex, + "Proxy for service Fred is no longer active because the IOC Registry has been shut down."); } // Show that toString() still works, even for a shutdown proxy. Modified: tapestry/tapestry5/trunk/tapestry-ioc/src/tes
[jira] Updated: (TAP5-84) Change proxy generation to use volatile fields rather than synchronized blocks
[ https://issues.apache.org/jira/browse/TAP5-84?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship updated TAP5-84: - Summary: Change proxy generation to use volatile fields rather than synchronized blocks (was: Change proxy generation to use atomic references rather than synchronized blocks) > Change proxy generation to use volatile fields rather than synchronized blocks > -- > > Key: TAP5-84 > URL: https://issues.apache.org/jira/browse/TAP5-84 > Project: Tapestry 5 > Issue Type: Improvement >Affects Versions: 5.0.15 >Reporter: Howard M. Lewis Ship >Assignee: Howard M. Lewis Ship >Priority: Minor > > As currently coded, the service proxies used for Tapestry services use a > synchronized block to a) check to see if the Registry has shut down and b) > obtain (if needed) the realized service implementation (wrapped by > interceptors, etc.). > It seems that with some juggling, these could largely be replaced with > AtomicBoolean and AtomicReferences. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Commented: (TAP5-84) Change proxy generation to use atomic references rather than synchronized blocks
[ https://issues.apache.org/jira/browse/TAP5-84?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12678801#action_12678801 ] Howard M. Lewis Ship commented on TAP5-84: -- After a brief look, using simple volatile fields seems to be the way to go, with a double-check (which is ok for volatile fields). I also found a way to eliminate the need for a volatile shutdown flag, sort of merging that back into the ObjectCreator. Still its hard to tell if there's a performance difference especially under JDK 1.6. Supposedly uncontested synchronized locks are super cheap in JDK 1.6 and volatiles are always more expensive than normal field access. > Change proxy generation to use atomic references rather than synchronized > blocks > > > Key: TAP5-84 > URL: https://issues.apache.org/jira/browse/TAP5-84 > Project: Tapestry 5 > Issue Type: Improvement >Affects Versions: 5.0.15 >Reporter: Howard M. Lewis Ship >Assignee: Howard M. Lewis Ship >Priority: Minor > > As currently coded, the service proxies used for Tapestry services use a > synchronized block to a) check to see if the Registry has shut down and b) > obtain (if needed) the realized service implementation (wrapped by > interceptors, etc.). > It seems that with some juggling, these could largely be replaced with > AtomicBoolean and AtomicReferences. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Assigned: (TAP5-84) Change proxy generation to use atomic references rather than synchronized blocks
[ https://issues.apache.org/jira/browse/TAP5-84?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship reassigned TAP5-84: Assignee: Howard M. Lewis Ship > Change proxy generation to use atomic references rather than synchronized > blocks > > > Key: TAP5-84 > URL: https://issues.apache.org/jira/browse/TAP5-84 > Project: Tapestry 5 > Issue Type: Improvement >Affects Versions: 5.0.15 >Reporter: Howard M. Lewis Ship >Assignee: Howard M. Lewis Ship >Priority: Minor > > As currently coded, the service proxies used for Tapestry services use a > synchronized block to a) check to see if the Registry has shut down and b) > obtain (if needed) the realized service implementation (wrapped by > interceptors, etc.). > It seems that with some juggling, these could largely be replaced with > AtomicBoolean and AtomicReferences. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Created: (TAP5-551) Glassfish V2.1 is unable to load correct woodstox stax implemention
Glassfish V2.1 is unable to load correct woodstox stax implemention --- Key: TAP5-551 URL: https://issues.apache.org/jira/browse/TAP5-551 Project: Tapestry 5 Issue Type: Bug Components: tapestry-core Affects Versions: 5.1.0.0 Reporter: Thilo Tanner Glassfish throws the following error while loading a template file: [ERROR] InternalModule.TemplateParser Construction of service TemplateParser failed Error invoking constructor org.apache.tapestry5.internal.services.TemplateParserImpl(Map, boolean) (at TemplateParserImpl.java:50) via org.apache.tapestry5.internal.services.InternalModule.bind(ServiceBinder) (at InternalModule.java:65) (for service 'TemplateParser'): com.sun.xml.stream.ZephyrParserFactory cannot be cast to org.codehaus.stax2.XMLInputFactory2 ... Workaround: Add the system property below to Application Server > JVM Settings > JVM Options and restart Glassfish -Djavax.xml.stream.XMLInputFactory=com.ctc.wstx.stax.WstxInputFactory -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
[jira] Closed: (TAP5-78) Portlet(JSR-168) Support
[ https://issues.apache.org/jira/browse/TAP5-78?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship closed TAP5-78. Resolution: Duplicate > Portlet(JSR-168) Support > > > Key: TAP5-78 > URL: https://issues.apache.org/jira/browse/TAP5-78 > Project: Tapestry 5 > Issue Type: New Feature >Affects Versions: 5.0.15 >Reporter: Michael Lake > Attachments: tapestry-portlet-contribution-code.zip > > -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.