Re: switch between tml and component
This sounds great. When you say "auto-completion" do you mean it can prompt you for the parameters of a component? Please tell us more. On 18/09/2009, at 12:15 AM, Alfonso Quiroga wrote: Yes, I have eclipse configured so tml files are shown as JSP files, and I use a specific tapestry DTD for auto-completion, that works perfect. I was wondering a fast change between a component (or page) tml and java file, the loom project I think is very early by now, it has bugs and I couldn't achieve this. Thanks On Wed, Sep 16, 2009 at 9:55 PM, cleverpig wrote: you can use eclipse wtp to edit tml files,just config association for it. On Thu, Sep 17, 2009 at 5:39 AM, Thiago H. de Paula Figueiredo wrote: Em Wed, 16 Sep 2009 18:37:28 -0300, Alfonso Quiroga > escreveu: I wish to know if someone did a small plugin for eclipse, so I can switch between component's TML and component's java file, thanks! Take a look at http://code.google.com/p/loom-t5/. -- Thiago H. de Paula Figueiredo Independent Java consultant, developer, and instructor http://www.arsmachina.com.br/thiago - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org -- cleverpig(Dan) Location: Beijing Address: Room 4018,No.A2 South Avenue Fuxingmen Beijing,P.R.China Zipcode: 100031 MSN: great_liu...@hotmail.com QQ: 149291732 Skype: cleverpigatmatrix Facebook ID:cleverpig Blog: www.cleverpig.name Tags: del.icio.us/cleverpig Twitter: twitter.com/cleverpig 新浪微博: t.sina.com.cn/cleverpig Organization: www.beijing-open-party.org or...@facebook: http://www.facebook.com/group.php?gid=8159558294 - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: RenderInformals on Component With Template
This component will grab the first element from the template and add all the informal parameters to it. @SupportsInformalParameters public class Inf { @Inject private ComponentResources _resources; void afterRenderTemplate(MarkupWriter writer) { Element wrapper = null; // find first element added by the template (could be comment etc...) for (Node child : writer.getElement().getChildren()) { if (child instanceof Element) { wrapper = (Element) child; break; } } if (wrapper != null) { final List names = _resources.getInformalParameterNames(); for (String name : names) { wrapper.attribute(name, _resources.getInformalParameter(name, String.class)); } } } } Josh On Fri, Sep 18, 2009 at 9:12 AM, Kai Weber wrote: > Hi, > > I have *exactly* the same problem as the user adamh in June 2008. He hasn't > got an answer. Does, one year later, anyone has a glue? > > http://www.nabble.com/RenderInformals-on-Component-With-Template-tt18053261.html#a18053261 > > In short this is his problem: > > Inf.tml > xmlns:t="http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";> > Inf Component > > > InfTest.tml > http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";> > > > Hi > > > > Regards, Kai > > - > To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org > For additional commands, e-mail: users-h...@tapestry.apache.org > > -- -- TheDailyTube.com. Sign up and get the best new videos on the internet delivered fresh to your inbox. - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: [ANNOUNCE] ChenilleKit 1.2.0 RELEASE
Great news. I look forward to trying out the latest release. -- Kevin On Fri, Sep 18, 2009 at 11:44 AM, Massimo Lusetti wrote: > Hi everyone, > I'm happy to announce the 1.2.0 release of the ChenilleKit project, > our first release compatible with Tapestry 5.1.0.5. > > The ChenilleKit project lately have suffered from various issues > affecting project management that have complicated more then the > necessary the development. > > We finally find peace at CodeHaus http://chenillekit.codehaus.org. > > Anyway the release is done now and for the first time you will find > 1.2.0 artifacts in the central maven repo, thanks to CodeHaus syncing > with it. I think this is a great plus for us and everyone using > ChenilleKit. > > I would like 1.2.0 to be released as a distribution outside maven > scope too, but I failed, so you will find 1.2.0 only as a maven > artifacts, sorry for that. > > Due to our late moves (from googlecode to tapestry...@formos and then > to CodeHaus) we lost our JIRA issues and we cannot produce a reliable > release notes. > > I would like to remember one more time to everyone interested that we > have our own mailing lists: > - annou...@chenillekit.codehaus.org Projects announcing important > news about the project, used by the team. > - u...@chenillekit.codehaus.org Users discussions and support > - d...@chenillekit.codehaus.org Developers discussions about all > aspect of Chenillekit coding. > - s...@chenillakit.codehaus.org Commit logs and JIRA issues > > Cheers > -- > Massimo > http://meridio.blogspot.com > > - > To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org > For additional commands, e-mail: users-h...@tapestry.apache.org > > - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: passing a service into a component as a parameter
> > I am trying to pass services into my components via parameters, i.e. I want > something like: > > > What does the text "dooferController" represent in this context? Is it a string that represents the name of the service interface that you want to load? or is it a property in your page that holds a reference to the service implementation? Are you trying to avoid injecting the "dooferController" in the page/parent component and simply passing it without the special binding? If for instance you were building a graphing app and had BarChartService, PieChartService and ScatterPlotService and needed to use the service in the page and some child components; I would have their individual service interfaces implement a base ChartService interface. With a ChartService property in the page holding the chosen implementation you can pass them to the component using the standard property bindings built into tapestry. If you really want to build a binding for looking up services then try using Class.forName() and passing the actual name of the service interface you want to pull: since you know where your services live (your.tapestry.package.services) you can append the passed name, or pass a fully qualified path... or you could get really configurable and add configuration with several paths to prepend. Good luck, Josh On Fri, Sep 18, 2009 at 2:11 AM, david.boyce wrote: > > I am trying to pass services into my components via parameters, i.e. I want > something like: > > > > Where service is some custom binding type and dooferController is a service > I've defined in my application module. > > The problem is that the only way I know of getting hold of a service is via > the Registry, which requires a type (as opposed to a spring application > context) and in my BindingFactory, I don't have access to the type of the > parameter, so exactly how to retrieve the service is unclear. > > At the moment, I've implemented something that works, but via accessing the > RegistryWrapper's underlying Registries allServiceDefs collection, which > seems a bit fragile and not ideal for non-singleton services. > > Anybody got any ideas? > > Cheers > > David > -- > View this message in context: > http://www.nabble.com/passing-a-service-into-a-component-as-a-parameter-tp25505462p25505462.html > Sent from the Tapestry - User mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org > For additional commands, e-mail: users-h...@tapestry.apache.org > > -- -- TheDailyTube.com. Sign up and get the best new videos on the internet delivered fresh to your inbox. - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: [Tapestry Central] Tapestry Performance Benchmark (vs. Wicket, JSF, etc.)
> T5 doesn't use the session itself. That's exactly what puzzles me. Last time I checked the Form component persists the tracker, which means rendering a form puts something in your session. Every page in the test has a form and so a different tracker would be persisted. I haven't done any testing to see how much heap this is actually consuming, but I can't imagine that its too much. even with 20 sessions and 7 pages that should only be 140 trackers, right? Josh On Thu, Sep 17, 2009 at 4:44 PM, Thiago H. de Paula Figueiredo wrote: > Em Thu, 17 Sep 2009 18:31:11 -0300, Norman Franke > escreveu: > >> I'm puzzled by the retained size for 20 sessions. > > Me too . . . > >> Is that due to how >> he wrote the app and marked everything as @Persist, or is T5 really >> that bad? > > T5 doesn't use the session itself. That's exactly what puzzles me. > > -- > Thiago H. de Paula Figueiredo > Independent Java consultant, developer, and instructor > http://www.arsmachina.com.br/thiago > > - > To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org > For additional commands, e-mail: users-h...@tapestry.apache.org > > -- -- TheDailyTube.com. Sign up and get the best new videos on the internet delivered fresh to your inbox. - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: T5.1 Graceful Session Timeout?
Since I'm sticking this in a superclass to be inherited by many pages, I'll pretend it is slightly more efficient to return the .class (which may not be true at all). It is indeed less code. :-) Thanks Thiago! mrg On Fri, Sep 18, 2009 at 4:32 PM, Thiago H. de Paula Figueiredo wrote: > Em Fri, 18 Sep 2009 17:28:03 -0300, Michael Gentry > escreveu: > >> Initially I was thinking I might need to set some values in my >> SessionTimeout page, but now I'm not sure if I'll do that. I'm >> assuming returning SessionTimeout.class will be more efficient than >> injecting the page? > > I don't know about performance, but returning SessionTimeout.class doesn't > need a private field annotated with @InjectPage. A little bit less code. :) > > -- > Thiago H. de Paula Figueiredo > Independent Java consultant, developer, and instructor > http://www.arsmachina.com.br/thiago > > - > To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org > For additional commands, e-mail: users-h...@tapestry.apache.org > > - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: T5.1 Graceful Session Timeout?
Em Fri, 18 Sep 2009 17:28:03 -0300, Michael Gentry escreveu: Initially I was thinking I might need to set some values in my SessionTimeout page, but now I'm not sure if I'll do that. I'm assuming returning SessionTimeout.class will be more efficient than injecting the page? I don't know about performance, but returning SessionTimeout.class doesn't need a private field annotated with @InjectPage. A little bit less code. :) -- Thiago H. de Paula Figueiredo Independent Java consultant, developer, and instructor http://www.arsmachina.com.br/thiago - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: T5.1 Graceful Session Timeout?
Initially I was thinking I might need to set some values in my SessionTimeout page, but now I'm not sure if I'll do that. I'm assuming returning SessionTimeout.class will be more efficient than injecting the page? Thanks Thiago, mrg On Fri, Sep 18, 2009 at 3:33 PM, Thiago H. de Paula Figueiredo wrote: > Em Fri, 18 Sep 2009 16:28:00 -0300, Michael Gentry > escreveu: > >> public Object onPrepareForSubmit() >> { >> // If there is no session, return the timeout page. >> if (sessionExists == false) >> return sessionTimeout; > > If you don't need to invoke methods in sessionTimeout, you can just return > SessionTimeout.class with the same result. > > -- > Thiago H. de Paula Figueiredo > Independent Java consultant, developer, and instructor > http://www.arsmachina.com.br/thiago > > - > To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org > For additional commands, e-mail: users-h...@tapestry.apache.org > > - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: T5.1 Graceful Session Timeout?
Em Fri, 18 Sep 2009 16:28:00 -0300, Michael Gentry escreveu: public Object onPrepareForSubmit() { // If there is no session, return the timeout page. if (sessionExists == false) return sessionTimeout; If you don't need to invoke methods in sessionTimeout, you can just return SessionTimeout.class with the same result. -- Thiago H. de Paula Figueiredo Independent Java consultant, developer, and instructor http://www.arsmachina.com.br/thiago - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: T5.1 Graceful Session Timeout?
For any who might need/want this, here is my current solution (this only works on FORM submits, but can be expanded upon): public Object onPrepareForSubmit() { // If there is no session, return the timeout page. if (sessionExists == false) return sessionTimeout; else return null; } @SessionState private Session session; private boolean sessionExists; @InjectPage private SessionTimeout sessionTimeout; Basically, if the session has vanished, it interrupts the FORM submission and redirects to the SessionTimeout page. mrg On Fri, Sep 18, 2009 at 9:37 AM, Michael Gentry wrote: > Well, I can't just create a new object, since I was editing an > existing one. So I had my object persisted, but now it is gone and > I'm getting an NPE. Tapestry doesn't seem to know my application > requires the session (and present a session timeout page) and I > haven't found a way to tell it to stop processing the FORM submission > yet. > > I'll look at your conversations link and see if that gives me ideas. > > mrg > > > On Thu, Sep 17, 2009 at 5:33 PM, Kalle Korhonen > wrote: >> Just to prevent nullpointers, in your onActivate() you should have if >> (object == null) object = new Object(). Obviously that could lead to >> unexpected results to the user - based on object state you could >> present a a message to the user etc. but there are quite a few >> different cases that you need to handle. Or you can detach the "page >> timeout" from session timeout and use some type of conversations, e.g. >> http://docs.codehaus.org/display/TRAILS/Conversations+in+Trails. >> >> Kalle >> >> >> On Thu, Sep 17, 2009 at 2:08 PM, Michael Gentry >> wrote: >>> Is there a way in T5.1 to have graceful session timeout handling on >>> form submission or links? >>> >>> For example, I have a form with a bunch of inputs and I wait to click >>> the button until my 2-minute session times out (I'm >>> developing/debugging, so a short session expiration). When I submit >>> the form, I get NPEs because the objects I required (and used @Persist >>> on) are no longer there. I'd like a way to gracefully handle that and >>> present a message or something. I've been searching the list, the >>> documentation, the wiki, and the JumpStart, but still haven't found >>> the right magic. >>> >>> Thanks, >>> >>> mrg >>> >>> - >>> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org >>> For additional commands, e-mail: users-h...@tapestry.apache.org >>> >>> >> >> - >> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org >> For additional commands, e-mail: users-h...@tapestry.apache.org >> >> > - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: [Announce] ioko-tapestry-commons-1.4.0
Yes, it is because dual EHCaches. We don't use disk persistence, so we haven't modified the diskStore attribute in ehcache.xml. So starting the next CacheManager instance causes a collision on this. I also want to avoid having duplicate config files for EHCache, so I wrote a custom CacheContentImpl which uses the already existing CacheManager. I swapped it by means of Tapestry's service override mechanism. Works like a charm! Olle 2009/9/17 Ben Gidley > Hi, > Is the error your getting complaining about 2 ehcaches? We have this in one > of our apps and it all works fine - so I am puzzled you are getting this > error. > > Ben Gidley > > www.gidley.co.uk > b...@gidley.co.uk > > > On Thu, Sep 17, 2009 at 2:15 PM, Olle Hallin wrote: > > > Hi! > > > > I just made an attempt to introduce the Ioko tapestry-caching library in > > our > > project, but stumbled on the fact that we already use EhCache. (We use > > tapestry-cache 1.5.0) > > > > (Manifested as an exception from ContentCacheImpl. when it tries to > > create the CacheManager instance.) > > > > I then tried to build my own version of the ContentCache service, hoping > > that it would replace the one in the Ioko CacheModule. But Tapestry then > > complains that there is more than one implementation of that interface. > > > > I then tried to decorate the ContentCache service built by CacheModule, > but > > that does not prevent the original service from being started. > > > > For us it would be valuable with some mechanism where one can inject an > > already running > > CacheManager into the Ioko ContentCacheImpl. > > > > Another feasible solution would be to provide our own implementation, and > > *prevent* the Ioko instance to start. Is it possible to prevent builder > > methods in other modules from being executed? > > > > Any ideas? > > > > Olle Hallin > > Senior Java Developer and Architect > > olle.hal...@crisp.se > > www.crisp.se > > > > > > > > > > 2009/8/6 Otho > > > > > There are some typos on > > > http://tapestry.formos.com/projects/ioko-tapestry-commons/ . In all > > > dependencies the starting slash of the closing is > missing. > > > > > > > > > 2009/8/5 Inge Solvoll > > > > > > > Excellent. I love the convenient javascript and jquery jars! > > > > > > > > On Tue, Aug 4, 2009 at 3:04 PM, Ben Gidley wrote: > > > > > > > > > Hi, > > > > > > > > > > ioko-tapestry-commons 1.4.0 has been released. This is a bug fix > > > release > > > > to > > > > > address issues in including the libraries. > > > > > > > > > > Full details and downloads are available at > > > > > http://tapestry.formos.com/projects/ioko-tapestry-commons/ > > > > > > > > > > Ben Gidley > > > > > > > > > > www.gidley.co.uk > > > > > b...@gidley.co.uk > > > > > > > > > > > > > > >
Re: [ANNOUNCE] ChenilleKit 1.2.0 RELEASE
:) :) :) Thanks a lot CK Team!! On Fri, Sep 18, 2009 at 5:44 PM, Massimo Lusetti wrote: > Hi everyone, > I'm happy to announce the 1.2.0 release of the ChenilleKit project, > our first release compatible with Tapestry 5.1.0.5. > > The ChenilleKit project lately have suffered from various issues > affecting project management that have complicated more then the > necessary the development. > > We finally find peace at CodeHaus http://chenillekit.codehaus.org. > > Anyway the release is done now and for the first time you will find > 1.2.0 artifacts in the central maven repo, thanks to CodeHaus syncing > with it. I think this is a great plus for us and everyone using > ChenilleKit. > > I would like 1.2.0 to be released as a distribution outside maven > scope too, but I failed, so you will find 1.2.0 only as a maven > artifacts, sorry for that. > > Due to our late moves (from googlecode to tapestry...@formos and then > to CodeHaus) we lost our JIRA issues and we cannot produce a reliable > release notes. > > I would like to remember one more time to everyone interested that we > have our own mailing lists: > - annou...@chenillekit.codehaus.org Projects announcing important > news about the project, used by the team. > - u...@chenillekit.codehaus.org Users discussions and support > - d...@chenillekit.codehaus.org Developers discussions about all > aspect of Chenillekit coding. > - s...@chenillakit.codehaus.org Commit logs and JIRA issues > > Cheers > -- > Massimo > http://meridio.blogspot.com > > - > To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org > For additional commands, e-mail: users-h...@tapestry.apache.org > > - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
RenderInformals on Component With Template
Hi, I have *exactly* the same problem as the user adamh in June 2008. He hasn't got an answer. Does, one year later, anyone has a glue? http://www.nabble.com/RenderInformals-on-Component-With-Template-tt18053261.html#a18053261 In short this is his problem: Inf.tml http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";> Inf Component InfTest.tml http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";> Hi Regards, Kai - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
[ANNOUNCE] ChenilleKit 1.2.0 RELEASE
Hi everyone, I'm happy to announce the 1.2.0 release of the ChenilleKit project, our first release compatible with Tapestry 5.1.0.5. The ChenilleKit project lately have suffered from various issues affecting project management that have complicated more then the necessary the development. We finally find peace at CodeHaus http://chenillekit.codehaus.org. Anyway the release is done now and for the first time you will find 1.2.0 artifacts in the central maven repo, thanks to CodeHaus syncing with it. I think this is a great plus for us and everyone using ChenilleKit. I would like 1.2.0 to be released as a distribution outside maven scope too, but I failed, so you will find 1.2.0 only as a maven artifacts, sorry for that. Due to our late moves (from googlecode to tapestry...@formos and then to CodeHaus) we lost our JIRA issues and we cannot produce a reliable release notes. I would like to remember one more time to everyone interested that we have our own mailing lists: - annou...@chenillekit.codehaus.org Projects announcing important news about the project, used by the team. - u...@chenillekit.codehaus.org Users discussions and support - d...@chenillekit.codehaus.org Developers discussions about all aspect of Chenillekit coding. - s...@chenillakit.codehaus.org Commit logs and JIRA issues Cheers -- Massimo http://meridio.blogspot.com - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: [T5] Pick up https/http from request
Important note on this one: My implementation breaks non-standard ports, and makes pages on port 8080 post forms to port 80. The correct way to address this is to just return null and false in the 2 methods, and do a service override instead of alias. On Thu, Nov 27, 2008 at 4:18 PM, Ryan Mitchell wrote: > Hi, glad to see the solution, I came up with something almost > identical, contributing my own RequestSecurityManager. I posted about > this issue a few weeks ago and was surprised no one responded, but I > figured I was explaining the problem weirdly, as I'm wont to do. In > my case the problem led to sessions being lost between the transitions > from https to http requests if the cookie the container created was > flagged as 'secure'. > > My implementation of RequestSecurityManager is identical to the > original T5 impl except one line: > > public String getBaseURL(Page page) { > boolean securePage = isSecure(page); >if (securePage == request.isSecure()) return null; >if (request.isSecure()) return null; // <<< rjm added 2008-10-30 >return baseURLSource.getBaseURL(securePage); >} > > I *think* this would resolve TAP5-167, though I haven't tested > explicitly. It does work well for my own application, were there is > an explicit mix of http and https pages (using @Secure annotation, > etc). > > > On Thu, Nov 27, 2008 at 3:56 AM, Michael Gerzabek > wrote: > > straight forward! Thanks for posting your solution. > > > > Inge Solvoll schrieb: > >> > >> Excellent! Thanks for thep help, everyone!! This has made my life so > much > >> easier... > >> > >> Got it working like this: > >> > >> In my implementation of RequestSecurityManager: > >> > >> public boolean checkForInsecureRequest(String pageName) throws > >> IOException > >> { > >>return false; > >> } > >> > >> public String getBaseURL(Page page) { > >>return baseURLSource.getBaseURL(request.isSecure()); > >> } > >> > >> > >> In my Appmodule: > >> > >> public static void contributeAlias(Configuration > >> configuration, @InjectService("Request") Request request, > >> @InjectService("BaseURLSource") BaseURLSource baseURLSource) { > >>RequestSecurityManager manager = new > MyRequestSecurityManager(request, > >> baseURLSource); > >> > >> > configuration.add(AliasContribution.create(RequestSecurityManager.class, > >> manager)); > >> } > >> > >> > >> On Wed, Nov 26, 2008 at 12:42 PM, Michael Gerzabek > >> >> > >>> > >>> wrote: > >>> > >> > >> > >>> > >>> Inge Solvoll schrieb: > >>> > >>> > > Thanks, I'll look into that then. > > What I want to do: > > 1. The user accesses http://myserver.com/mypage. Should get the same > url/protocol in return. > 2. The user accesses https://myserver.com/mypage. Should get the same > url/protocol in return. > > > > >>> > >>> Ok, > >>> > >>> so then forget BaseURLSource and implement RequestSecurityManager. The > >>> code > >>> could be something like > >>> > >>> public boolean checkForInsecureRequest( String pageName ) > >>> throws IOException { > >>> > >>> ... copy-n-paste from T5 implementation ... > >>> } > >>> > >>> public String getBaseURL( Page page ) { > >>> > >>> return baseURLSource.getBaseURL( request.isSecure() ); > >>> } > >>> > >>> and get Request injected in your constructor. > >>> > >>> /Michael > >>> > >>> As of now, the user gets a fixed protocol in return, not the protocol > he > >>> > > requested. > > > > On Wed, Nov 26, 2008 at 12:29 PM, Michael Gerzabek < > michael.gerza...@gmx.net > > > > > > > wrote: > > > > > > > > > > > > Inge, > > > > not sure that I undestand fully what you are about. It sounds like > you > > also > > want to implement RequestSecurityManager ( > > > > > > > http://tapestry.apache.org/tapestry5/apidocs/org/apache/tapestry5/internal/services/package-tree.html > > ). > > This is at least what I did and it works for me. > > > > /Michael > > > > Inge Solvoll schrieb: > > > > I think I know the reason for the loop... > > > > > > > >> > >> my getBaseURL method is only called when the requested url has a > >> different > >> protocol than specified in MetaDataConstants.SECURE_PAGE. It seems > >> that > >> when > >> I try to write a base URL in my custom method that has a different > >> protocol > >> than SECURE_PAGE value, they start knocking each other's heades with > >> redirects. > >> > >> Right now, it looks like this system works differently than I > thought. > >> Is > >> it > >> not possible to override the behaviour of one page or entire > >> application > >> fixed on a protocol? > >> > >> > >> > >> On Wed, Nov 26, 2008 at 11:44 AM, Kristian Marinkovic < > >> kristian.marinko...@porsche.co.at> wrote:
Re: T5.1 Graceful Session Timeout?
Well, I can't just create a new object, since I was editing an existing one. So I had my object persisted, but now it is gone and I'm getting an NPE. Tapestry doesn't seem to know my application requires the session (and present a session timeout page) and I haven't found a way to tell it to stop processing the FORM submission yet. I'll look at your conversations link and see if that gives me ideas. mrg On Thu, Sep 17, 2009 at 5:33 PM, Kalle Korhonen wrote: > Just to prevent nullpointers, in your onActivate() you should have if > (object == null) object = new Object(). Obviously that could lead to > unexpected results to the user - based on object state you could > present a a message to the user etc. but there are quite a few > different cases that you need to handle. Or you can detach the "page > timeout" from session timeout and use some type of conversations, e.g. > http://docs.codehaus.org/display/TRAILS/Conversations+in+Trails. > > Kalle > > > On Thu, Sep 17, 2009 at 2:08 PM, Michael Gentry wrote: >> Is there a way in T5.1 to have graceful session timeout handling on >> form submission or links? >> >> For example, I have a form with a bunch of inputs and I wait to click >> the button until my 2-minute session times out (I'm >> developing/debugging, so a short session expiration). When I submit >> the form, I get NPEs because the objects I required (and used @Persist >> on) are no longer there. I'd like a way to gracefully handle that and >> present a message or something. I've been searching the list, the >> documentation, the wiki, and the JumpStart, but still haven't found >> the right magic. >> >> Thanks, >> >> mrg >> >> - >> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org >> For additional commands, e-mail: users-h...@tapestry.apache.org >> >> > > - > To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org > For additional commands, e-mail: users-h...@tapestry.apache.org > > - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
WL10.3, Tapestry4.0, Module tapestry is duplicated error
Hello, My Tapestry4.0 web app(war file) works fine in WL92/JDK15, but trying the exact same web app(war file) in WL103/JDK16 generates below: Note that referenced path and file are EXACTLY the same. Any suggestions are greatly appreciated ! weblogic.application.ModuleException: [HTTP:101216]Servlet: "soWEDATWebApp" failed to preload on startup in Web application: "soWEDATWebApp.war". org.apache.hivemind.ApplicationRuntimeException: Error: Module tapestry is duplicated! Definition in jar:file:/opt/app/d1qpa1c1/pmts_home/jd8665/soWEDAT_Rel98a/vobs/wedat_dev/ wedat/soWEDAT/lib/tapestry-4.0.jar!/META-INF/hivemodule.xml has been ignored in favor of existing definition from jar:file:/opt/app/d1qpa1c1/pmts_home/jd8665/soWEDAT_Rel98a/vobs/wedat_dev/ wedat/soWEDAT/lib/tapestry-4.0.jar!/META-INF/hivemodule.xml. - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
passing a service into a component as a parameter
I am trying to pass services into my components via parameters, i.e. I want something like: Where service is some custom binding type and dooferController is a service I've defined in my application module. The problem is that the only way I know of getting hold of a service is via the Registry, which requires a type (as opposed to a spring application context) and in my BindingFactory, I don't have access to the type of the parameter, so exactly how to retrieve the service is unclear. At the moment, I've implemented something that works, but via accessing the RegistryWrapper's underlying Registries allServiceDefs collection, which seems a bit fragile and not ideal for non-singleton services. Anybody got any ideas? Cheers David -- View this message in context: http://www.nabble.com/passing-a-service-into-a-component-as-a-parameter-tp25505462p25505462.html Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: zone append or add new content
That problem still exists. I need a simple mechanism to add or delete some content via ajax which don't refresh older added content. The ajaxformloop is no option. -- View this message in context: http://www.nabble.com/zone-append-or-add-new-content-tp25185239p25505178.html Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: switch between tml and component
Looms works ok for me on Eclipse Ganymede (3.4.2) P.S. Loom is pretty old BTW On Thu, Sep 17, 2009 at 5:15 PM, Alfonso Quiroga wrote: > Yes, I have eclipse configured so tml files are shown as JSP files, > and I use a specific tapestry DTD for auto-completion, that works > perfect. I was wondering a fast change between a component (or page) > tml and java file, the loom project I think is very early by now, it > has bugs and I couldn't achieve this. Thanks - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: Palette and selection filtering
Thanks, stupid me. to many entries that look the same. Thiago H. de Paula Figueiredo wrote: > > Em Thu, 17 Sep 2009 09:42:52 -0300, rolfst escreveu: > >> Hi > > Hi! > >> Iam trying to filter out the already selected entries from the available >> entries from a palette. > > Palette does that by itself. > > -- > Thiago H. de Paula Figueiredo > Independent Java consultant, developer, and instructor > http://www.arsmachina.com.br/thiago > > - > To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org > For additional commands, e-mail: users-h...@tapestry.apache.org > > > -- View this message in context: http://www.nabble.com/Palette-and-selection-filtering-tp25490487p25504805.html Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: Using locale from user setting after login
On Fri, 18. Sep 2009, Stephan Windmüller wrote: > > Use a RequestFilter for setting the locale. > But I am unsure about how to implement this. Okay, I asked for help a little too quickly. Some things I figured out myself, but still the filter does not work. > Additionally I have to figure out if the user is logged in because > otherwise the database will return an error when I receive the saved > locale. The Request class does not have getRemoteUser(). Here I used RequestGlobals. > And is it possible to use Beans in the RequestFilter which I would > Inject on normal pages? That is possible using the build-Methods in AppModule itself. So my code looks now like this: public RequestFilter buildLocaleFilter(final RequestGlobals globals, final PersistentLocale persistentLocale){ return new RequestFilter(){ public boolean service(Request request, Response response, RequestHandler handler) throws IOException { if (globals.getHTTPServletRequest().getRemoteUser() != null) { Locale preferredLanguage = getDatabaseUser().getPreferredLanguage(); persistentLocale.set(preferredLanguage); } return handler.service(request, response); } }; } According to the debug output the locale is set, but that did not change anything on the page. - Stephan - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: StreamResponse on Success
Thanks .. that's what i'll do ... some page refresh from javascript .. Em Thu, 17 Sep 2009 11:55:03 -0300, jose luis sanchez escreveu: Anyone on this, please ? Tapestry doesn't do a redirect-after-post when you return a StreamResponse. HTTP doesn't allow to return two different responses at the same time (CSV and HTML, in your case). One possible solution is to force a page refresh using Javascript. - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: Using locale from user setting after login
Thiago H. de Paula Figueiredo wrote: >> We are using form based login from the application server (tomcat). >> So we are unable to modify the login logic. :-/ > Use a RequestFilter for setting the locale. Thanks, that looks like the correct place to put this code. But I am unsure about how to implement this. Is there any documentation of AppModule besides the JavaDoc or are there any examples for implemented RequestFilters besides the simple TimingFilter? Additionally I have to figure out if the user is logged in because otherwise the database will return an error when I receive the saved locale. The Request class does not have getRemoteUser(). And is it possible to use Beans in the RequestFilter which I would Inject on normal pages? Regards Stephan - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org