[jira] Created: (TAP5-1444) Index pages in subfolders should have precedence over start pages
Index pages in subfolders should have precedence over start pages - Key: TAP5-1444 URL: https://issues.apache.org/jira/browse/TAP5-1444 Project: Tapestry 5 Issue Type: Bug Components: tapestry-core Affects Versions: 5.2.4 Reporter: Ulrich Stärk Priority: Minor When there is both, an index and a start page in a subpackage, the index page shold have precedence over the start page since those are deprecated. Later, support for start pages in subpackages should be removed. -- This message is automatically generated by JIRA. - For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Assigned: (TAP5-1444) Index pages in subfolders should have precedence over start pages
[ https://issues.apache.org/jira/browse/TAP5-1444?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Ulrich Stärk reassigned TAP5-1444: -- Assignee: Ulrich Stärk Index pages in subfolders should have precedence over start pages - Key: TAP5-1444 URL: https://issues.apache.org/jira/browse/TAP5-1444 Project: Tapestry 5 Issue Type: Bug Components: tapestry-core Affects Versions: 5.2.4 Reporter: Ulrich Stärk Assignee: Ulrich Stärk Priority: Minor When there is both, an index and a start page in a subpackage, the index page shold have precedence over the start page since those are deprecated. Later, support for start pages in subpackages should be removed. -- This message is automatically generated by JIRA. - For more information on JIRA, see: http://www.atlassian.com/software/jira
svn commit: r1071170 - in /tapestry/tapestry5/trunk/tapestry-core/src: main/java/org/apache/tapestry5/internal/services/ComponentClassResolverImpl.java test/java/org/apache/tapestry5/internal/services
Author: uli Date: Wed Feb 16 08:33:24 2011 New Revision: 1071170 URL: http://svn.apache.org/viewvc?rev=1071170view=rev Log: TAP5-1444: Index pages in subfolders should have precedence over start pages Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/ComponentClassResolverImpl.java tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/internal/services/ComponentClassResolverImplTest.java Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/ComponentClassResolverImpl.java URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/ComponentClassResolverImpl.java?rev=1071170r1=1071169r2=1071170view=diff == --- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/ComponentClassResolverImpl.java (original) +++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/internal/services/ComponentClassResolverImpl.java Wed Feb 16 08:33:24 2011 @@ -322,9 +322,13 @@ public class ComponentClassResolverImpl String reducedName = lastSlashx 0 ? : logicalName.substring(0, lastSlashx); // Make the super-stripped name another alias to the class. - -logicalNameToClassName.put(reducedName, name); -pageNameToCanonicalPageName.put(reducedName, logicalName); +// TAP5-1444: Everything else but a start page has precedence + +if (!(lastTerm.equalsIgnoreCase(startPageName) logicalNameToClassName.containsKey(reducedName))) +{ +logicalNameToClassName.put(reducedName, name); +pageNameToCanonicalPageName.put(reducedName, logicalName); +} } pageClassNameToLogicalName.put(name, logicalName); Modified: tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/internal/services/ComponentClassResolverImplTest.java URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/internal/services/ComponentClassResolverImplTest.java?rev=1071170r1=1071169r2=1071170view=diff == --- tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/internal/services/ComponentClassResolverImplTest.java (original) +++ tapestry/tapestry5/trunk/tapestry-core/src/test/java/org/apache/tapestry5/internal/services/ComponentClassResolverImplTest.java Wed Feb 16 08:33:24 2011 @@ -183,6 +183,66 @@ public class ComponentClassResolverImplT verify(); } + +@Test +public void start_page_in_subfolder() +{ +ComponentInstantiatorSource source = mockComponentInstantiatorSource(); +ClassNameLocator locator = newClassNameLocator(); +Logger logger = compliantLogger(); + +train_for_app_packages(source); + +String className = APP_ROOT_PACKAGE + .pages.sub.HomePage; + +train_locateComponentClassNames(locator, APP_ROOT_PACKAGE + .pages, className); + +replay(); + +ListLibraryMapping mappings = Arrays.asList(); + +ComponentClassResolver resolver = new ComponentClassResolverImpl(logger, source, locator, APP_ROOT_PACKAGE, +HomePage, mappings); + +assertEquals(resolver.canonicalizePageName(sub/HomePage), sub/HomePage); +assertEquals(resolver.canonicalizePageName(sub), sub/HomePage); +assertTrue(resolver.isPageName(sub/HomePage)); + +verify(); +} + +/** + * TAP5-1444 + */ +@Test +public void index_page_precedence() +{ +ComponentInstantiatorSource source = mockComponentInstantiatorSource(); +ClassNameLocator locator = newClassNameLocator(); +Logger logger = compliantLogger(); + +train_for_app_packages(source); + +String[] classNames = { APP_ROOT_PACKAGE + .pages.sub.HomePage, APP_ROOT_PACKAGE + .pages.sub.SubIndex }; + +train_locateComponentClassNames(locator, APP_ROOT_PACKAGE + .pages, classNames); + +replay(); + +ListLibraryMapping mappings = Arrays.asList(); + +ComponentClassResolver resolver = new ComponentClassResolverImpl(logger, source, locator, APP_ROOT_PACKAGE, +HomePage, mappings); + +assertTrue(resolver.isPageName(sub/HomePage)); +assertTrue(resolver.isPageName(sub/subIndex)); +assertEquals(resolver.resolvePageNameToClassName(sub/HomePage), APP_ROOT_PACKAGE + .pages.sub.HomePage); +assertEquals(resolver.resolvePageNameToClassName(sub/SubIndex), APP_ROOT_PACKAGE + .pages.sub.SubIndex); +
svn commit: r1071177 - /tapestry/tapestry5/branches/maint-5-2/tapestry-jmx/
Author: uli Date: Wed Feb 16 08:59:28 2011 New Revision: 1071177 URL: http://svn.apache.org/viewvc?rev=1071177view=rev Log: add eclipse files to svn:ignore Modified: tapestry/tapestry5/branches/maint-5-2/tapestry-jmx/ (props changed) Propchange: tapestry/tapestry5/branches/maint-5-2/tapestry-jmx/ -- --- svn:ignore (original) +++ svn:ignore Wed Feb 16 08:59:28 2011 @@ -1,7 +1,4 @@ - - - - .project - target +.classpath +.settings
svn commit: r1071178 - /tapestry/tapestry5/trunk/tapestry-jmx/
Author: uli Date: Wed Feb 16 09:00:52 2011 New Revision: 1071178 URL: http://svn.apache.org/viewvc?rev=1071178view=rev Log: add eclipse files to svn:ignore Modified: tapestry/tapestry5/trunk/tapestry-jmx/ (props changed) Propchange: tapestry/tapestry5/trunk/tapestry-jmx/ -- --- svn:ignore (original) +++ svn:ignore Wed Feb 16 09:00:52 2011 @@ -1,7 +1,4 @@ - - - - .project - target +.settings +.classpath
[jira] Closed: (TAP5-1444) Index pages in subfolders should have precedence over start pages
[ https://issues.apache.org/jira/browse/TAP5-1444?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Ulrich Stärk closed TAP5-1444. -- Resolution: Fixed Fix Version/s: 5.3.0 Index pages in subfolders should have precedence over start pages - Key: TAP5-1444 URL: https://issues.apache.org/jira/browse/TAP5-1444 Project: Tapestry 5 Issue Type: Bug Components: tapestry-core Affects Versions: 5.2.4 Reporter: Ulrich Stärk Assignee: Ulrich Stärk Priority: Minor Fix For: 5.3.0 When there is both, an index and a start page in a subpackage, the index page shold have precedence over the start page since those are deprecated. Later, support for start pages in subpackages should be removed. -- This message is automatically generated by JIRA. - For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (TAP5-1444) Index pages in subfolders should have precedence over start pages
[ https://issues.apache.org/jira/browse/TAP5-1444?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=12995231#comment-12995231 ] Hudson commented on TAP5-1444: -- Integrated in tapestry-5.2-freestyle #266 (See [https://hudson.apache.org/hudson/job/tapestry-5.2-freestyle/266/]) TAP5-1444: Index pages in subfolders should have precedence over start pages Index pages in subfolders should have precedence over start pages - Key: TAP5-1444 URL: https://issues.apache.org/jira/browse/TAP5-1444 Project: Tapestry 5 Issue Type: Bug Components: tapestry-core Affects Versions: 5.2.4 Reporter: Ulrich Stärk Assignee: Ulrich Stärk Priority: Minor Fix For: 5.3.0 When there is both, an index and a start page in a subpackage, the index page shold have precedence over the start page since those are deprecated. Later, support for start pages in subpackages should be removed. -- This message is automatically generated by JIRA. - For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (TAP5-1208) In development mode, Tapestry should shadow field parameter values to instance variables, to assist with debugging
[ https://issues.apache.org/jira/browse/TAP5-1208?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=12995232#comment-12995232 ] Hudson commented on TAP5-1208: -- Integrated in tapestry-5.2-freestyle #266 (See [https://hudson.apache.org/hudson/job/tapestry-5.2-freestyle/266/]) In development mode, Tapestry should shadow field parameter values to instance variables, to assist with debugging -- Key: TAP5-1208 URL: https://issues.apache.org/jira/browse/TAP5-1208 Project: Tapestry 5 Issue Type: Improvement Components: tapestry-core Affects Versions: 5.3, 5.2 Reporter: Mike M Pestorich Assignee: Howard M. Lewis Ship Since Tapestry 5.2 and the end of page pooling, all mutable field state (unclaimed fields, parameter fields, persisted fields, etc.) have their values stored in an external, per-thread HashMap, which allows page instances (along with components within pages) to be shared across threads. However, when debugging, all those fields are still present but have null (or default) values. When in development mode, it would be great if reading or writing to the fields would shadow the value into the field, as well as do the other updates (moving the content to or from the HashMap, etc.). This would be pointless in production mode (the instance fields would be constantly overwritten by multiple threads) and possibly introduce memory leaks (as temporary objects would be referenced from the fields). However, quite reasonable to do this for development mode. Improvement related to May 2010 thread: [T5] debugging in eclipse http://mail-archives.apache.org/mod_mbox/tapestry-users/201005.mbox/%3caanlktinofxesmaloyxzr-osd4uzwtdc_qt1j4igzg...@mail.gmail.com%3E As noted in the thread, values can only be seen when debugging by inspecting the related conduit due to the class transformation that takes place behind the scenes. Actually, in my experience, this used to be the case but now with the most recent snapshots I can't even do that. Later on in the thread a suggestion is made to modify UncaimedFieldWorker. http://mail-archives.apache.org/mod_mbox/tapestry-users/201005.mbox/%3caanlktimtatlkszbyntum2pwn70kiwnnwlwjr4gmwl...@mail.gmail.com%3E I don't know if this is correct or not but I would think that this would be a useful improvement over the way things currently work. -- This message is automatically generated by JIRA. - For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Created: (TAP5-1445) Add clientId parameter to the Zone component
Add clientId parameter to the Zone component Key: TAP5-1445 URL: https://issues.apache.org/jira/browse/TAP5-1445 Project: Tapestry 5 Issue Type: Improvement Components: tapestry-core Affects Versions: 5.2.4 Reporter: Denis Stepanov Priority: Minor It will solve dynamic zone id problem, when clientId is null it will use the previous approach. Now we are forced to have a copy of the zone component with a similar solution. Also, it would be nice if a generated id is available before rendering, in a case when someone calls getClient on a zone before it have been rendered. -- This message is automatically generated by JIRA. - For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Created: (TAP5-1446) Improve coercion Collection, Map - SelectModel
Improve coercion Collection, Map - SelectModel --- Key: TAP5-1446 URL: https://issues.apache.org/jira/browse/TAP5-1446 Project: Tapestry 5 Issue Type: Improvement Components: tapestry-core Affects Versions: 5.2.4 Reporter: Denis Stepanov It should use SelectModelFactory with default property label?. If there is no such property it should have current toString value. There is probably a bug in SelectModelFactoryImpl: options.add(new OptionModelImpl(encoder.toClient(label), object)); toClient should be called with object -- This message is automatically generated by JIRA. - For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Closed: (TAP5-1445) Add clientId parameter to the Zone component
[ https://issues.apache.org/jira/browse/TAP5-1445?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Howard M. Lewis Ship closed TAP5-1445. -- Resolution: Invalid Assignee: Howard M. Lewis Ship Please check the component reference; Zone already has an id parameter. Add clientId parameter to the Zone component Key: TAP5-1445 URL: https://issues.apache.org/jira/browse/TAP5-1445 Project: Tapestry 5 Issue Type: Improvement Components: tapestry-core Affects Versions: 5.2.4 Reporter: Denis Stepanov Assignee: Howard M. Lewis Ship Priority: Minor It will solve dynamic zone id problem, when clientId is null it will use the previous approach. Now we are forced to have a copy of the zone component with a similar solution. Also, it would be nice if a generated id is available before rendering, in a case when someone calls getClient on a zone before it have been rendered. -- This message is automatically generated by JIRA. - For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Reopened: (TAP5-1445) Add clientId parameter to the Zone component
[ https://issues.apache.org/jira/browse/TAP5-1445?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Denis Stepanov reopened TAP5-1445: -- yes, but you can't have a dynamic id - t:id=user_${user.id} Add clientId parameter to the Zone component Key: TAP5-1445 URL: https://issues.apache.org/jira/browse/TAP5-1445 Project: Tapestry 5 Issue Type: Improvement Components: tapestry-core Affects Versions: 5.2.4 Reporter: Denis Stepanov Assignee: Howard M. Lewis Ship Priority: Minor It will solve dynamic zone id problem, when clientId is null it will use the previous approach. Now we are forced to have a copy of the zone component with a similar solution. Also, it would be nice if a generated id is available before rendering, in a case when someone calls getClient on a zone before it have been rendered. -- This message is automatically generated by JIRA. - For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (TAP5-1445) Add clientId parameter to the Zone component
[ https://issues.apache.org/jira/browse/TAP5-1445?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=12995327#comment-12995327 ] Igor Drobiazko commented on TAP5-1445: -- Denis, please read the component reference for Zone. There is a parameter called id. Add clientId parameter to the Zone component Key: TAP5-1445 URL: https://issues.apache.org/jira/browse/TAP5-1445 Project: Tapestry 5 Issue Type: Improvement Components: tapestry-core Affects Versions: 5.2.4 Reporter: Denis Stepanov Assignee: Howard M. Lewis Ship Priority: Minor It will solve dynamic zone id problem, when clientId is null it will use the previous approach. Now we are forced to have a copy of the zone component with a similar solution. Also, it would be nice if a generated id is available before rendering, in a case when someone calls getClient on a zone before it have been rendered. -- This message is automatically generated by JIRA. - For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (TAP5-1445) Add clientId parameter to the Zone component
[ https://issues.apache.org/jira/browse/TAP5-1445?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=12995335#comment-12995335 ] Denis Stepanov commented on TAP5-1445: -- Guys, I know that there is a parameter id, it is also used for defining component id so it can't be dynamic like myZone_${inLoopItem.id}, you know that right? Because of that there are issues like TAP5-255 Solution: Make clientId a parameter: @Parameter(defaultPrefix = BindingConstants.LITERAL) private String clientId; and correct setup render: clientId = clientId != null ? clientId : resources.isBound(id) ? idParameter : javascriptSupport.allocateClientId(resources); Add clientId parameter to the Zone component Key: TAP5-1445 URL: https://issues.apache.org/jira/browse/TAP5-1445 Project: Tapestry 5 Issue Type: Improvement Components: tapestry-core Affects Versions: 5.2.4 Reporter: Denis Stepanov Assignee: Howard M. Lewis Ship Priority: Minor It will solve dynamic zone id problem, when clientId is null it will use the previous approach. Now we are forced to have a copy of the zone component with a similar solution. Also, it would be nice if a generated id is available before rendering, in a case when someone calls getClient on a zone before it have been rendered. -- This message is automatically generated by JIRA. - For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Created: (TAP5-1447) ProgressiveDisplay could accept forcing client id property
ProgressiveDisplay could accept forcing client id property -- Key: TAP5-1447 URL: https://issues.apache.org/jira/browse/TAP5-1447 Project: Tapestry 5 Issue Type: Improvement Components: tapestry-core Affects Versions: 5.2.4 Reporter: Raul Montes Priority: Minor ProgressiveDisplay component could have similar behaviour to Zone component about forcing the id attribute. So, instead of setting clientId like: String clientId = jsSupport.allocateClientId(resources); It could be like Zone does: clientId = resources.isBound(id) ? idParameter : javascriptSupport.allocateClientId(resources); Since ProgressiveDisplay also creates a containing div (or other element) in the final markup, it is useful when you need to have related CSS or JS code. -- This message is automatically generated by JIRA. - For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (TAP5-1445) Add clientId parameter to the Zone component
[ https://issues.apache.org/jira/browse/TAP5-1445?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=12995384#comment-12995384 ] Josh Canfield commented on TAP5-1445: - As Howard said, this can be accomplished today. You are confusing t:id with the parameter id, which is understandable. The parameter id does what you want. This example code works today: TML *** t:loop source=1..5 value=zoneId p t:zone t:id=myZone id=hello_${zoneId} Hello! ${zoneId} ${now} /t:zone t:eventlink event=refresh t:context=zoneId t:zone=hello_${zoneId}Refresh/t:eventlink /p /t:loop PAGE @Property private Integer zoneId; @Component(id = myZone) private Zone zone; public Block onRefresh(Integer zoneId) { this.zoneId = zoneId; return zone.getBody(); } public String getNow() { return new Date().toString(); } *** GENERATED HTML *** pdiv class=t-zone id=hello_1 Hello! 1 Wed Feb 16 08:48:35 PST 2011 /div a id=eventlink onclick=javascript:return Tapestry.waitForPage(event); href=/test:refresh/1Refresh/a /p pdiv class=t-zone id=hello_2 Hello! 2 Wed Feb 16 08:48:35 PST 2011 /diva id=eventlink_0 onclick=javascript:return Tapestry.waitForPage(event); href=/test:refresh/2Refresh/a /p pdiv class=t-zone id=hello_3 Hello! 3 Wed Feb 16 08:48:35 PST 2011 /diva id=eventlink_1 onclick=javascript:return Tapestry.waitForPage(event); href=/test:refresh/3Refresh/a /p pdiv class=t-zone id=hello_4 Hello! 4 Wed Feb 16 08:48:35 PST 2011 /diva id=eventlink_2 onclick=javascript:return Tapestry.waitForPage(event); href=/test:refresh/4Refresh/a /p pdiv class=t-zone id=hello_5 Hello! 5 Wed Feb 16 08:48:35 PST 2011 /diva id=eventlink_3 onclick=javascript:return Tapestry.waitForPage(event); href=/test:refresh/5Refresh/a /p Add clientId parameter to the Zone component Key: TAP5-1445 URL: https://issues.apache.org/jira/browse/TAP5-1445 Project: Tapestry 5 Issue Type: Improvement Components: tapestry-core Affects Versions: 5.2.4 Reporter: Denis Stepanov Assignee: Howard M. Lewis Ship Priority: Minor It will solve dynamic zone id problem, when clientId is null it will use the previous approach. Now we are forced to have a copy of the zone component with a similar solution. Also, it would be nice if a generated id is available before rendering, in a case when someone calls getClient on a zone before it have been rendered. -- This message is automatically generated by JIRA. - For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Closed: (TAP5-1445) Add clientId parameter to the Zone component
[ https://issues.apache.org/jira/browse/TAP5-1445?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Josh Canfield closed TAP5-1445. --- Resolution: Invalid Assignee: (was: Howard M. Lewis Ship) Add clientId parameter to the Zone component Key: TAP5-1445 URL: https://issues.apache.org/jira/browse/TAP5-1445 Project: Tapestry 5 Issue Type: Improvement Components: tapestry-core Affects Versions: 5.2.4 Reporter: Denis Stepanov Priority: Minor It will solve dynamic zone id problem, when clientId is null it will use the previous approach. Now we are forced to have a copy of the zone component with a similar solution. Also, it would be nice if a generated id is available before rendering, in a case when someone calls getClient on a zone before it have been rendered. -- This message is automatically generated by JIRA. - For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (TAP5-1445) Add clientId parameter to the Zone component
[ https://issues.apache.org/jira/browse/TAP5-1445?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=12995397#comment-12995397 ] Denis Stepanov commented on TAP5-1445: -- Thanks, I forgot about it Add clientId parameter to the Zone component Key: TAP5-1445 URL: https://issues.apache.org/jira/browse/TAP5-1445 Project: Tapestry 5 Issue Type: Improvement Components: tapestry-core Affects Versions: 5.2.4 Reporter: Denis Stepanov Priority: Minor It will solve dynamic zone id problem, when clientId is null it will use the previous approach. Now we are forced to have a copy of the zone component with a similar solution. Also, it would be nice if a generated id is available before rendering, in a case when someone calls getClient on a zone before it have been rendered. -- This message is automatically generated by JIRA. - For more information on JIRA, see: http://www.atlassian.com/software/jira