Re: [NOOB] Getting the Locale without injection
Hi, which Tapestry version are you referring to? And what exactly do you mean with in a final object - are you talking about a component? In what way is the final part relevant? In Tapestry 4.0.x, the BasePage provides getLocale() and getMessages() methods. But I guess that's not what you are looking for? Lutz On 8/16/07, Marcelo C. de Freitas [EMAIL PROTECTED] wrote: Hello there, I want to get the page locale (and the page messages) in a final object without having to set them manually (meaning I can't do the @InjectObject stuff). Is there a way I can do that? I've looked for it into the Hivemind docs but I couldn't find anything really useful. -- Marcelo C. Freitas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Class cast exception in ASTChain, Bug OGNL-11
Kevin Menard wrote: On 8/15/07 10:50 AM, in article [EMAIL PROTECTED], Andrus Adamchik [EMAIL PROTECTED] wrote: Thinking about it some more This is not the end of the world for our application. We can either skip the upgrade or indeed force an interface on the objects involved, or avoid multi-step property traversal by moving it to Java class. But at a higher level it seems like the expression compilation algorithm is sacrificing correctness for performance. An implicit requirement on the @For to have homogeneous objects in the loop is confusing and non-obvious. A failover strategy hidden from the users would be great. How hard it would be to say decorate an expression compiled within a For loop in a try/catch that would switch to a generic algorithm on the first ClassCastException? This is an interesting idea that I think would work well. We ran into problems ourselves. OGNL would dump out a ton of output to the console, but then fallback to an expression that would work. I think it would be good to allow users to turn off expression compilation, i.e. revert to the old way that OGNL worked. Is this possible? It would allow us to continue with 4.1, without having all our expressions break on us. For me it was only 2 parts of the app that needed fixing, but I can imagine loads of people relying on the reflective nature of OGNL when constructing their pages... Damien -- Damien Uern Online Applications Developer Synect Online Solutions - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Class cast exception in ASTChain, Bug OGNL-11
Exclude the version that comes with 4.1.2 and fall back to 2.6.7. But, I think it's the responsibility of us, the users, to iron out the bugs in the expressionCompiler. I mean it's the least we can do. The benefits far outweigh the current issues from my perspective and Jesse's more than willing to fix any emerging issues. Everybody wants it, but if no one but him is willing to put down some effort, it'll never be finished. Kalle On 8/16/07, Damien Uern [EMAIL PROTECTED] wrote: Kevin Menard wrote: On 8/15/07 10:50 AM, in article [EMAIL PROTECTED], Andrus Adamchik [EMAIL PROTECTED] wrote: Thinking about it some more This is not the end of the world for our application. We can either skip the upgrade or indeed force an interface on the objects involved, or avoid multi-step property traversal by moving it to Java class. But at a higher level it seems like the expression compilation algorithm is sacrificing correctness for performance. An implicit requirement on the @For to have homogeneous objects in the loop is confusing and non-obvious. A failover strategy hidden from the users would be great. How hard it would be to say decorate an expression compiled within a For loop in a try/catch that would switch to a generic algorithm on the first ClassCastException? This is an interesting idea that I think would work well. We ran into problems ourselves. OGNL would dump out a ton of output to the console, but then fallback to an expression that would work. I think it would be good to allow users to turn off expression compilation, i.e. revert to the old way that OGNL worked. Is this possible? It would allow us to continue with 4.1, without having all our expressions break on us. For me it was only 2 parts of the app that needed fixing, but I can imagine loads of people relying on the reflective nature of OGNL when constructing their pages... Damien -- Damien Uern Online Applications Developer Synect Online Solutions - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: T5: radio, label
The problem is actually in the Radio component. Copy its source to make your own component and apply these changes: https://issues.apache.org/jira/browse/TAPESTRY-1709 Cheers, Nick. Chris Lewis wrote: tamseo, Let me amend my last message. I can use t:label in the form as long as its not a child of the t:radiogroup component! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[Tapestry Beginner] Validation is ignored
Hi Everyone, i've been teaching myself tapestry for some time now, and everytime i think i am finally getting a grip on it something new comes up. OK, here's the deal... (i'll be using snippets since you guys probably don't want a million lines of code... all code i post compiles in it's context and runs without exceptions) i have to pages, Login and Register First for login: Login.html has: tr tdlabel jwcid=@FieldLabel field=component:usernameUser Name/label/td tdinput jwcid=username//td /tr Login.page has: bean name=ValidString class=myproject.Validator.ValidString / component id=username type=TextField binding name=value value=username/ binding name=validators value=validators:required,$ValidString / binding name=displayName value=message:username / /component Login.java has: public abstract String getUsername(); public abstract void setUsername(String Username); public IPage tryLogin(){ // -- gets called when the form around username is submitted //do fancy stuff } this works quite good. it checks the enteresd string in username against the self written Validator $ValidString. I can debug, breakpoint, step-though and see all the magic happening. quite cool, acctually. Now for Register Register.html trtdfirstname /tdtdinput type=text jwcid=firstname //td/tr trtdlastname /tdtdinput type=text jwcid=lastname //td/tr Register.page bean name=ValidString class=myproject.Validator.ValidString / !-- same validator as before -- !-- Form -- component id=register type=Form binding name=listener value=listener:tryUserCreate/ /component component id=submitRegister type=Submit /component !-- Attributes of a Person -- component id=firstname type=TextField binding name=value value=firstname/ binding name=validators value=validators:required,$ehfgbiasdbgujas / !-- NOTE THIS -- /component component id=lastname type=TextField binding name=value value=lastname/ binding name=validators value=validators:required,$ValidString / /component Register.java public abstract String getFirstname(); public abstract String getLastname(); public IPage tryUserCreate(){ // do more fancy stuff } now this acctually compiles and runs (!!!) without an error or expection even tho the gibberish Validator bean in firstname does not exist. This form has a lot more fields to it, and two more self written validators but this is pretty much the essence. now - the Validators here get ignored. i can write anything after the $ and it still runs through without any trouble. I can even delete the bean statement completely withouth raising an exception. required is also ignored - it jumps right into the listener without looking at the Validators. This started happening after i had to refactor the class to move it to another package. Used the NetBeans refactor (which always worked before) and suddenly it would not validate anymore. Refactoring it back does not help either. if i type somthing like this in one if the TextFields it does give me an exception upon loading the page: binding name=validators value=validators:required,fsgdsfghkjsn / Here is what i have tried: i have moved the Form around in register - even used it inline - same thing i have copied and pasted the content to a new file - same thing i have used tapestry 4.1.1, 4.1.2 and the nightly 4.1.3 - same thing i have deleted the project and reloaded it from svn - same thing i have set up NetBeans completely new - same thing i have run the application on two more machines (Windows, Debian, Ubuntu) - same thing i have run it with sun java 1.5 and 1.6 - same thing also, if i tried to use a Fieldlabel (maybe thats the error ?) and copied the username from Login to Register (it has a username too) - one to one copy - works in Login, not in Register (the Fieldlabel says no DisplayName was set in Username - which i definetly had set - and throws an expception) anybody got any idea why the validators get ignored or why Register is behaving to strange ? i really need this to work sometime soon... Hope this mail is not too cryptic, Ingmar -- View this message in context: http://www.nabble.com/-Tapestry-Beginner--Validation-is-ignored-tf4278261.html#a12177442 Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: t4.1.2 contrib tree - how to add checkboxes
ok, i've just implemented my own INodeRenderFactory and it works :) mn wrote: Hi all! What is the simplest way to add checboxes to contrib:Tree component? mn -- View this message in context: http://www.nabble.com/t4.1.2-contrib-tree---how-to-add-checkboxes-tf4276007.html#a12177819 Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[T4.1] Two beginner questions (Pageconfig / AJAX)
Hi guys, after a simple basic test application, I decided to use Tapestry now for a real-used office application. I have one small and one general bigger question, hoping you can help me. The first question is about configurating directory informations for pages. In the .application-file I can setup where to search for the .class files by default. But what is with the pages itself? I can declare each page or component seperately and his directory-path, but no default. Especially if I have my pages in /WEB-INF/pages and my components in /WEB-INF/comps, is it possible to set these paths as default? The second question is about AJAX. I have used the AJAX-concept much in PHP - JS[ with Prototype(/Behaviour)]. The tapestry-dev-page gives information how to change an Insertion-Field via AJAX. But if I want to change a complete div-component by link, that could especially a seperate tapestry-component (Like Ajax.Update() in Prototype.js). Is this possible with tapestry itself or do I need the tacos-extension? Is there an example source available how to do this or could anybody give me some initial How-To-information? Example: If a user chooses in selection-field account mmustermann, the tapestry-component accountdata should reload with all informations of mmustermann. Thanks + Regards, Michael Wölm - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: how to clear the page cach
I think it's that: http://tapestry.apache.org/tapestry4/UsersGuide/configuration.html#configuration.search-path at: org.apache.tapestry.disable-caching (set in application-name.application) robinson wang schrieb: when i click a link ,if the session is invalid ,it will return to the page of login,but when i login again, click then link ,it still return to the page of login. when i restart the server , it's ok,i think it's caught by the page in the pool,how can i clear the pooled page? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
T5: Partial Page Rendering
Hi I tried to perform a partial page refresh with tapestry5 and ajax... I used the following code piece Kris Marinkovic postet on the mailing-list a month ago... Everything works fine, except if I try to render a component, which is not surrounded by a form-tag. Then it says: org.apache.tapestry.ioc.internal.util.TapestryException: No object of type org.apache.tapestry.services.FormSupport is available from the Environment. Available types are org.apache.tapestry.MarkupWriter, org.apache.tapestry.PageRenderSupport, org.apache.tapestry.ValidationDecorator, org.apache.tapestry.dom.Document, org.apache.tapestry.internal.services.DocumentScriptBuilder, org.apache.tapestry.services.Heartbeat. The code of the component looks like that: // to retrieve page instances @Inject private RequestPageCache _cache; // returns markupwriter @Inject private MarkupWriterFactory _mwf; // sets the environment @Inject private PageRenderInitializer initializer; public Object onActionFromUpdateLink() { MarkupWriter markupWriter = _mwf.newMarkupWriter(); initializer.setup(markupWriter); Page page = _cache.get(pageName); ComponentPageElement element = page.getRootElement(); for(String id : elementId) element = element.getEmbeddedElement(id); RenderQueueImpl queue = new RenderQueueImpl(page.getLog()); queue.push(element); queue.run(markupWriter); initializer.cleanup(markupWriter); return new TextStreamResponse(text/html, markupWriter.toString()); } There has to be an easy solution to that problem, but I just dont get it... Regards, Klaus -- View this message in context: http://www.nabble.com/T5%3A-Partial-Page-Rendering-tf4278997.html#a12179365 Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[Announce] Acegi Security library for Tapestry 5
Hi, Thanks to Ivan Dubrov I've been able to put together an Acegi Security library for T5. My idea was a library similar to James Carman's tapestry-acegi for T4. Basic usage is that it works with the @Secured annotation. Currently only class level, but page listeners is planned. There are also a few components planned to make things easier, but this is merely get it out of the door release. :-). More information and example usage and application can be found here: http://www.localhost.nu/java/tapestry5-acegi/ -- regards, Robin - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [Announce] Acegi Security library for Tapestry 5
Alleluia -- View this message in context: http://www.nabble.com/-Announce--Acegi-Security-library-for-Tapestry-5-tf4279236.html#a12180260 Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: T5: a layout with varying style sheets
I agree that under normal circumstances the layout component should override styles in the embedded component, except in the cases (such as this example) where the embedded component represents a page. We /want/ the page to be able to have the ability to override styles in the general containing styles of the layout. This isn't the same situation as using some 3rd party component and needing to override those styles, but the problem is that Tapestry sees them as the same. Robert Zeigler wrote: Overall, that looks pretty good, but you could handle it easier, I think, by using the environment service. The top level document is available during render from the Environment service, so you could use that in place of steps 2 and 3. Consistent ordering would be nice... the difficult thing there is determining what ordering should be the correct ordering. If you have some way or knowing what the correct ordering ought to be, then you could certainly traverse the dom and make sure your new link element is inserted in the correct location. But the real question is knowing what the right order should be. Order of render is probably incorrect. For example, you create a layout component which inserts your application-specific stylesheets via the proposed custom style component. Your layout is embedded in a page, and as part of the layout body, there is a component which also uses the style component. Rendering order would place the style of the layout first, and the style of the embedded component second, which is probably not what you want since you might be overriding the component-default styling in your application style. (You could get around that be declaring your layout/application-specific style component after the t:body/ of your layout component, but...) You don't want to have to explicitly define an order in the style component since you don't really know what stylesheets will be available. But, again, if you can figure out what the order /ought/ to be, you should be able to enforce that order. :) Robert On Aug 13, 2007, at 8/136:08 PM , Chris Lewis wrote: So it looks like one would need to (re)create something similar to the T4 Shell component. I've taken a brief look at the DOM api, and if I were to write something as focused as a Style component, then it looks like I'd have to: 1) create my component class, either in my.namespace.components, or another module that is loaded and contributed 2) get a MarkupWriter instance via void beginRender/@BeginRender 3) use writer.getRootElement() to get the root, and then traverse into the head 4) assuming eHead is my head Element, use eHead.element(link, rel, stylesheet, type, text/css, href, TODO-css-url-here), to append a link Can anyone comment on the (in)correctness of this? It'd be nice to ensure ordering of the sheets somehow, so they can cascade properly. It'd be easier to do that with a more sophisticated Shell-link component that handled building the page base (head, metas, scripts, etc). Anyway, please share thoughts. thanks chris Robert Zeigler wrote: T5 renders with a dom. Gives you a lot of control... You could create a style component that finds the head and inserts the appropriate link element. Then your components could add their own stylesheets using the style component, with the page and containing components none the wiser. You would want to make sure that a given stylesheet is inserted only once, of course (eg, if your component is contained within a loop...). A component like this should be very straightforward to write in T5. Robert On Aug 13, 2007, at 8/134:51 PM , Chris Lewis wrote: One of the nice things I learned in my brief investigation of T4.1.2 was that the Shell component would automatically pick up any style sheets a page declared using the @Style annotation (or something like that). I've been wondering how something like this might be achieved in T5, using the available components as opposed to subclassing a base page. This seems like a feature that would be part of the core, as it is such a common need. I know I could emulate this by creating a layout that expected a page property, say externalCss (a collection), and using the Loop component to iterate it and insert the link elements. Is this the only way to do this in T5? thanks! chris - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands,
Re: T5: radio, label
Nick, thanks for pointing that out and I'm glad to see its a known issue (hopefully that means a fix is coming). Thanks for your solution, but I'd rather just use the raw label tag. I'm not entirely sure what the benefit of using the the label component is to be honest, but it was one of those thing where I felt like I had to understand what was happening (I'm new to tap). Thanks again! chris Nick Westgate wrote: The problem is actually in the Radio component. Copy its source to make your own component and apply these changes: https://issues.apache.org/jira/browse/TAPESTRY-1709 Cheers, Nick. Chris Lewis wrote: tamseo, Let me amend my last message. I can use t:label in the form as long as its not a child of the t:radiogroup component! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [NOOB] Getting the Locale without injection
Sorry about my confusion regarding final classes. I meant a object from a class that's not abstract. The thing is I'm not subclassing neither *Component nor *Page and I don't see this class working as or being constructed by a Hivemind service. I'm working with 4.1. 2007/8/16, Lutz Hühnken [EMAIL PROTECTED]: Hi, which Tapestry version are you referring to? And what exactly do you mean with in a final object - are you talking about a component? In what way is the final part relevant? In Tapestry 4.0.x, the BasePage provides getLocale() and getMessages() methods. But I guess that's not what you are looking for? Lutz On 8/16/07, Marcelo C. de Freitas [EMAIL PROTECTED] wrote: Hello there, I want to get the page locale (and the page messages) in a final object without having to set them manually (meaning I can't do the @InjectObject stuff). Is there a way I can do that? I've looked for it into the Hivemind docs but I couldn't find anything really useful. -- Marcelo C. Freitas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Marcelo C. Freitas IM's: MSN: [EMAIL PROTECTED] ICQ: 24263609 Jabber: [EMAIL PROTECTED] GTalk: [EMAIL PROTECTED] Yahoo: baterausp - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: T5: date picker component
This is something we will work on for the next release of this component. All ideas on how to dynamically generate the java script ifFormat for this (depending on the SimpleDateFormat on the server side) are welcome. oh! and also how to get the DateTranslator in the module to parse it correctly. 2007/8/16, Marcelo lotif [EMAIL PROTECTED]: i was looking for it a few days ago... just one question: it will have an easy to set translator in the future? if i want to set my own format i'll have to recompile the module ... Thanks! 2007/8/13, Ted Steen [EMAIL PROTECTED]: Hi! A new version of our date picker component is released. Compability issues with 5.0.5 is resolved. There are new features in un-commited code here, sent to me by Martin Dietze, but we want to have a closer look before we add it. http://code.google.com/p/tapestry5-jscalendar/ -- /ted - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Atenciosamente, Marcelo Lotif -- /ted - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE : Re: T5: date picker component
Hi, As I said on google bug tracker, a good idea would be to put the date format in a localizable property file. Typically, date format will depend on the user locale. But I don't know how to do this... sorry. Julien --- Ted Steen [EMAIL PROTECTED] a écrit : This is something we will work on for the next release of this component. All ideas on how to dynamically generate the java script ifFormat for this (depending on the SimpleDateFormat on the server side) are welcome. oh! and also how to get the DateTranslator in the module to parse it correctly. 2007/8/16, Marcelo lotif [EMAIL PROTECTED]: i was looking for it a few days ago... just one question: it will have an easy to set translator in the future? if i want to set my own format i'll have to recompile the module ... Thanks! 2007/8/13, Ted Steen [EMAIL PROTECTED]: Hi! A new version of our date picker component is released. Compability issues with 5.0.5 is resolved. There are new features in un-commited code here, sent to me by Martin Dietze, but we want to have a closer look before we add it. http://code.google.com/p/tapestry5-jscalendar/ -- /ted - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Atenciosamente, Marcelo Lotif -- /ted - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ Ne gardez plus qu'une seule adresse mail ! Copiez vos mails vers Yahoo! Mail - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: T5: radio, label
You're welcome. It wasn't a known issue before you found it. I just debugged and logged it. The benefits of using the label component are: - DRY: a component declares its label once, and the Label refers to it - validation decoration of the resulting label Cheers, Nick. Chris Lewis-5 wrote: Nick, thanks for pointing that out and I'm glad to see its a known issue (hopefully that means a fix is coming). Thanks for your solution, but I'd rather just use the raw label tag. I'm not entirely sure what the benefit of using the the label component is to be honest, but it was one of those thing where I felt like I had to understand what was happening (I'm new to tap). Thanks again! chris Nick Westgate wrote: The problem is actually in the Radio component. Copy its source to make your own component and apply these changes: https://issues.apache.org/jira/browse/TAPESTRY-1709 Cheers, Nick. Chris Lewis wrote: tamseo, Let me amend my last message. I can use t:label in the form as long as its not a child of the t:radiogroup component! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/T5%3A-radio%2C-label-tf4276314.html#a12183202 Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Class cast exception in ASTChain, Bug OGNL-11
I am an open source developer myself and I *love* when the users submit patches that work or at least create intelligent Jira's :-) But that's not the point here. Even though there is an OGNL-11 bug report, this is not a bug. This is a new feature of Tapestry 4.1. No matter was else was said in this thread, there is clearly a consensus between Tapestry commiters and users about what is causing it. The disagreement is what (if anything) should be done about that. So it will not help if I open another bug report saying my @For loop is broken - it will not get fixed unless we all agree that 4.0 scriptable behavior was a good thing :-) Cheers, Andrus Kalle Korhonen-2 wrote: Exclude the version that comes with 4.1.2 and fall back to 2.6.7. But, I think it's the responsibility of us, the users, to iron out the bugs in the expressionCompiler. I mean it's the least we can do. The benefits far outweigh the current issues from my perspective and Jesse's more than willing to fix any emerging issues. Everybody wants it, but if no one but him is willing to put down some effort, it'll never be finished. Kalle -- View this message in context: http://www.nabble.com/Class-cast-exception-in-ASTChain%2C-Bug-OGNL-11-tf4054151.html#a12183517 Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
T5: static page variables in templates
Hello, I'm implementing a form with some radio buttons. My understanding so far is that the radio buttons provide a value, and that value is stored in the containing RadioGroup's value parameter when the form is submitted. The form has only 2 radio buttons, each representing a string value. This string value should be a constant in the page class, but I can't figure out how to grab a constant from the page class in the template. In T4 this was done with something like: value=ognl:@com.app.MyPage.STATIC_MEMBER How can this be done in T5? thanks! chris - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: T5 developing with WTP and TOMCAT
Ok, now, I am using jettylauncher eclipse plugin to develop T5. I hope T5 can fix the problem about working with tomcat. There are many people using tomcat for develop and product. On 8/15/07, Denny deng [EMAIL PROTECTED] wrote: Hi, I develop with WTP and TOMCAT. If I set the tomcat don't auto-reload, tapestry5 can take the changes of html template, while it can't take the chages of page class. It make the hot code replace failed. However, If I enable tomcat auto-reload. tapestry can take both html template and page class changes. But, it will cause tomcat reload the context. It's very slow, and after some times, it will cause tomcat out of memory. I know using Jetty servlet container will be fine. But I like developing with eclipse WTP. So I like the way of T3, T4, just add a java system property. -Dorg.apache.tapestry.disable-caching=true. It would be fine. just a bit slow while reload the page. -- View this message in context: http://www.nabble.com/T5-developing-with-WTP-and-TOMCAT-tf4273924.html#a12164566 Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Regards Denny Site: http://dengyin2000.javaeye.com
Re: T5: static page variables in templates
T5 uses Prop, so you should be able to specify it using ${prop:STATIC_MEMBER} On 8/16/07, Chris Lewis [EMAIL PROTECTED] wrote: Hello, I'm implementing a form with some radio buttons. My understanding so far is that the radio buttons provide a value, and that value is stored in the containing RadioGroup's value parameter when the form is submitted. The form has only 2 radio buttons, each representing a string value. This string value should be a constant in the page class, but I can't figure out how to grab a constant from the page class in the template. In T4 this was done with something like: value=ognl:@com.app.MyPage.STATIC_MEMBER How can this be done in T5? thanks! chris - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [Announce] Acegi Security library for Tapestry 5
I may have two questions : - First is it normal that you choose not to use the SecurityContextHolderAwareRequestFilter ? I used this : public static void contributeHttpServletRequestHandler( OrderedConfigurationHttpServletRequestFilter configuration, WebApplicationContext webApplicationContext) { Filter securityContextHolderAwareRequestFilter = (Filter)webApplicationContext.getBean(securityContextHolderAwareRequestFilter); configuration.add(acegiSecurityContextHolderAwareRequestFilter, new HttpServletRequestFilterWrapper(securityContextHolderAwareRequestFilter), after:acegiRememberMeProcessingFilter); } - I tryied to use the loggout feature, but it seams not working : Error 404 when calling /j_acegi_logout. Should I add something somewhere ? Best regards, Martin -- View this message in context: http://www.nabble.com/-Announce--Acegi-Security-library-for-Tapestry-5-tf4279236.html#a12184379 Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: T5 developing with WTP and TOMCAT
I use Tomcat 5.5.23 and WTP for development. My context probably reloads 200-400 times a day. Only when I am making changes to web.xml/context.xml, log4j.properties, hibernate xmls do I need to stop and then start the server again. I have never run into a memory issue, although if I run modules directly from workspace the temp directory under my workspace/.metadata//server-core can get hosed sometimes. I've had more reliability running straight from the Tomcat container, with everything initialized through WTP. On 8/16/07, Denny [EMAIL PROTECTED] wrote: Ok, now, I am using jettylauncher eclipse plugin to develop T5. I hope T5 can fix the problem about working with tomcat. There are many people using tomcat for develop and product. On 8/15/07, Denny deng [EMAIL PROTECTED] wrote: Hi, I develop with WTP and TOMCAT. If I set the tomcat don't auto-reload, tapestry5 can take the changes of html template, while it can't take the chages of page class. It make the hot code replace failed. However, If I enable tomcat auto-reload. tapestry can take both html template and page class changes. But, it will cause tomcat reload the context. It's very slow, and after some times, it will cause tomcat out of memory. I know using Jetty servlet container will be fine. But I like developing with eclipse WTP. So I like the way of T3, T4, just add a java system property. -Dorg.apache.tapestry.disable-caching=true. It would be fine. just a bit slow while reload the page. -- View this message in context: http://www.nabble.com/T5-developing-with-WTP-and-TOMCAT-tf4273924.html#a12164566 Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Regards Denny Site: http://dengyin2000.javaeye.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: T5: static page variables in templates
But alas, you cannot. If I remember correctly, you're not allowed to use expansions in parameters (${}). This isn't needed for value as its expanded anyway, but the bottom line is T5 throws an exception if you do something like this: t:radio value=prop:STATIC_FIELD/ or t:radio value=${prop:STATIC_FIELD}/ or t:radio value=STATIC_FIELD/ Even if the page class has this field. It throws an exception with the message: Could not convert 'prop:AGENT_LISTER' into a component parameter binding: Class xxx.Login does not contain a property named 'AGENT_LISTER' (within property expression 'AGENT_LISTER'). Daniel Jue wrote: T5 uses Prop, so you should be able to specify it using ${prop:STATIC_MEMBER} On 8/16/07, Chris Lewis [EMAIL PROTECTED] wrote: Hello, I'm implementing a form with some radio buttons. My understanding so far is that the radio buttons provide a value, and that value is stored in the containing RadioGroup's value parameter when the form is submitted. The form has only 2 radio buttons, each representing a string value. This string value should be a constant in the page class, but I can't figure out how to grab a constant from the page class in the template. In T4 this was done with something like: value=ognl:@com.app.MyPage.STATIC_MEMBER How can this be done in T5? thanks! chris - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: T5 developing with WTP and TOMCAT
On Thu, 16 Aug 2007 12:54:31 -0300, Denny [EMAIL PROTECTED] wrote: Ok, now, I am using jettylauncher eclipse plugin to develop T5. I hope T5 can fix the problem about working with tomcat. There are many people using tomcat for develop and product. It's a Tomcat issue, not a Tapestry one. Howard explains the problem here: http://tapestryjava.blogspot.com/2007/02/fighting-with-tomcat.html -- Thiago H. de Paula Figueiredo Desenvolvedor, Instrutor e Consultor de Tecnologia Eteg Tecnologia da Informação Ltda. http://www.eteg.com.br - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: T5: static page variables in templates
I can't test this right now, but my first guess would be that you haven't implemented a getter method for the value. do you have a public String getAGENT_LISTER() method? On 8/16/07, Chris Lewis [EMAIL PROTECTED] wrote: But alas, you cannot. If I remember correctly, you're not allowed to use expansions in parameters (${}). This isn't needed for value as its expanded anyway, but the bottom line is T5 throws an exception if you do something like this: t:radio value=prop:STATIC_FIELD/ or t:radio value=${prop:STATIC_FIELD}/ or t:radio value=STATIC_FIELD/ Even if the page class has this field. It throws an exception with the message: Could not convert 'prop:AGENT_LISTER' into a component parameter binding: Class xxx.Login does not contain a property named 'AGENT_LISTER' (within property expression 'AGENT_LISTER'). Daniel Jue wrote: T5 uses Prop, so you should be able to specify it using ${prop:STATIC_MEMBER} On 8/16/07, Chris Lewis [EMAIL PROTECTED] wrote: Hello, I'm implementing a form with some radio buttons. My understanding so far is that the radio buttons provide a value, and that value is stored in the containing RadioGroup's value parameter when the form is submitted. The form has only 2 radio buttons, each representing a string value. This string value should be a constant in the page class, but I can't figure out how to grab a constant from the page class in the template. In T4 this was done with something like: value=ognl:@com.app.MyPage.STATIC_MEMBER How can this be done in T5? thanks! chris - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- -- TheDailyTube.com. Sign up and get the best new videos on the internet delivered fresh to your inbox.
Re: [Announce] Acegi Security library for Tapestry 5
Well... I made this, and now I can Login / Logout and use isUserInRole() and getUserPrincipal() methods public static void contributeHttpServletRequestHandler( OrderedConfigurationHttpServletRequestFilter configuration, WebApplicationContext webApplicationContext, @InjectService(rememberMeLogoutHandler) LogoutHandler rememberMeLogoutHandler, @Inject @Value(${acegi.logout.url}) String logoutUrl, @Inject @Value(${acegi.afterlogout.url}) String afterLogoutUrl ) { Filter securityContextHolderAwareRequestFilter = (Filter)webApplicationContext.getBean(securityContextHolderAwareRequestFilter); configuration.add(acegiSecurityContextHolderAwareRequestFilter, new HttpServletRequestFilterWrapper(securityContextHolderAwareRequestFilter), after:acegiRememberMeProcessingFilter); LogoutHandler[] logoutHandler = { new SecurityContextLogoutHandler(), rememberMeLogoutHandler } ; LogoutFilter acegiLogoutFilter = new LogoutFilter(afterLogoutUrl,logoutHandler); acegiLogoutFilter.setFilterProcessesUrl(logoutUrl); configuration.add(acegiLogoutFilter, new HttpServletRequestFilterWrapper(acegiLogoutFilter), after:acegiHttpSessionContextIntegrationFilter); } -- View this message in context: http://www.nabble.com/-Announce--Acegi-Security-library-for-Tapestry-5-tf4279236.html#a12185631 Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: T5: static page variables in templates
You can use agentLister if you add a getAgentLister accessor to your class. Prop is the default binding for value and expansions - prop: is not needed, and you can use expansions in parameters. Or use message:agentLister with a properties file. Cheers, Nick. Chris Lewis-5 wrote: But alas, you cannot. If I remember correctly, you're not allowed to use expansions in parameters (${}). This isn't needed for value as its expanded anyway, but the bottom line is T5 throws an exception if you do something like this: t:radio value=prop:STATIC_FIELD/ or t:radio value=${prop:STATIC_FIELD}/ or t:radio value=STATIC_FIELD/ Even if the page class has this field. It throws an exception with the message: Could not convert 'prop:AGENT_LISTER' into a component parameter binding: Class xxx.Login does not contain a property named 'AGENT_LISTER' (within property expression 'AGENT_LISTER'). Daniel Jue wrote: T5 uses Prop, so you should be able to specify it using ${prop:STATIC_MEMBER} On 8/16/07, Chris Lewis [EMAIL PROTECTED] wrote: Hello, I'm implementing a form with some radio buttons. My understanding so far is that the radio buttons provide a value, and that value is stored in the containing RadioGroup's value parameter when the form is submitted. The form has only 2 radio buttons, each representing a string value. This string value should be a constant in the page class, but I can't figure out how to grab a constant from the page class in the template. In T4 this was done with something like: value=ognl:@com.app.MyPage.STATIC_MEMBER How can this be done in T5? thanks! chris - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/T5%3A-static-page-variables-in-templates-tf4280474.html#a12185540 Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: T5: static page variables in templates
Of course not - its a public static member. I realize Tap is trying to call this as part of the expansion, but what I'm asking is if there is a way to instruct Tap 5 (as there is Tap 4) to look for a static field. Josh Canfield wrote: I can't test this right now, but my first guess would be that you haven't implemented a getter method for the value. do you have a public String getAGENT_LISTER() method? On 8/16/07, Chris Lewis [EMAIL PROTECTED] wrote: But alas, you cannot. If I remember correctly, you're not allowed to use expansions in parameters (${}). This isn't needed for value as its expanded anyway, but the bottom line is T5 throws an exception if you do something like this: t:radio value=prop:STATIC_FIELD/ or t:radio value=${prop:STATIC_FIELD}/ or t:radio value=STATIC_FIELD/ Even if the page class has this field. It throws an exception with the message: Could not convert 'prop:AGENT_LISTER' into a component parameter binding: Class xxx.Login does not contain a property named 'AGENT_LISTER' (within property expression 'AGENT_LISTER'). Daniel Jue wrote: T5 uses Prop, so you should be able to specify it using ${prop:STATIC_MEMBER} On 8/16/07, Chris Lewis [EMAIL PROTECTED] wrote: Hello, I'm implementing a form with some radio buttons. My understanding so far is that the radio buttons provide a value, and that value is stored in the containing RadioGroup's value parameter when the form is submitted. The form has only 2 radio buttons, each representing a string value. This string value should be a constant in the page class, but I can't figure out how to grab a constant from the page class in the template. In T4 this was done with something like: value=ognl:@com.app.MyPage.STATIC_MEMBER How can this be done in T5? thanks! chris - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: RE : Re: T5: date picker component
I think it would be nice to have a DateFormat parameter on the component which can default to the current locale. I will have a look at it.. 2007/8/16, Julien HENRY [EMAIL PROTECTED]: Hi, As I said on google bug tracker, a good idea would be to put the date format in a localizable property file. Typically, date format will depend on the user locale. But I don't know how to do this... sorry. Julien --- Ted Steen [EMAIL PROTECTED] a écrit : This is something we will work on for the next release of this component. All ideas on how to dynamically generate the java script ifFormat for this (depending on the SimpleDateFormat on the server side) are welcome. oh! and also how to get the DateTranslator in the module to parse it correctly. 2007/8/16, Marcelo lotif [EMAIL PROTECTED]: i was looking for it a few days ago... just one question: it will have an easy to set translator in the future? if i want to set my own format i'll have to recompile the module ... Thanks! 2007/8/13, Ted Steen [EMAIL PROTECTED]: Hi! A new version of our date picker component is released. Compability issues with 5.0.5 is resolved. There are new features in un-commited code here, sent to me by Martin Dietze, but we want to have a closer look before we add it. http://code.google.com/p/tapestry5-jscalendar/ -- /ted - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Atenciosamente, Marcelo Lotif -- /ted - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ Ne gardez plus qu'une seule adresse mail ! Copiez vos mails vers Yahoo! Mail - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- /ted - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: T5: static page variables in templates
Exactly. getters/setters are fluff for this, and I prefer the semantics of static finals as opposed to storing the possible values in the message catalog. In reality it seems like the radio type components could have a bit more cohesion - let me elaborate. If you are using radio buttons, then you are absolutely restricting the user to 1 of N available choices. If you have multiple instances of absolutely bounded choices, then you have multiple radio groups. The point to take home is radio groups are only ever used to allow the selection of 1 choice from a known and finite set of choices. This aspect is not encapsulated by the radio component. It seems like this could be implemented with a (sorted) map, and then you could supply this map object to the radio container. This would alleviate the need to explicitly set the value on each radio component in the container, and would also open the door for extra validation (like the selection that comes it is actually a valid key in the map). This probably wouldn't be too hard to implement. I'm not at all bashing the components, I'm just pointing out what seems like a useful and natural improvement. Daniel Jue wrote: I think he wants to bypass the need for a getter and try to directly retrieve something like a static final, which should have the public visibility needed. I just assumed prop: would work since you specify the exact name, instead of having get appended. I guess ognl's special syntax for getting statics was that you specify the full path to the class that holds the static? On 8/16/07, Josh Canfield [EMAIL PROTECTED] wrote: I can't test this right now, but my first guess would be that you haven't implemented a getter method for the value. do you have a public String getAGENT_LISTER() method? On 8/16/07, Chris Lewis [EMAIL PROTECTED] wrote: But alas, you cannot. If I remember correctly, you're not allowed to use expansions in parameters (${}). This isn't needed for value as its expanded anyway, but the bottom line is T5 throws an exception if you do something like this: t:radio value=prop:STATIC_FIELD/ or t:radio value=${prop:STATIC_FIELD}/ or t:radio value=STATIC_FIELD/ Even if the page class has this field. It throws an exception with the message: Could not convert 'prop:AGENT_LISTER' into a component parameter binding: Class xxx.Login does not contain a property named 'AGENT_LISTER' (within property expression 'AGENT_LISTER'). Daniel Jue wrote: T5 uses Prop, so you should be able to specify it using ${prop:STATIC_MEMBER} On 8/16/07, Chris Lewis [EMAIL PROTECTED] wrote: Hello, I'm implementing a form with some radio buttons. My understanding so far is that the radio buttons provide a value, and that value is stored in the containing RadioGroup's value parameter when the form is submitted. The form has only 2 radio buttons, each representing a string value. This string value should be a constant in the page class, but I can't figure out how to grab a constant from the page class in the template. In T4 this was done with something like: value=ognl:@com.app.MyPage.STATIC_MEMBER How can this be done in T5? thanks! chris - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- -- TheDailyTube.com. Sign up and get the best new videos on the internet delivered fresh to your inbox. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[T5] Ajax tests
Hi, I play with T5 and want to explore Ajax capacity. I need to know which service is responsible on the instantiation of a component. Is it possible to have a resume (classes implied) of how Tapestry process component instantiation. Thanks for any input ;)
T-4.1.2 css overrides broken
Folks, Something changed with regard to CSS. I was overriding fine in T-4.0. Now it is broken. Here is whats in my layout.css div#header { color: black; clear: both; padding: 0; height: 15%; width: 100%; background: #fff url( images/trails-header94.jpg ) top left no-repeat; } Here is my markup rendered from my Home.html... script type=text/javascriptdjConfig = {isDebug:false,baseRelativePath:/assets/static/dojo-0.4.3/,parseWidgets:false,locale:en} /script script type=text/javascript src=/assets/static/dojo-0.4.3/dojo.js/script script type=text/javascript dojo.registerModulePath(tapestry, /assets/static/tapestry); /script script type=text/javascript src=/assets/static/tapestry/core.js/script script type=text/javascript dojo.require(tapestry.namespace); tapestry.requestEncoding='UTF-8'; /script !-- Application: trails -- !-- Page: Home -- !-- Generated: Thu Aug 16 13:52:26 EDT 2007 -- html head meta name=generator content=Tapestry Application Framework, version 4.1.2 / link rel=stylesheet type=text/css title=don't select href=/styles/tapestryskin/theme.css / style type=text/css div#header { color: black; clear: both; padding: 0; height: 15%; width: 100%; margin: 0; background: #fff url( /BlobService.svc?class=org.trails.demo.AdminLayoutcontentType=image/bmpfileName=eclipse.bmpid=1property=header ) top left no-repeat; } body { background-repeat: inherit; padding: 5; margin: 5; width: 100%; background: #fff url( /BlobService.svc?class=org.trails.demo.AdminLayoutcontentType=image/giffileName=backgd-original.gifid=1property=background ) top left repeat; } div#main { padding: 15 auto; width: 100%; } div#splash { background: #fff url( /BlobService.svc?class=org.trails.demo.AdminLayoutcontentType=image/jpegfileName=bae.parts.splash.jpgid=1property=splash ) top left no-repeat; } div#page { overflow: auto; width: 100%; padding: 0 0 0 0; margin: 0 0 0 0; background-repeat: repeat; background: #fff url( /BlobService.svc?class=org.trails.demo.AdminLayoutcontentType=image/giffileName=backgd-original.gifid=1property=background ) top left no-repeat; } /style /head body id=Body div id=page a id=PageLink href=/Home.page div id=header /div /a OK, my CustomHead (which extends Shell) rendered the overrides. Background override works. header override fails to work Any ideas? Best regards Ken in nashua _ Messenger Café open for fun 24/7. Hot games, cool activities served daily. Visit now. http://cafemessenger.com?ocid=TXT_TAGHM_AugHMtagline - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: T-4.1.2 css overrides broken
What I meant by header override failed to work ... The original layout.css image appears in Mozilla. IE nothing appears. So my header override is as if it does not exist. Could there be a reserved work collision with header? I did try headermain but that did nothing. I also cleared mozilla cache. No relief. _ Now you can see trouble before he arrives http://newlivehotmail.com/?ocid=TXT_TAGHM_migration_HM_viral_protection_0507 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
tapestry + ognl bootstrap issue - app broken
Same stack trace occurs on tapestry.version4.1.3-SNAPSHOT/tapestry.version ognl.version2.7.1-SNAPSHOT/ognl.version My Home.html only renders a stack trace.. Any ideas? Best regards Ken in nashua --- STACK TRACE FOLLOWS: HTTP ERROR: 500 ognl.OgnlContext.getLocalReferences()Ljava/util/Map; RequestURI=/app Caused by: org.apache.hivemind.ApplicationRuntimeException: ognl.OgnlContext.getLocalReferences()Ljava/util/Map; [classpath:/org/apache/tapestry/html/Style.jwc, line 56, column 55] at org.apache.tapestry.error.ExceptionPresenterImpl.presentException(ExceptionPresenterImpl.java:66) at org.trails.exception.ApplicationExceptionPresenterImpl.presentException(ApplicationExceptionPresenterImpl.java:26) at $ExceptionPresenter_1146fe0f759.presentException($ExceptionPresenter_1146fe0f759.java) at $ExceptionPresenter_1146fe0f758.presentException($ExceptionPresenter_1146fe0f758.java) at org.apache.tapestry.engine.AbstractEngine.activateExceptionPage(AbstractEngine.java:117) at org.apache.tapestry.engine.AbstractEngine.service(AbstractEngine.java:269) at org.apache.tapestry.services.impl.InvokeEngineTerminator.service(InvokeEngineTerminator.java:54) at $WebRequestServicer_1146fe0f7cb.service($WebRequestServicer_1146fe0f7cb.java) at $WebRequestServicer_1146fe0f7ca.service($WebRequestServicer_1146fe0f7ca.java) at org.apache.tapestry.services.impl.DisableCachingFilter.service(DisableCachingFilter.java:54) at $WebRequestServicerFilter_1146fe0f7cd.service($WebRequestServicerFilter_1146fe0f7cd.java) at $WebRequestServicerFilter_1146fe0f7cc.service($WebRequestServicerFilter_1146fe0f7cc.java) at $WebRequestServicer_1146fe0f7ce.service($WebRequestServicer_1146fe0f7ce.java) at org.trails.i18n.LocaleFilter.service(LocaleFilter.java:26) at $WebRequestServicerFilter_1146fe0f7c9.service($WebRequestServicerFilter_1146fe0f7c9.java) at $WebRequestServicerFilter_1146fe0f7c8.service($WebRequestServicerFilter_1146fe0f7c8.java) at $WebRequestServicer_1146fe0f7ce.service($WebRequestServicer_1146fe0f7ce.java) at $WebRequestServicer_1146fe0f7c5.service($WebRequestServicer_1146fe0f7c5.java) at $WebRequestServicer_1146fe0f7c4.service($WebRequestServicer_1146fe0f7c4.java) at org.apache.tapestry.services.impl.WebRequestServicerPipelineBridge.service(WebRequestServicerPipelineBridge.java:61) at $ServletRequestServicer_1146fe0f7ab.service($ServletRequestServicer_1146fe0f7ab.java) at $ServletRequestServicer_1146fe0f7aa.service($ServletRequestServicer_1146fe0f7aa.java) at org.apache.tapestry.request.DecodedRequestInjector.service(DecodedRequestInjector.java:55) at $ServletRequestServicerFilter_1146fe0f7a7.service($ServletRequestServicerFilter_1146fe0f7a7.java) at $ServletRequestServicerFilter_1146fe0f7a6.service($ServletRequestServicerFilter_1146fe0f7a6.java) at $ServletRequestServicer_1146fe0f7ac.service($ServletRequestServicer_1146fe0f7ac.java) at org.apache.tapestry.multipart.MultipartDecoderFilter.service(MultipartDecoderFilter.java:52) at $ServletRequestServicerFilter_1146fe0f7a5.service($ServletRequestServicerFilter_1146fe0f7a5.java) at $ServletRequestServicerFilter_1146fe0f7a4.service($ServletRequestServicerFilter_1146fe0f7a4.java) at $ServletRequestServicer_1146fe0f7ac.service($ServletRequestServicer_1146fe0f7ac.java) at org.apache.tapestry.services.impl.SetupRequestEncoding.service(SetupRequestEncoding.java:53) at $ServletRequestServicerFilter_1146fe0f7a9.service($ServletRequestServicerFilter_1146fe0f7a9.java) at $ServletRequestServicerFilter_1146fe0f7a8.service($ServletRequestServicerFilter_1146fe0f7a8.java) at $ServletRequestServicer_1146fe0f7ac.service($ServletRequestServicer_1146fe0f7ac.java) at $ServletRequestServicer_1146fe0f79f.service($ServletRequestServicer_1146fe0f79f.java) at $ServletRequestServicer_1146fe0f79e.service($ServletRequestServicer_1146fe0f79e.java) at org.apache.tapestry.ApplicationServlet.doService(ApplicationServlet.java:126) at org.apache.tapestry.ApplicationServlet.doGet(ApplicationServlet.java:103) at javax.servlet.http.HttpServlet.service(HttpServlet.java:740) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:491) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1074) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:70) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1065) at org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:198) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:75) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1065) at
Re: [Tapestry Beginner] Validation is ignored
I can't really see your mistake from the code, but anyway, here are two things that could be wrong: 1. for client-side validation to work, you need to set the clienValidationEnabled parameter of your form to true 2. be sure to bind the form's delegate-parameter to your delegate. 3. if you want server-side validation check the delegate bean using hasErrors 2007/8/16, ipoese [EMAIL PROTECTED]: Hi Everyone, i've been teaching myself tapestry for some time now, and everytime i think i am finally getting a grip on it something new comes up. OK, here's the deal... (i'll be using snippets since you guys probably don't want a million lines of code... all code i post compiles in it's context and runs without exceptions) i have to pages, Login and Register First for login: Login.html has: tr tdlabel jwcid=@FieldLabel field=component:usernameUser Name/label/td tdinput jwcid=username//td /tr Login.page has: bean name=ValidString class=myproject.Validator.ValidString / component id=username type=TextField binding name=value value=username/ binding name=validators value=validators:required,$ValidString / binding name=displayName value=message:username / /component Login.java has: public abstract String getUsername(); public abstract void setUsername(String Username); public IPage tryLogin(){ // -- gets called when the form around username is submitted //do fancy stuff } this works quite good. it checks the enteresd string in username against the self written Validator $ValidString. I can debug, breakpoint, step-though and see all the magic happening. quite cool, acctually. Now for Register Register.html trtdfirstname /tdtdinput type=text jwcid=firstname //td/tr trtdlastname /tdtdinput type=text jwcid=lastname //td/tr Register.page bean name=ValidString class=myproject.Validator.ValidString / !-- same validator as before -- !-- Form -- component id=register type=Form binding name=listener value=listener:tryUserCreate/ /component component id=submitRegister type=Submit /component !-- Attributes of a Person -- component id=firstname type=TextField binding name=value value=firstname/ binding name=validators value=validators:required,$ehfgbiasdbgujas / !-- NOTE THIS -- /component component id=lastname type=TextField binding name=value value=lastname/ binding name=validators value=validators:required,$ValidString / /component Register.java public abstract String getFirstname(); public abstract String getLastname(); public IPage tryUserCreate(){ // do more fancy stuff } now this acctually compiles and runs (!!!) without an error or expection even tho the gibberish Validator bean in firstname does not exist. This form has a lot more fields to it, and two more self written validators but this is pretty much the essence. now - the Validators here get ignored. i can write anything after the $ and it still runs through without any trouble. I can even delete the bean statement completely withouth raising an exception. required is also ignored - it jumps right into the listener without looking at the Validators. This started happening after i had to refactor the class to move it to another package. Used the NetBeans refactor (which always worked before) and suddenly it would not validate anymore. Refactoring it back does not help either. if i type somthing like this in one if the TextFields it does give me an exception upon loading the page: binding name=validators value=validators:required,fsgdsfghkjsn / Here is what i have tried: i have moved the Form around in register - even used it inline - same thing i have copied and pasted the content to a new file - same thing i have used tapestry 4.1.1, 4.1.2 and the nightly 4.1.3 - same thing i have deleted the project and reloaded it from svn - same thing i have set up NetBeans completely new - same thing i have run the application on two more machines (Windows, Debian, Ubuntu) - same thing i have run it with sun java 1.5 and 1.6 - same thing also, if i tried to use a Fieldlabel (maybe thats the error ?) and copied the username from Login to Register (it has a username too) - one to one copy - works in Login, not in Register (the Fieldlabel says no DisplayName was set in Username - which i definetly had set - and throws an expception) anybody got any idea why the validators get ignored or why Register is behaving to strange ? i really need this to work sometime soon... Hope this mail is not too cryptic, Ingmar -- View this message in context: http://www.nabble.com/-Tapestry-Beginner--Validation-is-ignored-tf4278261.html#a12177442 Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --
Re: T-4.1.2 css overrides broken
This error persists... If anyone can elaborate on the impact to CSS and workaround that would be terrific. I am currently running tapestry.version4.1.3-SNAPSHOT/tapestry.version ognl.version2.7.1-SNAPSHOT/ognl.version -Dorg.apache.tapestry.disable-caching=true _ Puzzles, trivia teasers, word scrambles and more. Play for your chance to win! http://club.live.com/home.aspx?icid=CLUB_hotmailtextlink - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [Tapestry Beginner] Validation is ignored
Marcus Schulte wrote: I can't really see your mistake from the code, but anyway, here are two things that could be wrong: 1. for client-side validation to work, you need to set the clienValidationEnabled parameter of your form to true 2. be sure to bind the form's delegate-parameter to your delegate. 3. if you want server-side validation check the delegate bean using hasErrors thanks for the answer - i have figured it out by myself by now - i used the listener event in the form instead of success - which means no matter what validation says, the form will still be submitted to the listener. This is not what i would have expected to happen - but it did happen, and it confused me greatly. Using the SubmitType submit and success listener now gets it all working nicely even with the self written validators. again, thanks for the answer - i think the issue at hand is resolved... -- View this message in context: http://www.nabble.com/-Tapestry-Beginner--Validation-is-ignored-tf4278261.html#a12189234 Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Jessionid and static resources
Yeah that is a lame practice. It doesn't do it anymore. (or at least won't in the next 5-8 minutes) On 8/15/07, Kevin Menard [EMAIL PROTECTED] wrote: Hi, About a year back I asked about jsessionid being added to static resources and how this was messing with us serving those resources up through apache httpd [1]. At the time, it was indicated that this would be fixed for 4.1. I've just gotten back into the 4.1.x game recently. Can anyone comment on whether or not this has been addressed? Thanks, Kevin [1] http://article.gmane.org/gmane.comp.java.tapestry.user/38351 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Jesse Kuhnert Tapestry/Dojo team member/developer Open source based consulting work centered around dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [Announce] Acegi Security library for Tapestry 5
On 8/16/07, Kheldar666 [EMAIL PROTECTED] wrote: I may have two questions : - First is it normal that you choose not to use the SecurityContextHolderAwareRequestFilter ? I used this : Is it needed? Can the filter be found without using spring beans? I want the library to be completly free of spring dependencies (I know I can't avoid Acegi using spring, but the library doesn't need to. - I tryied to use the loggout feature, but it seams not working : Error 404 when calling /j_acegi_logout. Should I add something somewhere ? The idea is to use the LogoutService. @Inject LogoutService logoutService; logoutService.logout(); If that doesn't work, something is wrong :) -- regards, Robin - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Class cast exception in ASTChain, Bug OGNL-11
Well, you guys let me know what it is that you want I guess. Though I'm sure many will not care about the perf increase at all there are some tapestry users with very large public facing applications where things like this are a huge bump in response times - which goes in to all kinds of formulas that eventually come out to happier users/ less money or similar... maybe If enough people want it I guess some kind of don't ever compile option could be made configurable somehow. On 8/16/07, Andrus Adamchik [EMAIL PROTECTED] wrote: I am an open source developer myself and I *love* when the users submit patches that work or at least create intelligent Jira's :-) But that's not the point here. Even though there is an OGNL-11 bug report, this is not a bug. This is a new feature of Tapestry 4.1. No matter was else was said in this thread, there is clearly a consensus between Tapestry commiters and users about what is causing it. The disagreement is what (if anything) should be done about that. So it will not help if I open another bug report saying my @For loop is broken - it will not get fixed unless we all agree that 4.0 scriptable behavior was a good thing :-) Cheers, Andrus Kalle Korhonen-2 wrote: Exclude the version that comes with 4.1.2 and fall back to 2.6.7. But, I think it's the responsibility of us, the users, to iron out the bugs in the expressionCompiler. I mean it's the least we can do. The benefits far outweigh the current issues from my perspective and Jesse's more than willing to fix any emerging issues. Everybody wants it, but if no one but him is willing to put down some effort, it'll never be finished. Kalle -- View this message in context: http://www.nabble.com/Class-cast-exception-in-ASTChain%2C-Bug-OGNL-11-tf4054151.html#a12183517 Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Jesse Kuhnert Tapestry/Dojo team member/developer Open source based consulting work centered around dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [Announce] Acegi Security library for Tapestry 5
For the SecurityContextHolder I went a little too fast... You don't need to use WebContextApplication : configuration.add(acegiSecurityContextHolderAwareRequestFilter, new HttpServletRequestFilterWrapper(new SecurityContextHolderAwareRequestFilter()), after:acegiRememberMeProcessingFilter); For the loggout service, if the purpose is to use only the LogoutService... What's the use of acegi.logout.url ? By the way, it's a great work you did. You solve many of my problems in one jar :) Cheers, Martin Robin Ericsson-3 wrote: On 8/16/07, Kheldar666 [EMAIL PROTECTED] wrote: I may have two questions : - First is it normal that you choose not to use the SecurityContextHolderAwareRequestFilter ? I used this : Is it needed? Can the filter be found without using spring beans? I want the library to be completly free of spring dependencies (I know I can't avoid Acegi using spring, but the library doesn't need to. - I tryied to use the loggout feature, but it seams not working : Error 404 when calling /j_acegi_logout. Should I add something somewhere ? The idea is to use the LogoutService. @Inject LogoutService logoutService; logoutService.logout(); If that doesn't work, something is wrong :) -- regards, Robin - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/-Announce--Acegi-Security-library-for-Tapestry-5-tf4279236.html#a12190506 Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: FYI T5.0.5 Tree Component based on DHTMLgoodies.com drag 'n drop folder tree
yeah! I will give my attention to it. 2007/8/15, Erik Vullings [EMAIL PROTECTED]: I've just created a simple T5 tree component: http://wiki.apache.org/tapestry/Tapestry5TreeComponent based on http://www.dhtmlgoodies.com/index.html?whichScript=drag-drop-folder-tree. Comments are welcome. Cheers Erik -- 得与失都是生活
T5 Validator
Hey guys, I've been using T5 for a while and haven't needed to create my own validator until now and I am absolutely dumb founded for how to do itany insight would be great. many thx, Jon - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
T4: Instance method dangers
I want to cache a rountrip to a database in an instance method of a page class like this: public FlowDataPageContent getFlowDataPageContent() { if (_pageContent == null) { _pageContent = getContentService().getFlowDataPageContent(/* some data in an ASO */); } return _pageContent; } content service is injected by Spring. Am I going to get into threading/concurrency problems here? Is there a more elegant way to avoid multiple round trips to the database accessed by my service? Bill - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: T4: Instance method dangers
It's thread safe. A more elegant method may be to push the caching out to something more generic like your database or object caching strategies such as is used in things like hibernate. Some properties - such as those passed in as parameters to components - are sometimes cached by tapestry during render already as well. On 8/16/07, Bill Holloway [EMAIL PROTECTED] wrote: I want to cache a rountrip to a database in an instance method of a page class like this: public FlowDataPageContent getFlowDataPageContent() { if (_pageContent == null) { _pageContent = getContentService().getFlowDataPageContent(/* some data in an ASO */); } return _pageContent; } content service is injected by Spring. Am I going to get into threading/concurrency problems here? Is there a more elegant way to avoid multiple round trips to the database accessed by my service? Bill - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Jesse Kuhnert Tapestry/Dojo team member/developer Open source based consulting work centered around dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Jessionid and static resources
Awesome. Thanks. Now if I just could get the maven ant tasks to grab the snapshots without hassle . . . Any plans to put out shorter release for 4.1.3? ;-) Thanks again, Kevin On 8/16/07 5:26 PM, in article [EMAIL PROTECTED], Jesse Kuhnert [EMAIL PROTECTED] wrote: Yeah that is a lame practice. It doesn't do it anymore. (or at least won't in the next 5-8 minutes) On 8/15/07, Kevin Menard [EMAIL PROTECTED] wrote: Hi, About a year back I asked about jsessionid being added to static resources and how this was messing with us serving those resources up through apache httpd [1]. At the time, it was indicated that this would be fixed for 4.1. I've just gotten back into the 4.1.x game recently. Can anyone comment on whether or not this has been addressed? Thanks, Kevin [1] http://article.gmane.org/gmane.comp.java.tapestry.user/38351 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: T4: Instance method dangers
Thanks! I'll talk to the service layer/Spring people tomorrow about pushing the caching down into the service there. They've been thinking about using os cache or something. bill On 8/16/07, Jesse Kuhnert [EMAIL PROTECTED] wrote: It's thread safe. A more elegant method may be to push the caching out to something more generic like your database or object caching strategies such as is used in things like hibernate. Some properties - such as those passed in as parameters to components - are sometimes cached by tapestry during render already as well. On 8/16/07, Bill Holloway [EMAIL PROTECTED] wrote: I want to cache a rountrip to a database in an instance method of a page class like this: public FlowDataPageContent getFlowDataPageContent() { if (_pageContent == null) { _pageContent = getContentService().getFlowDataPageContent(/* some data in an ASO */); } return _pageContent; } content service is injected by Spring. Am I going to get into threading/concurrency problems here? Is there a more elegant way to avoid multiple round trips to the database accessed by my service? Bill - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Jesse Kuhnert Tapestry/Dojo team member/developer Open source based consulting work centered around dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]