Confused about Resource basics
Hi, I just realised that our session is getting loaded multiple times per web request. I see that aside from the page request the session is getting loaded for items such as css, js, etc that are referenced in the code. Now I'm trying to make sure I understand resources correctly in terms of session synchronization. I can;t find much documentation on that aside from the mention in SharedResources javadoc. Can someone correct me on this. But aside from SharedResrouces are all other types of resources sync'd with the session (ie its loaded)? Including StyleSheetReference, all ResourceReference's, etc? It seems that all our css and javascript references that are part of components are going through loading the session. thanks for any pointers on this as I'm really confused. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Confused about Resource basics
Further to this - if I look at the code in the wicket filter: resource = webApplication.getSharedResources().get(resourceReferenceKey); // If resource found and it is cacheable if ((resource != null) resource.isCacheable()) { snip.. Session.findOrCreate(request, response); It seems that shared resources will also load the session etc time. How can I avoid the session being loaded? On Mon, Oct 11, 2010 at 6:25 PM, Wayne Pope waynemailingli...@googlemail.com wrote: Hi, I just realised that our session is getting loaded multiple times per web request. I see that aside from the page request the session is getting loaded for items such as css, js, etc that are referenced in the code. Now I'm trying to make sure I understand resources correctly in terms of session synchronization. I can;t find much documentation on that aside from the mention in SharedResources javadoc. Can someone correct me on this. But aside from SharedResrouces are all other types of resources sync'd with the session (ie its loaded)? Including StyleSheetReference, all ResourceReference's, etc? It seems that all our css and javascript references that are part of components are going through loading the session. thanks for any pointers on this as I'm really confused. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Wicket 1.4.12 Ajax problems
We haven't used 1.4.11, so it comes from upgrading from 1.4.8 straight to 1.4.12 I'm no good at javascript at all, but I will see what I can reproduce with a quickstart when I get time. But for now we'll stick with 1.4.8 in production. On Sun, Oct 3, 2010 at 12:48 PM, Martin Grigorov mgrigo...@apache.org wrote: Did you try with 1.4.11 before trying 1.4.12 ? Someone in IRC had the same problem - try 1.4.11, the browser caches the broken wicket-ajax.js (see WICKET-3040) and then upgrade to 1.4.12 but the browser still used the cached version from 1.4.11. You said that you tried several browsers so maybe it is not the same case. Many people use 1.4.12 and they don't experience this problem... On Sun, Oct 3, 2010 at 12:32 PM, Mathias Nilsson wicket.program...@gmail.com wrote: I also tried 1.4.12 and got the same problem in chrome. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Wicket-1-4-12-Ajax-problems-tp2930684p2953070.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Wicket 1.4.12 Ajax problems
Hi, I just tried migrating our app from 1.4.8 to 1.4.12. However I'm having a lot of trouble with ajax submits now. I cannot get anything to work. I'm getting various problems depending on the browser. Such errors as: stack overflow in line 433 (IE7) Wicket.WUPB.Def is null or not an object (line 554) (IE7) Wicket.WUPB is undefined (Firefox). It must be something we're not doing or missing. Anyone got an ideas before I go spend a day or 2 trying to figure this out. thanks for any tips. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: UploadProgressBar does not work in Safari browser?
Does anyone know if any patches were submitted for this or does anyone know of some code that can work? We're finding more and more of our users are Chrome and Safari and its becoming a pain. I have tried looking at this but my javascript knowledge is beginner at best. thanks for any help or pointers Wayne On Sat, Jul 4, 2009 at 9:46 PM, Mathias Nilsson wicket.program...@gmail.com wrote: After dealing with this for a long time I desided to make my own servlet and AJAX communication and that works. It seams to be a problem for Safari, Chrome to make a GET request to resources/classpath. I don't see anything other than that that messes up the UploadProgressBar to work in all browsers. Also, there is a bug in the percentage width for safari and Opera. You could do this by changing the % width to pixels and solve the problem. -- View this message in context: http://www.nabble.com/UploadProgressBar-does-not-work-in-Safari-browser--tp21571997p24337460.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: debugging PageExpiredExceptions
We're interested in this as well, as our logs are full of these as well. On Mon, Apr 12, 2010 at 10:32 AM, Nikita Tovstoles nikita.tovsto...@gmail.com wrote: So far I traced this down to the fact that sometimes some wicket:interface requests (in our case used in img src and in anchor 'href) do not include a jsessionid - either as a ;jsessionid= URL param or a cookie - thus no session can be found. The container's impl of HttpServletResponse.encodeURL(String) decides whether to rewrite the URL with jsessionid. It's supposed to NOT rewrite the URL if the client is confirmed to support cookie (though there are other criteria). I imagine that works correctly (we're using Tomcat 6.0.20). Anyone know of cases wherein wicket does not call response.encodeURL(generatedURL) for whatever reason? -nikita On Fri, Apr 9, 2010 at 3:51 PM, Nikita Tovstoles nikita.tovsto...@gmail.com wrote: Here's a typical exception: 00:01:17,644 ERROR CLPWebRequestCycle:34 - Cannot find the rendered page in session [pagemap=null,componentPath=7:results:resultsInfo:criteriaContainer:inputPanel:categorySearchForm:submitLink:searchButton,versionNumber=0] org.apache.wicket.protocol.http.PageExpiredException: Cannot find the rendered page in session [pagemap=null,componentPath=7:results:resultsInfo:criteriaContainer:inputPanel:categorySearchForm:submitLink:searchButton,versionNumber=0] at org.apache.wicket.protocol.http.WebRequestCycleProcessor.resolve(WebRequestCycleProcessor.java:197) at org.apache.wicket.RequestCycle.step(RequestCycle.java:1310) at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1428) at org.apache.wicket.RequestCycle.request(RequestCycle.java:545) at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:479) at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:312) On Fri, Apr 9, 2010 at 3:35 PM, Nikita Tovstoles nikita.tovsto...@gmail.com wrote: We're seeing a PageExpiredExceptions in roughly 2-6% of our production web sessions and cannot determine the root cause: 1. it's not a session affinity problem (we went as far as running a single node - the exceptions persisted) 2. it's not a session expiration case (our avg production session is far less than 40 min session timeout value; given the number of sessions wherein PEEs occur it's highly unlikely that those sessions are the 40+ min outliers 3. it's not a serialization problem - everything on pages is serializable. And if it were a serialization issue, should we not be seeing WicketSerializeableException stack traces in the logs? 4. Settings.automaticMultiWindowSupport remains at default (=true) 5. we cannot come up with a consistent repro though somehow managed to cause PEE to happen a couple of times by seemingly randomly clicking on UI controls and playing with back/forward browser buttons Any tips on how to go about determining the root cause? Looking at the exception below (typical - always thrown from WebRequestCycleProcessor.resolve()), what specifically would you look for? Which loggers would it be useful to turn to debug? Also, is there any way to determine Page class type when catching a PageExpiredException - so at least we could implement on PEE throw new RestartResponseException(pageType, defaultParams) - instead of showing the default error page. thanks, -nikita - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Properties of model are set to NULL even though we have setRequired set to true
Hi, has anyone got any idea about this? I'm still 'spinning my wheels' on it. thanks for any help. On Fri, Apr 2, 2010 at 5:00 PM, Wayne Pope waynemailingli...@googlemail.com wrote: Hi, we've got several examples in our logs of properties of the model being set to null even though the textfield is set to required. I have NO idea how on earth this can happen - its just doesn't make sense - and its really frustrating me!! here's an example: Caused by: java.lang.NullPointerException at org.apache.commons.codec.digest.DigestUtils.md5(DigestUtils.java:86) at org.apache.commons.codec.digest.DigestUtils.md5Hex(DigestUtils.java:108) at hub.app.wicket.admin.ChangePasswordPage$1.onSubmit(ChangePasswordPage.java:49) at org.apache.wicket.markup.html.form.Form.delegateSubmit(Form.java:1518) ... FormUser form = new FormUser(form, new CompoundPropertyModelUser(new HibernateEntityModelUser(User.class, u.getId( { �...@override protected void onSubmit() { User u = getModelObject(); u.setPassword(DigestUtils.md5Hex(u.getPassword()); userDAO.save(u); setRedirect(true); setResponsePage(HubApplication.get().getHomePage()); } }; form.add(new Label(email)); PasswordTextField password = new PasswordTextField(password); form.add(password); PasswordTextField repeatPassword = new PasswordTextField(repeatPassword); repeatPassword.setModel(password.getModel()); form.add(repeatPassword); form.add(new EqualPasswordInputValidator(password, repeatPassword)); form.add(new SubmitLink(submitLink)); add(form); This is just one example - we see elsewhere in the logs sometimes a textfield that is setrequired(true) ends up nullpointering somewhere when saving the object. What could do this? - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Properties of model are set to NULL even though we have setRequired set to true
Hi Nino, we cannot reproduce it locally at all. Only happens in production. we have a straight forward setup - apache balancing to 2 tomcat instances - no clustering. really annoying! On Tue, Apr 6, 2010 at 3:51 PM, nino martinez wael nino.martinez.w...@gmail.com wrote: Hi Wayne I guess you've tried debugging it, so it's not a consistent error? Are you using any special web container or is wrapped somehow (like terracotta)? 2010/4/6 Wayne Pope waynemailingli...@googlemail.com: Hi, has anyone got any idea about this? I'm still 'spinning my wheels' on it. thanks for any help. On Fri, Apr 2, 2010 at 5:00 PM, Wayne Pope waynemailingli...@googlemail.com wrote: Hi, we've got several examples in our logs of properties of the model being set to null even though the textfield is set to required. I have NO idea how on earth this can happen - its just doesn't make sense - and its really frustrating me!! here's an example: Caused by: java.lang.NullPointerException at org.apache.commons.codec.digest.DigestUtils.md5(DigestUtils.java:86) at org.apache.commons.codec.digest.DigestUtils.md5Hex(DigestUtils.java:108) at hub.app.wicket.admin.ChangePasswordPage$1.onSubmit(ChangePasswordPage.java:49) at org.apache.wicket.markup.html.form.Form.delegateSubmit(Form.java:1518) ... FormUser form = new FormUser(form, new CompoundPropertyModelUser(new HibernateEntityModelUser(User.class, u.getId( { �...@override protected void onSubmit() { User u = getModelObject(); u.setPassword(DigestUtils.md5Hex(u.getPassword()); userDAO.save(u); setRedirect(true); setResponsePage(HubApplication.get().getHomePage()); } }; form.add(new Label(email)); PasswordTextField password = new PasswordTextField(password); form.add(password); PasswordTextField repeatPassword = new PasswordTextField(repeatPassword); repeatPassword.setModel(password.getModel()); form.add(repeatPassword); form.add(new EqualPasswordInputValidator(password, repeatPassword)); form.add(new SubmitLink(submitLink)); add(form); This is just one example - we see elsewhere in the logs sometimes a textfield that is setrequired(true) ends up nullpointering somewhere when saving the object. What could do this? - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Properties of model are set to NULL even though we have setRequired set to true
Hi David, thing is - we cannot reproduce it at all, so we cannot debug at all and hence we don't know where to start. I suppose we could put debugging traces in our code and the wicket code to help us understand but that doesn't feel right.. On Tue, Apr 6, 2010 at 3:58 PM, David Chang david_q_zh...@yahoo.com wrote: Hello Wayne, I understand your frustration. Recently, I got a similar case but it eventually turned out that it was my fault due to being new in Wicket. Long story short, for a dropdownchoice list with loadabledetachablemodel, I set up a load method, but in another place, I used dropdownchoice#setChoices to update the list for ajax update. This method actually changes the model, but i did not know about its impact. I spent almost a whole day to figure out why the load method did not get called again. So in your case, there MUST be a reason. Look everywhere these fields get changed. Good luck! David --- On Tue, 4/6/10, nino martinez wael nino.martinez.w...@gmail.com wrote: From: nino martinez wael nino.martinez.w...@gmail.com Subject: Re: Properties of model are set to NULL even though we have setRequired set to true To: users@wicket.apache.org Date: Tuesday, April 6, 2010, 9:51 AM Hi Wayne I guess you've tried debugging it, so it's not a consistent error? Are you using any special web container or is wrapped somehow (like terracotta)? 2010/4/6 Wayne Pope waynemailingli...@googlemail.com: Hi, has anyone got any idea about this? I'm still 'spinning my wheels' on it. thanks for any help. On Fri, Apr 2, 2010 at 5:00 PM, Wayne Pope waynemailingli...@googlemail.com wrote: Hi, we've got several examples in our logs of properties of the model being set to null even though the textfield is set to required. I have NO idea how on earth this can happen - its just doesn't make sense - and its really frustrating me!! here's an example: Caused by: java.lang.NullPointerException at org.apache.commons.codec.digest.DigestUtils.md5(DigestUtils.java:86) at org.apache.commons.codec.digest.DigestUtils.md5Hex(DigestUtils.java:108) at hub.app.wicket.admin.ChangePasswordPage$1.onSubmit(ChangePasswordPage.java:49) at org.apache.wicket.markup.html.form.Form.delegateSubmit(Form.java:1518) ... FormUser form = new FormUser(form, new CompoundPropertyModelUser(new HibernateEntityModelUser(User.class, u.getId( { �...@override protected void onSubmit() { User u = getModelObject(); u.setPassword(DigestUtils.md5Hex(u.getPassword()); userDAO.save(u); setRedirect(true); setResponsePage(HubApplication.get().getHomePage()); } }; form.add(new Label(email)); PasswordTextField password = new PasswordTextField(password); form.add(password); PasswordTextField repeatPassword = new PasswordTextField(repeatPassword); repeatPassword.setModel(password.getModel()); form.add(repeatPassword); form.add(new EqualPasswordInputValidator(password, repeatPassword)); form.add(new SubmitLink(submitLink)); add(form); This is just one example - we see elsewhere in the logs sometimes a textfield that is setrequired(true) ends up nullpointering somewhere when saving the object. What could do this? - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Properties of model are set to NULL even though we have setRequired set to true
Hi, we've got several examples in our logs of properties of the model being set to null even though the textfield is set to required. I have NO idea how on earth this can happen - its just doesn't make sense - and its really frustrating me!! here's an example: Caused by: java.lang.NullPointerException at org.apache.commons.codec.digest.DigestUtils.md5(DigestUtils.java:86) at org.apache.commons.codec.digest.DigestUtils.md5Hex(DigestUtils.java:108) at hub.app.wicket.admin.ChangePasswordPage$1.onSubmit(ChangePasswordPage.java:49) at org.apache.wicket.markup.html.form.Form.delegateSubmit(Form.java:1518) ... FormUser form = new FormUser(form, new CompoundPropertyModelUser(new HibernateEntityModelUser(User.class, u.getId( { @Override protected void onSubmit() { User u = getModelObject(); u.setPassword(DigestUtils.md5Hex(u.getPassword()); userDAO.save(u); setRedirect(true); setResponsePage(HubApplication.get().getHomePage()); } }; form.add(new Label(email)); PasswordTextField password = new PasswordTextField(password); form.add(password); PasswordTextField repeatPassword = new PasswordTextField(repeatPassword); repeatPassword.setModel(password.getModel()); form.add(repeatPassword); form.add(new EqualPasswordInputValidator(password, repeatPassword)); form.add(new SubmitLink(submitLink)); add(form); This is just one example - we see elsewhere in the logs sometimes a textfield that is setrequired(true) ends up nullpointering somewhere when saving the object. What could do this? - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: PageExpiredException - getting this when the session hasn't timeout
Well as far as I know the default balancer in apache supports this yes. On Mon, Mar 29, 2010 at 2:22 PM, Martijn Dashorst martijn.dasho...@gmail.com wrote: Are you using sticky sessions? Martijn On Fri, Mar 26, 2010 at 5:15 PM, Wayne Pope waynemailingli...@googlemail.com wrote: One more bit of info - it was a ajax request that caused this. Any ideas? On Fri, Mar 26, 2010 at 3:42 PM, Wayne Pope waynemailingli...@gmail.com wrote: oh and I doubled check that all the classes implement Serializable Wayne Pope-2 wrote: Hi, we're getting this exception in production sometimes, and today I experienced it first hand. We have a session of 60 mins set in the web.xml - however I got this after just 5 mins: org.apache.wicket.protocol.http.PageExpiredException: Cannot find the rendered page in session [pagemap=null,componentPath=1,versionNumber=0] at org.apache.wicket.protocol.http.WebRequestCycleProcessor.resolve(WebRequestCycleProcessor.java:197) at hub.app.wicket.app.HubRequestCycleProcessor.resolve(HubRequestCycleProcessor.java:137) at org.apache.wicket.RequestCycle.step(RequestCycle.java:1301) at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1419) at org.apache.wicket.RequestCycle.request(RequestCycle.java:545) at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:456) at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:289) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at com.wideplay.warp.persist.PersistenceFilter$3.run(PersistenceFilter.java:141) at com.wideplay.warp.persist.internal.Lifecycles.failEarlyAndLeaveNoOneBehind(Lifecycles.java:29) at com.wideplay.warp.persist.PersistenceFilter.doFilter(PersistenceFilter.java:155) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293) at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:190) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:291) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:769) at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:698) at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.java:891) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:690) at java.lang.Thread.run(Thread.java:619) I honestly don't know where this is coming from. What can cause this? cookie not being passed? apache proxy balancer not working? Has anyone experienced this? PS HubRequestCycleProcessor is just calling WebRequestCycleProcessor - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- View this message in context: http://old.nabble.com/PageExpiredException---getting-this-when-the-session-hasn%27t-timeout-tp28043403p28043436.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- Become a Wicket expert, learn from the best: http://wicketinaction.com Apache Wicket 1.4 increases type safety for web applications Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.4.4 - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: PageExpiredException - getting this when the session hasn't timeout
Hi Richard my mistake we have the following setting: ProxyPass / balancer://cluster/ stickysession=JSESSIONID nofailover=Off This problem happens from time to time in production with no pattern that we can find. We have a 'shared' firewall that hosts the SSL cert, going to the apache instance which balances to 2 tomcat instances. I know its happening as I've experienced it myself but there seems no reason for it. We're using cookie sessions rather than url On Wed, Mar 31, 2010 at 2:51 PM, Richard Wilkinson richardjohnwilkin...@googlemail.com wrote: Hi Wayne, As far as I know mod_proxy_balancer does not have sticky sessions on by default, you have to tell it what cookie to use. Am am assuming that you have multiple tomcats (or similar) behind apache, are you using any sort of session replication for them? Does this exception occur when you go directly to tomcat (or whatever you are using) and bypass apache, if so then it indicates a different problem. -- Regards - Richard Wilkinson Developer, jWeekend: OO Java Technologies - Development and Training http://jWeekend.com On 31 March 2010 13:28, Wayne Pope waynemailingli...@googlemail.com wrote: Well as far as I know the default balancer in apache supports this yes. On Mon, Mar 29, 2010 at 2:22 PM, Martijn Dashorst martijn.dasho...@gmail.com wrote: Are you using sticky sessions? Martijn On Fri, Mar 26, 2010 at 5:15 PM, Wayne Pope waynemailingli...@googlemail.com wrote: One more bit of info - it was a ajax request that caused this. Any ideas? On Fri, Mar 26, 2010 at 3:42 PM, Wayne Pope waynemailingli...@gmail.com wrote: oh and I doubled check that all the classes implement Serializable Wayne Pope-2 wrote: Hi, we're getting this exception in production sometimes, and today I experienced it first hand. We have a session of 60 mins set in the web.xml - however I got this after just 5 mins: org.apache.wicket.protocol.http.PageExpiredException: Cannot find the rendered page in session [pagemap=null,componentPath=1,versionNumber=0] at org.apache.wicket.protocol.http.WebRequestCycleProcessor.resolve(WebRequestCycleProcessor.java:197) at hub.app.wicket.app.HubRequestCycleProcessor.resolve(HubRequestCycleProcessor.java:137) at org.apache.wicket.RequestCycle.step(RequestCycle.java:1301) at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1419) at org.apache.wicket.RequestCycle.request(RequestCycle.java:545) at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:456) at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:289) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at com.wideplay.warp.persist.PersistenceFilter$3.run(PersistenceFilter.java:141) at com.wideplay.warp.persist.internal.Lifecycles.failEarlyAndLeaveNoOneBehind(Lifecycles.java:29) at com.wideplay.warp.persist.PersistenceFilter.doFilter(PersistenceFilter.java:155) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293) at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:190) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:291) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:769) at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:698) at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.java:891) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:690) at java.lang.Thread.run(Thread.java:619) I honestly don't know where this is coming from. What can cause this? cookie not being passed? apache proxy balancer not working? Has anyone experienced this? PS HubRequestCycleProcessor is just calling WebRequestCycleProcessor - To unsubscribe, e-mail: users
Re: PageExpiredException - getting this when the session hasn't timeout
Hi Martin, I think we can confidently say that its not a serialization issue as its a very simple component/panel that is used a lot. The pageexpiredexception I experience on this component was the first time we'd seen it. We see these exceptions seemlying randomly in the production logs. On Wed, Mar 31, 2010 at 3:29 PM, Martijn Dashorst martijn.dasho...@gmail.com wrote: Not only all the classes need to implement Serializable, but their properties need to be serializable as well... public class MyFoo implements Serializable { private Connection connection = ... } is not completely serializable martijn On Fri, Mar 26, 2010 at 3:42 PM, Wayne Pope waynemailingli...@gmail.com wrote: oh and I doubled check that all the classes implement Serializable Wayne Pope-2 wrote: Hi, we're getting this exception in production sometimes, and today I experienced it first hand. We have a session of 60 mins set in the web.xml - however I got this after just 5 mins: org.apache.wicket.protocol.http.PageExpiredException: Cannot find the rendered page in session [pagemap=null,componentPath=1,versionNumber=0] at org.apache.wicket.protocol.http.WebRequestCycleProcessor.resolve(WebRequestCycleProcessor.java:197) at hub.app.wicket.app.HubRequestCycleProcessor.resolve(HubRequestCycleProcessor.java:137) at org.apache.wicket.RequestCycle.step(RequestCycle.java:1301) at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1419) at org.apache.wicket.RequestCycle.request(RequestCycle.java:545) at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:456) at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:289) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at com.wideplay.warp.persist.PersistenceFilter$3.run(PersistenceFilter.java:141) at com.wideplay.warp.persist.internal.Lifecycles.failEarlyAndLeaveNoOneBehind(Lifecycles.java:29) at com.wideplay.warp.persist.PersistenceFilter.doFilter(PersistenceFilter.java:155) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293) at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:190) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:291) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:769) at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:698) at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.java:891) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:690) at java.lang.Thread.run(Thread.java:619) I honestly don't know where this is coming from. What can cause this? cookie not being passed? apache proxy balancer not working? Has anyone experienced this? PS HubRequestCycleProcessor is just calling WebRequestCycleProcessor - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- View this message in context: http://old.nabble.com/PageExpiredException---getting-this-when-the-session-hasn%27t-timeout-tp28043403p28043436.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- Become a Wicket expert, learn from the best: http://wicketinaction.com Apache Wicket 1.4 increases type safety for web applications Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.4.4 - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
Re: PageExpiredException - getting this when the session hasn't timeout
Hi Richard, thanks for the reply. I'll have a look at trying to make the failover fail again - but the last time we tested it was working fine so unless there is a core problem with the apache balancer and tomcat I don't know what I can do. There are probably other reasons why you might see a page expired exception, for example if you access so many pages after the page you get the exception on that it is it pushed out of the page map, but unless you can reproduce it by going directly a single tomcat instance, it is probably down to the clustering. Problem is I cannot reproduce it at all (and I have tried for quite some time now). Can you explain a little more: if you access so many pages after the page you get the exception on that it is it pushed out of the page map, Do you mean if we have 2 tabs open , and on one I move around the pages then go back to the first tab and try and do something? On Wed, Mar 31, 2010 at 3:26 PM, Richard Wilkinson richardjohnwilkin...@googlemail.com wrote: Ok, If you can replicate the problem by the following: 1) shutting down tomcat 1, therefore ensuring that you go to tomcat 2, 2) going to a page on your site (that has some ajax on there), 3) starting up tomcat 1, then shutting down tomcat 2, therefore ensuring that the next request goes to tomcat 1, 4) then make an ajax request on the current page. If you see the page expired then, it probably indicates that your tomcat session clustering is either is not working correctly, or that you don't have any clustering in place. Either of these problems will mean that sessions are not shared to the other tomcat. So whenever apache decides not to obey the sticky sessions (which it can do if it cannot access the tomcat it wants to access) your users session (and pagemap) will not be accessible, so you will see the page expired exception. You can also replicate this by making apache do 'round robin' clustering since then you are pretty sure that requests will be fired to different boxes. If this is the problem, it will affect all users using your site at the time (ie they will all experience the exception), so you may want to try and test away from production if this is a problem for you. There are probably other reasons why you might see a page expired exception, for example if you access so many pages after the page you get the exception on that it is it pushed out of the page map, but unless you can reproduce it by going directly a single tomcat instance, it is probably down to the clustering. Hope that helps. -- Regards - Richard Wilkinson Developer, jWeekend: OO Java Technologies - Development and Training http://jWeekend.com On 31 March 2010 14:04, Wayne Pope waynemailingli...@googlemail.com wrote: Hi Richard my mistake we have the following setting: ProxyPass / balancer://cluster/ stickysession=JSESSIONID nofailover=Off This problem happens from time to time in production with no pattern that we can find. We have a 'shared' firewall that hosts the SSL cert, going to the apache instance which balances to 2 tomcat instances. I know its happening as I've experienced it myself but there seems no reason for it. We're using cookie sessions rather than url On Wed, Mar 31, 2010 at 2:51 PM, Richard Wilkinson richardjohnwilkin...@googlemail.com wrote: Hi Wayne, As far as I know mod_proxy_balancer does not have sticky sessions on by default, you have to tell it what cookie to use. Am am assuming that you have multiple tomcats (or similar) behind apache, are you using any sort of session replication for them? Does this exception occur when you go directly to tomcat (or whatever you are using) and bypass apache, if so then it indicates a different problem. -- Regards - Richard Wilkinson Developer, jWeekend: OO Java Technologies - Development and Training http://jWeekend.com On 31 March 2010 13:28, Wayne Pope waynemailingli...@googlemail.com wrote: Well as far as I know the default balancer in apache supports this yes. On Mon, Mar 29, 2010 at 2:22 PM, Martijn Dashorst martijn.dasho...@gmail.com wrote: Are you using sticky sessions? Martijn On Fri, Mar 26, 2010 at 5:15 PM, Wayne Pope waynemailingli...@googlemail.com wrote: One more bit of info - it was a ajax request that caused this. Any ideas? On Fri, Mar 26, 2010 at 3:42 PM, Wayne Pope waynemailingli...@gmail.com wrote: oh and I doubled check that all the classes implement Serializable Wayne Pope-2 wrote: Hi, we're getting this exception in production sometimes, and today I experienced it first hand. We have a session of 60 mins set in the web.xml - however I got this after just 5 mins: org.apache.wicket.protocol.http.PageExpiredException: Cannot find the rendered page in session [pagemap=null,componentPath=1,versionNumber=0
Re: PageExpiredException - getting this when the session hasn't timeout
Thanks for the explanation Richard. We do have setAutomaticMultiWindowSupport set to false, because when we had it set to true we had some problems (I cannot remember what exactly - something to do with url mounting I think). Thing is when I experienced this issue I only had one tab open - it may explain some of the other similar exceptions in the log though. We're using the default SecondLevelCacheSessionStore. the plot thickens! On Wed, Mar 31, 2010 at 4:22 PM, Richard Wilkinson richardjohnwilkin...@googlemail.com wrote: Hi, Ok, anyone else please correct me if i am wrong, but afaik: The pagemap holds a finite number of pages in it, each time you access a new page it gets added to the page map, how many pages it holds depends on which implementation of page map you are using, which usually depends on which type of session store you are using, but usually pages are evicted from the page map on a least recently used basis. If you had 2 tabs open, did a load of stuff on one tab, then went back to the other, it is quite possible the page in the other tab will have been removed from the page map. However wicket should by default try and detect that a new tab is open, and give the other tab a different page map, but this is not completely reliable. Also this can be turned off (application.getPageSettings().setAutomaticMultiWindowSupport(false); i think), which maybe you have done. -- Regards - Richard Wilkinson Developer, jWeekend: OO Java Technologies - Development and Training http://jWeekend.com On 31 March 2010 15:02, Wayne Pope waynemailingli...@googlemail.com wrote: Hi Richard, thanks for the reply. I'll have a look at trying to make the failover fail again - but the last time we tested it was working fine so unless there is a core problem with the apache balancer and tomcat I don't know what I can do. There are probably other reasons why you might see a page expired exception, for example if you access so many pages after the page you get the exception on that it is it pushed out of the page map, but unless you can reproduce it by going directly a single tomcat instance, it is probably down to the clustering. Problem is I cannot reproduce it at all (and I have tried for quite some time now). Can you explain a little more: if you access so many pages after the page you get the exception on that it is it pushed out of the page map, Do you mean if we have 2 tabs open , and on one I move around the pages then go back to the first tab and try and do something? On Wed, Mar 31, 2010 at 3:26 PM, Richard Wilkinson richardjohnwilkin...@googlemail.com wrote: Ok, If you can replicate the problem by the following: 1) shutting down tomcat 1, therefore ensuring that you go to tomcat 2, 2) going to a page on your site (that has some ajax on there), 3) starting up tomcat 1, then shutting down tomcat 2, therefore ensuring that the next request goes to tomcat 1, 4) then make an ajax request on the current page. If you see the page expired then, it probably indicates that your tomcat session clustering is either is not working correctly, or that you don't have any clustering in place. Either of these problems will mean that sessions are not shared to the other tomcat. So whenever apache decides not to obey the sticky sessions (which it can do if it cannot access the tomcat it wants to access) your users session (and pagemap) will not be accessible, so you will see the page expired exception. You can also replicate this by making apache do 'round robin' clustering since then you are pretty sure that requests will be fired to different boxes. If this is the problem, it will affect all users using your site at the time (ie they will all experience the exception), so you may want to try and test away from production if this is a problem for you. There are probably other reasons why you might see a page expired exception, for example if you access so many pages after the page you get the exception on that it is it pushed out of the page map, but unless you can reproduce it by going directly a single tomcat instance, it is probably down to the clustering. Hope that helps. -- Regards - Richard Wilkinson Developer, jWeekend: OO Java Technologies - Development and Training http://jWeekend.com On 31 March 2010 14:04, Wayne Pope waynemailingli...@googlemail.com wrote: Hi Richard my mistake we have the following setting: ProxyPass / balancer://cluster/ stickysession=JSESSIONID nofailover=Off This problem happens from time to time in production with no pattern that we can find. We have a 'shared' firewall that hosts the SSL cert, going to the apache instance which balances to 2 tomcat instances. I know its happening as I've experienced it myself but there seems no reason for it. We're using cookie sessions rather than url On Wed
Re: PageExpiredException - getting this when the session hasn't timeout
I don't believe that this DiskPageStore is clustered, because it is an actual file on the machine. If this is the case then although the current page will be clustered by tomcat, the previous pages wont be, so wont be available on the other machine. This could cause the exception you are seeing. Thanks Richard that was REALLY helpful - I think this could well be the issue - I had no idea about this and now I think about it I'm kicking myself. I have a look into this to try and understand it and do some searches On Wed, Mar 31, 2010 at 5:02 PM, Richard Wilkinson richardjohnwilkin...@googlemail.com wrote: afaik, the default SecondLevelCacheSessionStore works by keeping the current page in session (in memory) and uses DiskPageStore as its second level cache, which stores all the other pages in a file on disk. I don't believe that this DiskPageStore is clustered, because it is an actual file on the machine. If this is the case then although the current page will be clustered by tomcat, the previous pages wont be, so wont be available on the other machine. This could cause the exception you are seeing. However that is about the limit of my knowledge on the subject, and maybe now the DiskPageStore is clusterable. When I have done clustering in the past I used a custom session store. Also I remember reading that you have to tell tomcat not to keep session attributes serialized after replication for it to work correctly see [1], (although that is a few years old) [1] - http://old.nabble.com/A-few-clustering-questions-td16993201.html -- Regards - Richard Wilkinson Developer, jWeekend: OO Java Technologies - Development and Training http://jWeekend.com On 31 March 2010 15:40, Wayne Pope waynemailingli...@googlemail.com wrote: Thanks for the explanation Richard. We do have setAutomaticMultiWindowSupport set to false, because when we had it set to true we had some problems (I cannot remember what exactly - something to do with url mounting I think). Thing is when I experienced this issue I only had one tab open - it may explain some of the other similar exceptions in the log though. We're using the default SecondLevelCacheSessionStore. the plot thickens! On Wed, Mar 31, 2010 at 4:22 PM, Richard Wilkinson richardjohnwilkin...@googlemail.com wrote: Hi, Ok, anyone else please correct me if i am wrong, but afaik: The pagemap holds a finite number of pages in it, each time you access a new page it gets added to the page map, how many pages it holds depends on which implementation of page map you are using, which usually depends on which type of session store you are using, but usually pages are evicted from the page map on a least recently used basis. If you had 2 tabs open, did a load of stuff on one tab, then went back to the other, it is quite possible the page in the other tab will have been removed from the page map. However wicket should by default try and detect that a new tab is open, and give the other tab a different page map, but this is not completely reliable. Also this can be turned off (application.getPageSettings().setAutomaticMultiWindowSupport(false); i think), which maybe you have done. -- Regards - Richard Wilkinson Developer, jWeekend: OO Java Technologies - Development and Training http://jWeekend.com On 31 March 2010 15:02, Wayne Pope waynemailingli...@googlemail.com wrote: Hi Richard, thanks for the reply. I'll have a look at trying to make the failover fail again - but the last time we tested it was working fine so unless there is a core problem with the apache balancer and tomcat I don't know what I can do. There are probably other reasons why you might see a page expired exception, for example if you access so many pages after the page you get the exception on that it is it pushed out of the page map, but unless you can reproduce it by going directly a single tomcat instance, it is probably down to the clustering. Problem is I cannot reproduce it at all (and I have tried for quite some time now). Can you explain a little more: if you access so many pages after the page you get the exception on that it is it pushed out of the page map, Do you mean if we have 2 tabs open , and on one I move around the pages then go back to the first tab and try and do something? On Wed, Mar 31, 2010 at 3:26 PM, Richard Wilkinson richardjohnwilkin...@googlemail.com wrote: Ok, If you can replicate the problem by the following: 1) shutting down tomcat 1, therefore ensuring that you go to tomcat 2, 2) going to a page on your site (that has some ajax on there), 3) starting up tomcat 1, then shutting down tomcat 2, therefore ensuring that the next request goes to tomcat 1, 4) then make an ajax request on the current page. If you see the page expired then, it probably indicates that your tomcat
Re: PageExpiredException - getting this when the session hasn't timeout
Actually - to be clear - we have 2 tomcat instances on the same machine, but I don't see this being the issue. So back to the drawing board again :-( On Wed, Mar 31, 2010 at 6:27 PM, Richard Wilkinson richardjohnwilkin...@googlemail.com wrote: OK, so so long as all cluster machines are running, they will all have the same contents in their DiskPageMap, and you should never see the exception, however, if one machine goes down for a bit, any pages visited during that time will not be transferred to it when it comes back up, meaning that the DiskPageMaps can get out of sync. -- Regards - Richard Wilkinson Developer, jWeekend: OO Java Technologies - Development and Training http://jWeekend.com On 31 March 2010 16:14, Martijn Dashorst martijn.dasho...@gmail.com wrote: The last page is kept in the session such that it is transferred across the cluster. Each node in the cluster should then update the local pagestore with that page. Matej has written quite a bit about this behavior on this list, so searching might help. Martijn On Wed, Mar 31, 2010 at 5:02 PM, Richard Wilkinson richardjohnwilkin...@googlemail.com wrote: afaik, the default SecondLevelCacheSessionStore works by keeping the current page in session (in memory) and uses DiskPageStore as its second level cache, which stores all the other pages in a file on disk. I don't believe that this DiskPageStore is clustered, because it is an actual file on the machine. If this is the case then although the current page will be clustered by tomcat, the previous pages wont be, so wont be available on the other machine. This could cause the exception you are seeing. However that is about the limit of my knowledge on the subject, and maybe now the DiskPageStore is clusterable. When I have done clustering in the past I used a custom session store. Also I remember reading that you have to tell tomcat not to keep session attributes serialized after replication for it to work correctly see [1], (although that is a few years old) [1] - http://old.nabble.com/A-few-clustering-questions-td16993201.html -- Regards - Richard Wilkinson Developer, jWeekend: OO Java Technologies - Development and Training http://jWeekend.com On 31 March 2010 15:40, Wayne Pope waynemailingli...@googlemail.com wrote: Thanks for the explanation Richard. We do have setAutomaticMultiWindowSupport set to false, because when we had it set to true we had some problems (I cannot remember what exactly - something to do with url mounting I think). Thing is when I experienced this issue I only had one tab open - it may explain some of the other similar exceptions in the log though. We're using the default SecondLevelCacheSessionStore. the plot thickens! On Wed, Mar 31, 2010 at 4:22 PM, Richard Wilkinson richardjohnwilkin...@googlemail.com wrote: Hi, Ok, anyone else please correct me if i am wrong, but afaik: The pagemap holds a finite number of pages in it, each time you access a new page it gets added to the page map, how many pages it holds depends on which implementation of page map you are using, which usually depends on which type of session store you are using, but usually pages are evicted from the page map on a least recently used basis. If you had 2 tabs open, did a load of stuff on one tab, then went back to the other, it is quite possible the page in the other tab will have been removed from the page map. However wicket should by default try and detect that a new tab is open, and give the other tab a different page map, but this is not completely reliable. Also this can be turned off (application.getPageSettings().setAutomaticMultiWindowSupport(false); i think), which maybe you have done. -- Regards - Richard Wilkinson Developer, jWeekend: OO Java Technologies - Development and Training http://jWeekend.com On 31 March 2010 15:02, Wayne Pope waynemailingli...@googlemail.com wrote: Hi Richard, thanks for the reply. I'll have a look at trying to make the failover fail again - but the last time we tested it was working fine so unless there is a core problem with the apache balancer and tomcat I don't know what I can do. There are probably other reasons why you might see a page expired exception, for example if you access so many pages after the page you get the exception on that it is it pushed out of the page map, but unless you can reproduce it by going directly a single tomcat instance, it is probably down to the clustering. Problem is I cannot reproduce it at all (and I have tried for quite some time now). Can you explain a little more: if you access so many pages after the page you get the exception on that it is it pushed out of the page map, Do you mean if we have 2 tabs open
PageExpiredException - getting this when the session hasn't timeout
Hi, we're getting this exception in production sometimes, and today I experienced it first hand. We have a session of 60 mins set in the web.xml - however I got this after just 5 mins: org.apache.wicket.protocol.http.PageExpiredException: Cannot find the rendered page in session [pagemap=null,componentPath=1,versionNumber=0] at org.apache.wicket.protocol.http.WebRequestCycleProcessor.resolve(WebRequestCycleProcessor.java:197) at hub.app.wicket.app.HubRequestCycleProcessor.resolve(HubRequestCycleProcessor.java:137) at org.apache.wicket.RequestCycle.step(RequestCycle.java:1301) at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1419) at org.apache.wicket.RequestCycle.request(RequestCycle.java:545) at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:456) at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:289) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at com.wideplay.warp.persist.PersistenceFilter$3.run(PersistenceFilter.java:141) at com.wideplay.warp.persist.internal.Lifecycles.failEarlyAndLeaveNoOneBehind(Lifecycles.java:29) at com.wideplay.warp.persist.PersistenceFilter.doFilter(PersistenceFilter.java:155) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293) at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:190) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:291) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:769) at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:698) at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.java:891) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:690) at java.lang.Thread.run(Thread.java:619) I honestly don't know where this is coming from. What can cause this? cookie not being passed? apache proxy balancer not working? Has anyone experienced this? PS HubRequestCycleProcessor is just calling WebRequestCycleProcessor - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: PageExpiredException - getting this when the session hasn't timeout
oh and I doubled check that all the classes implement Serializable Wayne Pope-2 wrote: Hi, we're getting this exception in production sometimes, and today I experienced it first hand. We have a session of 60 mins set in the web.xml - however I got this after just 5 mins: org.apache.wicket.protocol.http.PageExpiredException: Cannot find the rendered page in session [pagemap=null,componentPath=1,versionNumber=0] at org.apache.wicket.protocol.http.WebRequestCycleProcessor.resolve(WebRequestCycleProcessor.java:197) at hub.app.wicket.app.HubRequestCycleProcessor.resolve(HubRequestCycleProcessor.java:137) at org.apache.wicket.RequestCycle.step(RequestCycle.java:1301) at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1419) at org.apache.wicket.RequestCycle.request(RequestCycle.java:545) at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:456) at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:289) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at com.wideplay.warp.persist.PersistenceFilter$3.run(PersistenceFilter.java:141) at com.wideplay.warp.persist.internal.Lifecycles.failEarlyAndLeaveNoOneBehind(Lifecycles.java:29) at com.wideplay.warp.persist.PersistenceFilter.doFilter(PersistenceFilter.java:155) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293) at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:190) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:291) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:769) at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:698) at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.java:891) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:690) at java.lang.Thread.run(Thread.java:619) I honestly don't know where this is coming from. What can cause this? cookie not being passed? apache proxy balancer not working? Has anyone experienced this? PS HubRequestCycleProcessor is just calling WebRequestCycleProcessor - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- View this message in context: http://old.nabble.com/PageExpiredException---getting-this-when-the-session-hasn%27t-timeout-tp28043403p28043436.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: PageExpiredException - getting this when the session hasn't timeout
One more bit of info - it was a ajax request that caused this. Any ideas? On Fri, Mar 26, 2010 at 3:42 PM, Wayne Pope waynemailingli...@gmail.com wrote: oh and I doubled check that all the classes implement Serializable Wayne Pope-2 wrote: Hi, we're getting this exception in production sometimes, and today I experienced it first hand. We have a session of 60 mins set in the web.xml - however I got this after just 5 mins: org.apache.wicket.protocol.http.PageExpiredException: Cannot find the rendered page in session [pagemap=null,componentPath=1,versionNumber=0] at org.apache.wicket.protocol.http.WebRequestCycleProcessor.resolve(WebRequestCycleProcessor.java:197) at hub.app.wicket.app.HubRequestCycleProcessor.resolve(HubRequestCycleProcessor.java:137) at org.apache.wicket.RequestCycle.step(RequestCycle.java:1301) at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1419) at org.apache.wicket.RequestCycle.request(RequestCycle.java:545) at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:456) at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:289) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at com.wideplay.warp.persist.PersistenceFilter$3.run(PersistenceFilter.java:141) at com.wideplay.warp.persist.internal.Lifecycles.failEarlyAndLeaveNoOneBehind(Lifecycles.java:29) at com.wideplay.warp.persist.PersistenceFilter.doFilter(PersistenceFilter.java:155) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293) at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:190) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:291) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:769) at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:698) at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.java:891) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:690) at java.lang.Thread.run(Thread.java:619) I honestly don't know where this is coming from. What can cause this? cookie not being passed? apache proxy balancer not working? Has anyone experienced this? PS HubRequestCycleProcessor is just calling WebRequestCycleProcessor - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- View this message in context: http://old.nabble.com/PageExpiredException---getting-this-when-the-session-hasn%27t-timeout-tp28043403p28043436.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Only render javascript once per request?
Hi, I been looking how to solve this and I cannot see a clear way. Basically in a given page we have a list of TextField derived classes that use a JQuery auto complete. This means for each textfield rendered on the page we render in the head something like: $(document).ready(function(){var data = ['Sitemap', 'vbmbmnvbmn', 'second', 'communications', 'test', 'Wayne', 'Wireframes', 'fook', 'business case', 'Logos', 'round 1', 'layout', 'Marketing', 'new one', 'graphics', 'hot stuff', 'Accounts', 'Template']; $('#labels390').autocomplete(data, { multiple: true, multipleSeparator: ', ', scroll: true, scrollHeight: 300 })}) $(document).ready(function(){var data = ['Sitemap', 'vbmbmnvbmn', 'second', 'communications', 'test', 'Wayne', 'Wireframes', 'fook', 'business case', 'Logos', 'round 1', 'layout', 'Marketing', 'new one', 'graphics', 'hot stuff', 'Accounts', 'Template']; $('#labels391').autocomplete(data, { multiple: true, multipleSeparator: ', ', scroll: true, scrollHeight: 300 })}) $(document).ready(function(){var data = ['Sitemap', 'vbmbmnvbmn', 'second', 'communications', 'test', 'Wayne', 'Wireframes', 'fook', 'business case', 'Logos', 'round 1', 'layout', 'Marketing', 'new one', 'graphics', 'hot stuff', 'Accounts', 'Template']; $('#labels392').autocomplete(data, { multiple: true, multipleSeparator: ', ', scroll: true, scrollHeight: 300 })}) etc.. As you can clearly see this isn't too efficient and I want to set the data array only once and then attach the autocomplete to the textfield and the data. In the renderhead of the textfield derived class is there anyway to somehow only render the data part once per request? (this also massively reduces the db calls to create the list!) thanks for any pointers Wayne - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
AjaxSubmitLink + setResponsePage = feedback message problem on new page
Hello all, Ok I cannot figure this one out. I have a Page that contains a Form with a AjaxSubmitLink: AjaxSubmitLink submitLink= new AjaxSubmitLink(submitLink) { @Override protected void onSubmit(AjaxRequestTarget target, Form? form) { info(getString(admin.paymentSuccesfull)); setResponsePage(Application.get().getHomePage()); } @Override protected void onError(AjaxRequestTarget target, Form? form) { target.addComponent(feedback); } }; On the home page I have a Panel that contains a FeedbackPanel - this feedback panel works fine when using elements on that page. However when submitting the form and displaying the home page I get the message in the logs: Component-targetted feedback message was left unrendered. This could be because you are missing a FeedbackPanel on the page. Message: [FeedbackMessage message = ... And the message is not displayed. Any ideas why wicket cannot find the feedback panel in the page? (its definitely there in a Panel) feedback panel is added as such: FeedbackPanel feedback = new FeedbackPanel(feedbackPanel); add(feedback); many thanks Wayne - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: AjaxSubmitLink + setResponsePage = feedback message problem on new page
thanks for the explanation. Works perfect now. much appreciated. On Wed, Jan 27, 2010 at 8:23 PM, Igor Vaynberg igor.vaynb...@gmail.com wrote: the former -igor On Wed, Jan 27, 2010 at 10:45 AM, Riyad Kalla rka...@gmail.com wrote: Igor, will FeedbackPanel correctly consume the messages from the session scope and remove them -- or do you have to manually remove them once they've been rendered? On Wed, Jan 27, 2010 at 11:42 AM, Igor Vaynberg igor.vaynb...@gmail.comwrote: the problem is that there is a redirect between your calling info() and the feedback panel rendering. this is because thats the only way to do it in ajax - issue a window.location=... if you are doing feedback messages across requests then use getsession().info(...) -igor On Wed, Jan 27, 2010 at 10:15 AM, Wayne Pope waynemailingli...@googlemail.com wrote: Hello all, Ok I cannot figure this one out. I have a Page that contains a Form with a AjaxSubmitLink: AjaxSubmitLink submitLink= new AjaxSubmitLink(submitLink) { �...@override protected void onSubmit(AjaxRequestTarget target, Form? form) { info(getString(admin.paymentSuccesfull)); setResponsePage(Application.get().getHomePage()); } �...@override protected void onError(AjaxRequestTarget target, Form? form) { target.addComponent(feedback); } }; On the home page I have a Panel that contains a FeedbackPanel - this feedback panel works fine when using elements on that page. However when submitting the form and displaying the home page I get the message in the logs: Component-targetted feedback message was left unrendered. This could be because you are missing a FeedbackPanel on the page. Message: [FeedbackMessage message = ... And the message is not displayed. Any ideas why wicket cannot find the feedback panel in the page? (its definitely there in a Panel) feedback panel is added as such: FeedbackPanel feedback = new FeedbackPanel(feedbackPanel); add(feedback); many thanks Wayne - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
I feel silly asking this
Ok , I think I must have a brain block or something. Basically how do you localize the submit input on a form with having to add a Button? Currently we have a fairly large number of forms in the applicaiton that just the default form onSubmit and we just add something like: input type=submit value=Save/ to the html. Do we need to add Buttons to all our pages or is there a way to specify in our application properties files what the default value should be for submits? many thanks - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: I feel silly asking this
of course the attribute ! ah monday mornings. thanks everyone! On Mon, Jan 11, 2010 at 1:00 PM, Jonas barney...@gmail.com wrote: have a look at http://cwiki.apache.org/WICKET/wickets-xhtml-tags.html section 'Attribute wicket:message' On Mon, Jan 11, 2010 at 12:56 PM, Wayne Pope waynemailingli...@googlemail.com wrote: Ok , I think I must have a brain block or something. Basically how do you localize the submit input on a form with having to add a Button? Currently we have a fairly large number of forms in the applicaiton that just the default form onSubmit and we just add something like: input type=submit value=Save/ to the html. Do we need to add Buttons to all our pages or is there a way to specify in our application properties files what the default value should be for submits? many thanks - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: UploadWebRequest is actually a UploadWebRequest$MultipartRequest
ok where should I log it? On Fri, Nov 20, 2009 at 7:22 PM, Igor Vaynberg igor.vaynb...@gmail.com wrote: looks like a bug. -igor On Fri, Nov 20, 2009 at 8:55 AM, Wayne Pope waynemailingli...@googlemail.com wrote: Hello, we get the following warning in our logs: (UploadProgressBar.java:106) - UploadProgressBar will not work without an UploadWebRequest. See the javadoc for details. We do override in the application: @Override protected WebRequest newWebRequest(javax.servlet.http.HttpServletRequest servletRequest) { return new UploadWebRequest(servletRequest); }; When I debug UploadProgressBar I see that: if (!(RequestCycle.get().getRequest() instanceof UploadWebRequest)) { log.warn(UploadProgressBar will not work without an UploadWebRequest. See the javadoc for details.); } However RequestCycle.get().getRequest() is returning a UploadWebRequest$MultipartRequest instance. What are we doing wrong or is this a bug? thanks - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
PageExpiredException: Cannot find the rendered page in session
Hi, we're seeing a few of these in production of late. I however cannot reproduce them locally at the moment. We're using wicket rc7. Any ideas? 2009-11-20 13:43:09,170 ERROR - hub.app.wicket.app.HubWebRequestCycle.onRuntimeException(HubWebRequestCycle.java:72) 72 HubWebRequestCycle - Runtime Exception! org.apache.wicket.protocol.http.PageExpiredException: Cannot find the rendered page in session [pagemap=wicket-2,componentPath=20,versionNumber=0] at org.apache.wicket.protocol.http.WebRequestCycleProcessor.resolve(WebRequestCycleProcessor.java:190) at hub.app.wicket.app.HubRequestCycleProcessor.resolve(HubRequestCycleProcessor.java:137) at org.apache.wicket.RequestCycle.step(RequestCycle.java:1252) at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1370) at org.apache.wicket.RequestCycle.request(RequestCycle.java:501) at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:455) at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:288) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at com.wideplay.warp.persist.PersistenceFilter$3.run(PersistenceFilter.java:141) at com.wideplay.warp.persist.internal.Lifecycles.failEarlyAndLeaveNoOneBehind(Lifecycles.java:29) at com.wideplay.warp.persist.PersistenceFilter.doFilter(PersistenceFilter.java:155) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293) at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:190) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:291) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:769) at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:698) at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.java:891) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:690) at java.lang.Thread.run(Thread.java:619) thanks Wayne - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: PageExpiredException: Cannot find the rendered page in session
Ok I just want to clarify that if we get: [pagemap=null,componentPath=20,versionNumber=0] pagemap null thats not a problem? thanks On Fri, Nov 20, 2009 at 5:16 PM, Igor Vaynberg igor.vaynb...@gmail.com wrote: its a regular page expired exception... -igor On Fri, Nov 20, 2009 at 4:49 AM, Wayne Pope waynemailingli...@googlemail.com wrote: Hi, we're seeing a few of these in production of late. I however cannot reproduce them locally at the moment. We're using wicket rc7. Any ideas? 2009-11-20 13:43:09,170 ERROR - hub.app.wicket.app.HubWebRequestCycle.onRuntimeException(HubWebRequestCycle.java:72) 72 HubWebRequestCycle - Runtime Exception! org.apache.wicket.protocol.http.PageExpiredException: Cannot find the rendered page in session [pagemap=wicket-2,componentPath=20,versionNumber=0] at org.apache.wicket.protocol.http.WebRequestCycleProcessor.resolve(WebRequestCycleProcessor.java:190) at hub.app.wicket.app.HubRequestCycleProcessor.resolve(HubRequestCycleProcessor.java:137) at org.apache.wicket.RequestCycle.step(RequestCycle.java:1252) at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1370) at org.apache.wicket.RequestCycle.request(RequestCycle.java:501) at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:455) at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:288) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at com.wideplay.warp.persist.PersistenceFilter$3.run(PersistenceFilter.java:141) at com.wideplay.warp.persist.internal.Lifecycles.failEarlyAndLeaveNoOneBehind(Lifecycles.java:29) at com.wideplay.warp.persist.PersistenceFilter.doFilter(PersistenceFilter.java:155) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293) at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:190) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:291) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:769) at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:698) at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.java:891) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:690) at java.lang.Thread.run(Thread.java:619) thanks Wayne - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
UploadWebRequest is actually a UploadWebRequest$MultipartRequest
Hello, we get the following warning in our logs: (UploadProgressBar.java:106) - UploadProgressBar will not work without an UploadWebRequest. See the javadoc for details. We do override in the application: @Override protected WebRequest newWebRequest(javax.servlet.http.HttpServletRequest servletRequest) { return new UploadWebRequest(servletRequest); }; When I debug UploadProgressBar I see that: if (!(RequestCycle.get().getRequest() instanceof UploadWebRequest)) { log.warn(UploadProgressBar will not work without an UploadWebRequest. See the javadoc for details.); } However RequestCycle.get().getRequest() is returning a UploadWebRequest$MultipartRequest instance. What are we doing wrong or is this a bug? thanks - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: PageExpiredException: Cannot find the rendered page in session
thanks IIja and Igor :-) On Fri, Nov 20, 2009 at 5:54 PM, Ilja Pavkovic ilja.pavko...@binaere-bauten.de wrote: Hi, Ok I just want to clarify that if we get: [pagemap=null,componentPath=20,versionNumber=0] pagemap null thats not a problem? pagemap with name null indicates the default pagemap. Everything is fine :) Best Regards, Ilja Pavkovic -- binaere bauten gmbh · tempelhofer ufer 1a · 10961 berlin +49 · 171 · 9342 465 Handelsregister: HRB 115854 - Amtsgericht Charlottenburg Geschäftsführer: Dipl.-Inform. Ilja Pavkovic, Dipl.-Inform. Jost Becker - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
How can I disable a IFormValidator?
Hello, I have a form that has a AbstractFormValidator added to it. This does some validation on a couple of formcomponents. However in some situations on of the components is not visible and we get the warming: IFormValidator in form `formContainer:form` depends on a component that has been removed from the page or is no longer visible. How can I diable the AbstractFormValidator so that we don't get this warning? (as it doesn't need validating). many thanks Wayne - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
WebRequestCycle is creating a HTTP 400/Bad request
Hi, firstly I'm sure this is something we are doing wrong here and is not an issue with wicket however we're lost as to what to do to solve it. We have a page mounted like this: mount(new MixedParamUrlCodingStrategy(/cube/todos, WhichTaskPage.class,. We then request this page: http://locolhost:8080/cube/todos/1/116 In the constructor of WhichTaskPage with throw a RestartResponseAtInterceptPageException (and I have tried just using setResponsePage) to another page. Now in WebRequestCycle.redirectTo(final Page page) the line: redirectUrl = page.urlFor(IRedirectListener.INTERFACE).toString(); creates the following url: ../../../?wicket:interface=:13 further up the call stack Jetty/Tomcat returns a HTTP 302 with the location: http://localhost:8080/../../../?wicket:interface=:13 Now the issue: Firefox seems to be smart enough to then request the following url (I'm using a the sniffer call fiddler for this): GET /?wicket:interface=:3 HTTP/1.1 this resolves and works fine. However Internet Explorer does what its asked and redirect to: GET /../../../?wicket:interface=:3 HTTP/1.1 This url does exists and Tomcat/Jetty returns HTTP 400 This is effecting all our IE users and we're in a bit of a panic as how to solve it. Any ideas? many thanks Wayne - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Fwd: RestartResponseAtInterceptPageException causing odd problem with IE
Last go - any ideas ? thanks -- Forwarded message -- From: Wayne Pope waynemailingli...@googlemail.com Date: Thu, Oct 8, 2009 at 5:17 PM Subject: RestartResponseAtInterceptPageException causing odd problem with IE To: users@wicket.apache.org Hi, something we've run across with users using IE - basically if they try and access a page they do not have RENDER permission a UnauthorizedActionException gets thrown. This in turn (when I set through wicket 1.4-rc6) throws a RestartResponseAtInterceptPageException with a AccessDeniedPage that we set in the application. Not this works no problem is all browser except IE. In IE we get a HTTP 400 bad request. If we refresh the browser the page displays correctly. I have no idea why this is happening. Has anyone seen this or can give me some pointers on how to fix this? many thanks Wayne - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
RestartResponseAtInterceptPageException causing odd problem with IE
Hi, something we've run across with users using IE - basically if they try and access a page they do not have RENDER permission a UnauthorizedActionException gets thrown. This in turn (when I set through wicket 1.4-rc6) throws a RestartResponseAtInterceptPageException with a AccessDeniedPage that we set in the application. Not this works no problem is all browser except IE. In IE we get a HTTP 400 bad request. If we refresh the browser the page displays correctly. I have no idea why this is happening. Has anyone seen this or can give me some pointers on how to fix this? many thanks Wayne - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
AJAX and Safari
Hi, not sure how to investigate this, but we have an issue with ajax and safari. Problem is it doesn't happen every time - only about 40% . Essentally we send a request: Request Accept text/xml Content-Typeapplication/x-www-form-urlencoded Referer http://foo1.glasscubesdev.com:8080/?wicket:interface=:5 User-Agent Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US) AppleWebKit/525.19 (KHTML, like Gecko) Version/3.1.2 Safari/525.21 Wicket-Ajax true We receive this on the server/eclipse and the request is processed. However the response is received like this on safari (using the developer menu): Response Ajax-Location ?wicket:interface=:5 Content-Length 1 Server Jetty(6.1.4) As you can see the content length is 1. The effect is that it appears that request never returns (there's nothing in the ajax debug window). It happens locally and on the server. We're on 1.4-rc2 of wicket. Any ideas? Anyone seen something like this before? many thanks Wayne - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: AJAX and Safari
Sorry I just realised that its not ajax - just a normal form submit. We still have the same problem though Wayne Pope-2 wrote: Hi, not sure how to investigate this, but we have an issue with ajax and safari. Problem is it doesn't happen every time - only about 40% . Essentally we send a request: Request Accepttext/xml Content-Type application/x-www-form-urlencoded Referer http://foo1.glasscubesdev.com:8080/?wicket:interface=:5 User-AgentMozilla/5.0 (Windows; U; Windows NT 6.0; en-US) AppleWebKit/525.19 (KHTML, like Gecko) Version/3.1.2 Safari/525.21 Wicket-Ajax true We receive this on the server/eclipse and the request is processed. However the response is received like this on safari (using the developer menu): Response Ajax-Location ?wicket:interface=:5 Content-Length1 ServerJetty(6.1.4) As you can see the content length is 1. The effect is that it appears that request never returns (there's nothing in the ajax debug window). It happens locally and on the server. We're on 1.4-rc2 of wicket. Any ideas? Anyone seen something like this before? many thanks Wayne - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- View this message in context: http://www.nabble.com/AJAX-and-Safari-tp24145113p24145166.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: AJAX and Safari
It looks like we are using an AjaxButton. Sorry for 2 emails to describe the one problem. Any ideas? many thanks On Mon, Jun 22, 2009 at 12:49 PM, Wayne Popewaynemailingli...@gmail.com wrote: Sorry I just realised that its not ajax - just a normal form submit. We still have the same problem though Wayne Pope-2 wrote: Hi, not sure how to investigate this, but we have an issue with ajax and safari. Problem is it doesn't happen every time - only about 40% . Essentally we send a request: Request Accept text/xml Content-Type application/x-www-form-urlencoded Referer http://foo1.glasscubesdev.com:8080/?wicket:interface=:5 User-Agent Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US) AppleWebKit/525.19 (KHTML, like Gecko) Version/3.1.2 Safari/525.21 Wicket-Ajax true We receive this on the server/eclipse and the request is processed. However the response is received like this on safari (using the developer menu): Response Ajax-Location ?wicket:interface=:5 Content-Length 1 Server Jetty(6.1.4) As you can see the content length is 1. The effect is that it appears that request never returns (there's nothing in the ajax debug window). It happens locally and on the server. We're on 1.4-rc2 of wicket. Any ideas? Anyone seen something like this before? many thanks Wayne - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- View this message in context: http://www.nabble.com/AJAX-and-Safari-tp24145113p24145166.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: AJAX and Safari
Yes sorry - apologies to all. I'll have a look Martin. On Mon, Jun 22, 2009 at 1:11 PM, Martin Funkmafulaf...@googlemail.com wrote: uh, now that's a moving target. sorry but no solution out of my head, but next steps for me would be checking if it happens on the server or on its way to the browser. What does the response Buffer in the WicketFilter look like just before the doGet returns? mf Am 22.06.2009 um 12:58 schrieb Wayne Pope: It looks like we are using an AjaxButton. Sorry for 2 emails to describe the one problem. Any ideas? many thanks On Mon, Jun 22, 2009 at 12:49 PM, Wayne Popewaynemailingli...@gmail.com wrote: Sorry I just realised that its not ajax - just a normal form submit. We still have the same problem though Wayne Pope-2 wrote: Hi, not sure how to investigate this, but we have an issue with ajax and safari. Problem is it doesn't happen every time - only about 40% . Essentally we send a request: Request Accept text/xml Content-Type application/x-www-form-urlencoded Referer http://foo1.glasscubesdev.com:8080/?wicket:interface=:5 User-Agent Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US) AppleWebKit/525.19 (KHTML, like Gecko) Version/3.1.2 Safari/525.21 Wicket-Ajax true We receive this on the server/eclipse and the request is processed. However the response is received like this on safari (using the developer menu): Response Ajax-Location ?wicket:interface=:5 Content-Length 1 Server Jetty(6.1.4) As you can see the content length is 1. The effect is that it appears that request never returns (there's nothing in the ajax debug window). It happens locally and on the server. We're on 1.4-rc2 of wicket. Any ideas? Anyone seen something like this before? many thanks Wayne - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- View this message in context: http://www.nabble.com/AJAX-and-Safari-tp24145113p24145166.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: AJAX and Safari
The buffer is empty. I see from the request the querystring is wicket:interface=:7:projectPagePanel:toolBox2:inviteUserPanel:hiddenArea:invitePanel:inviteForm:inviteButton::IActivePageBehaviorListener:0:wicket:ignoreIfNotActive=truerandom=0.2301371863577515 the response is a http 200 adn ther redirectURL is set to ?wicket:interface=:7 - not sure if this is relavent. If I can the button to a norml button (not an AjaxButton) it works fine. Looks like I will need to do this. On Mon, Jun 22, 2009 at 1:29 PM, Wayne Popewaynemailingli...@googlemail.com wrote: Yes sorry - apologies to all. I'll have a look Martin. On Mon, Jun 22, 2009 at 1:11 PM, Martin Funkmafulaf...@googlemail.com wrote: uh, now that's a moving target. sorry but no solution out of my head, but next steps for me would be checking if it happens on the server or on its way to the browser. What does the response Buffer in the WicketFilter look like just before the doGet returns? mf Am 22.06.2009 um 12:58 schrieb Wayne Pope: It looks like we are using an AjaxButton. Sorry for 2 emails to describe the one problem. Any ideas? many thanks On Mon, Jun 22, 2009 at 12:49 PM, Wayne Popewaynemailingli...@gmail.com wrote: Sorry I just realised that its not ajax - just a normal form submit. We still have the same problem though Wayne Pope-2 wrote: Hi, not sure how to investigate this, but we have an issue with ajax and safari. Problem is it doesn't happen every time - only about 40% . Essentally we send a request: Request Accept text/xml Content-Type application/x-www-form-urlencoded Referer http://foo1.glasscubesdev.com:8080/?wicket:interface=:5 User-Agent Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US) AppleWebKit/525.19 (KHTML, like Gecko) Version/3.1.2 Safari/525.21 Wicket-Ajax true We receive this on the server/eclipse and the request is processed. However the response is received like this on safari (using the developer menu): Response Ajax-Location ?wicket:interface=:5 Content-Length 1 Server Jetty(6.1.4) As you can see the content length is 1. The effect is that it appears that request never returns (there's nothing in the ajax debug window). It happens locally and on the server. We're on 1.4-rc2 of wicket. Any ideas? Anyone seen something like this before? many thanks Wayne - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- View this message in context: http://www.nabble.com/AJAX-and-Safari-tp24145113p24145166.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Wicket Job offer
PLEASE REPLY TO ME DIRECTLY - NOT THE USER GROUP! Web 2.0 startup based in Nice/Monaco in the south of France seeks top developer to join their small team. English working environment. Skills: Java, Apache Wicket, Hibernate (annotations), Guice, XHTML, CSS, javascript, Agile/SCRUM, Linux skills, ant bash, maven. Experience 3+ years. If you contribute to open source projects this will be a bonus. Must be motivated and interested in all Web applications, developments and open source frameworks and projects. You must have excellent design and OO , being able to product clean simple code, and not work from examples. The ability to figure out quickly how a new technology/framework is imperative. Must be comfortable working in a SCRUM environment - ie transparency on your code, and daily updates of progress. Bonus skills: Open source contributions, design interests, usability experience, Lucerne search engine/library, The company based in Monaco/Nice area will shortly be launching an online social Web application targeted at SME's. You will be joining just before this period and be expected to pick up quickly from the current code and base and become 100% responsible for the platform and code base including all architecture, design, and contribute to the discussions on future developments/direction of the product. You'll also be responsible for production troubleshooting and scalability. This role is for someone will all round skills and you'll need to be flexible and work on new items at short notice. This is a small company of only 4 people so you must be part of the team and be motivated to work in this type of environment. This role can turn into a long term position for someone motivated to contribute and be part of the company and will reap the rewards. The person who fills this role needs a passion for Internet based technologies and Web sites, knowledge and interest in Web based sites, applications, design , usability, new trends and ways of working on the net. Please send you CV to me. We need someone on the ground here unfortunalty, not working remotely at this time. thanks Wayne - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Custom wicket:tags?
Hi, is it possible to develop our own custom wicket tag(s)? Anyone done this, or have any pointers? thanks - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Custom wicket:tags?
thanks guys On Mon, Mar 9, 2009 at 3:52 PM, Jeremy Thomerson jer...@wickettraining.com wrote: Look at AutoLinkResolver and see how to build one - you can basically auto-magically handle any kind of tag any way you want to. -- Jeremy Thomerson http://www.wickettraining.com On Mon, Mar 9, 2009 at 4:58 AM, Wayne Pope waynemailingli...@googlemail.com wrote: Hi, is it possible to develop our own custom wicket tag(s)? Anyone done this, or have any pointers? thanks - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Using RequestCycle outside of a http request
Hi, We have some Bookmarkable pages that display some given content. I would like to email these links out to a set of users. We have a set of classes that knows how to build the good bookmarkable link depending on the content. Now this works all fine and good. However we need to move the email sending aspect to a batch/thread (for daily updates). I would like create the bookmarkable link the same way and call toString() to get the good URL. However I get an exception about not running inside a request/application. Is it possible to create a new RequestCycle outside of a request (it doesn't appear so) or is there any other way of creating the link aside from hand coding/crafting them? thanks for any pointers Wayne www.glasscubes.com - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Using RequestCycle outside of a http request
ok thanks Jeremy On Fri, Mar 6, 2009 at 5:28 PM, Jeremy Thomerson jer...@wickettraining.com wrote: Search the mail list - there's a lot of examples of this. Basically, you'll need to use WicketTester - it will set up a mock request cycle, etc. for you. -- Jeremy Thomerson http://www.wickettraining.com On Fri, Mar 6, 2009 at 10:03 AM, Wayne Pope waynemailingli...@googlemail.com wrote: Hi, We have some Bookmarkable pages that display some given content. I would like to email these links out to a set of users. We have a set of classes that knows how to build the good bookmarkable link depending on the content. Now this works all fine and good. However we need to move the email sending aspect to a batch/thread (for daily updates). I would like create the bookmarkable link the same way and call toString() to get the good URL. However I get an exception about not running inside a request/application. Is it possible to create a new RequestCycle outside of a request (it doesn't appear so) or is there any other way of creating the link aside from hand coding/crafting them? thanks for any pointers Wayne www.glasscubes.com - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: How to deal with IE bug/feature 'return form submit' in Wicket?
Hi Jeremy, thanks very much for helping. I went with the first suggestion which seems to work fine. The code is essentially now: = new Form() { add(new AjaxButton() { void onSubmit() { if(!form.isSubmitted()) { onSubmit(); } } void onSubmit() { IRequestTarget iTarget = RequestCycle.get().getRequestTarget(); AjaxRequestTarget target= null; if (iTarget instanceof AjaxRequestTarget) { target = (AjaxRequestTarget) iTarget; } //logic.. } } Looks like I'm going to have to go through all our forms and apply this pattern where we have ajaxbuttons or ajaxlinks. thanks On Wed, Feb 25, 2009 at 7:47 PM, Jeremy Thomerson jer...@wickettraining.com wrote: Actually, thinking a little more - rather than disabling the return key, could you do something like this in JS (pseudo code): form onsubmit=ajaxSubmitButton.submit(); return false; blah blah blah /form Then when the return key was pressed, the form would submit, and if they have JS, it will use the ajaxsubmitbutton and stop the normal form submission? And if they don't have JS, it will just work as a normal form. -- Jeremy Thomerson http://www.wickettraining.com On Wed, Feb 25, 2009 at 12:45 PM, Jeremy Thomerson jer...@wickettraining.com wrote: This probably isn't the best way, but you could possibly move all of your onSubmit code to the form's on submit, including the request target stuff. Just do RequestCycle.get().getRequestTarget() (or there maybe AjaxRequestTarget.get() - I can't remember). That's not a true fix but at least it gets rid of the duplicate code issue. Someone else may have a suggestion on how to do a real fix. -- Jeremy Thomerson http://www.wickettraining.com On Wed, Feb 25, 2009 at 11:57 AM, Wayne Pope waynemailingli...@googlemail.com wrote: Hi, I have a form that has a single text field and an ajax button. In FF when I click on the button or hit return key the onSumit of the ajaxButton is called. In IE when I click on the button the onSubmit of the ajaxButton is called. However In IE (as you may know) if I hit the return key it submits the form and the form's onSubmit method is be called instead of the ajaxButton so the page just refreshes. If I add the onSubmit to the form, in FF if I click on the button , first the onSubmit of the form is called, then the ajaxButton onSubmit, and we end up with double the submits Aside from disabling the return key via javascript - not really an option as its just bad usability for us - any suggestions on how to handle this in a more elegant way? For the moment I've used form.isSubmitted() in the ajaxButton onSubmit, but it means I have to duplicate some of the code between the 2 onSubmits to control ajaxrequestTarget . thanks Wayne www.glasscubes.com - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: How to deal with IE bug/feature 'return form submit' in Wicket?
Just looking through some of our forms and this isn;t going to work where we have 2 ajaxbuttons in the same form. I suppose we'll need to separate the forms or something now. On Thu, Feb 26, 2009 at 9:06 AM, Wayne Pope waynemailingli...@googlemail.com wrote: Hi Jeremy, thanks very much for helping. I went with the first suggestion which seems to work fine. The code is essentially now: = new Form() { add(new AjaxButton() { void onSubmit() { if(!form.isSubmitted()) { onSubmit(); } } void onSubmit() { IRequestTarget iTarget = RequestCycle.get().getRequestTarget(); AjaxRequestTarget target= null; if (iTarget instanceof AjaxRequestTarget) { target = (AjaxRequestTarget) iTarget; } //logic.. } } Looks like I'm going to have to go through all our forms and apply this pattern where we have ajaxbuttons or ajaxlinks. thanks On Wed, Feb 25, 2009 at 7:47 PM, Jeremy Thomerson jer...@wickettraining.com wrote: Actually, thinking a little more - rather than disabling the return key, could you do something like this in JS (pseudo code): form onsubmit=ajaxSubmitButton.submit(); return false; blah blah blah /form Then when the return key was pressed, the form would submit, and if they have JS, it will use the ajaxsubmitbutton and stop the normal form submission? And if they don't have JS, it will just work as a normal form. -- Jeremy Thomerson http://www.wickettraining.com On Wed, Feb 25, 2009 at 12:45 PM, Jeremy Thomerson jer...@wickettraining.com wrote: This probably isn't the best way, but you could possibly move all of your onSubmit code to the form's on submit, including the request target stuff. Just do RequestCycle.get().getRequestTarget() (or there maybe AjaxRequestTarget.get() - I can't remember). That's not a true fix but at least it gets rid of the duplicate code issue. Someone else may have a suggestion on how to do a real fix. -- Jeremy Thomerson http://www.wickettraining.com On Wed, Feb 25, 2009 at 11:57 AM, Wayne Pope waynemailingli...@googlemail.com wrote: Hi, I have a form that has a single text field and an ajax button. In FF when I click on the button or hit return key the onSumit of the ajaxButton is called. In IE when I click on the button the onSubmit of the ajaxButton is called. However In IE (as you may know) if I hit the return key it submits the form and the form's onSubmit method is be called instead of the ajaxButton so the page just refreshes. If I add the onSubmit to the form, in FF if I click on the button , first the onSubmit of the form is called, then the ajaxButton onSubmit, and we end up with double the submits Aside from disabling the return key via javascript - not really an option as its just bad usability for us - any suggestions on how to handle this in a more elegant way? For the moment I've used form.isSubmitted() in the ajaxButton onSubmit, but it means I have to duplicate some of the code between the 2 onSubmits to control ajaxrequestTarget . thanks Wayne www.glasscubes.com - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Wicket Security Question
Hi, In terms of SWARM etc its in the pre-generics stage. It didn't take much to get it working with the latest wicket version mind. It works fine, however it wan't what we needed in the end - we went with the wicket.aurthorization package and rolled our own dynamic acl-list/roles etc. I had some promising converstions with Les Hazlewood from jsecurity.org - that looks like another great package and more flexible IMO. However Les was right in the middle of a move to NYC and didn't have anytime to spend on doing a wicket version of jsecurity. It might be worth pinging him a mail and see if he up for doing it again. Wayne www.glasscubes.com On Thu, Feb 26, 2009 at 8:09 PM, Nino Martinez nino.martinez.w...@gmail.com wrote: I might pick it up (But since it's not something I need right now, it has low priority).. But was hoping that Wayne Pope would get back and tell whats state it is in.. Philippe Laflamme wrote: FYI: it's not clear what will happen with the wicket-security package. The original maintainer sadly passed away last year and no-one has officially taken the torch. We've used both packages (auth-roles and swarm), but neither with spring-security. We'd like to move to using spring-security using Swarm, but we haven't taken any step in this regard due to the package's situation... Hoping the package gets an official maintainer soon. Philippe Markus Strickler wrote: Hi- http://wicketstuff.org/confluence/display/STUFFWIKI/Security+Framework+Comparison might be of interest. I've been using Auth-roles together with ACEGI in a project and it worked quite well. -markus Am 25.02.2009 um 21:23 schrieb M Goodell: I would like to pose a question. We are looking at using Wicket as a platform for an upcoming project. So far we are *really* liking what Wicket brings to the table. In terms of security / securing a web application our first thought was Spring Security. My question: Does Spring Security play nice with Wicket and is it a viable addition to a Wicket Application? Or, what are other alternatives are available for use to investigate. Thank you in advance for any thoughts, comments and suggestions. M. Goodell -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
How to deal with IE bug/feature 'return form submit' in Wicket?
Hi, I have a form that has a single text field and an ajax button. In FF when I click on the button or hit return key the onSumit of the ajaxButton is called. In IE when I click on the button the onSubmit of the ajaxButton is called. However In IE (as you may know) if I hit the return key it submits the form and the form's onSubmit method is be called instead of the ajaxButton so the page just refreshes. If I add the onSubmit to the form, in FF if I click on the button , first the onSubmit of the form is called, then the ajaxButton onSubmit, and we end up with double the submits Aside from disabling the return key via javascript - not really an option as its just bad usability for us - any suggestions on how to handle this in a more elegant way? For the moment I've used form.isSubmitted() in the ajaxButton onSubmit, but it means I have to duplicate some of the code between the 2 onSubmits to control ajaxrequestTarget . thanks Wayne www.glasscubes.com - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
subdomains and setting up WebSession
Hi, I need to be able to map urls like: foo.myapp.com foo2.myapp.com woo.myapp.com etc.. and be able to have a parameter in my session (say a String) set to either foo, foo2, woo, etc These subdomains are database driven and therefore I don't want to add any subdomains hardcoded to web.xml or apache . I was thinking about doing a mod rewrite in apache and either appending an extra parameter or mapping to something like: /webappurl/foo /webappurl/foo2 /webappurl/woo and then (by majic!) be able to pick this up in the wicket session. Anyone got any idea's on how I could go about this? I did think about adding another servlet filter and setting some threadlocal variable, but this doesn't feel right. many thanks - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: subdomains and setting up WebSession
Hi Martin, basically I need subdomains to map to a context within the application. For example if you have a application that has several customers, I want to have a separate subdomain for each customer: william.myapp.com jo.myapp.com sarah.myapp.com I'd like 'william' to always see his URLS like: http://william.myapp.com/?wicket:interface=:4 However in the application I need to figure out that I'm in the 'william' context, so i can serve williams content only. On Mon, Feb 23, 2009 at 5:00 PM, Martin Makundi martin.maku...@koodaripalvelut.com wrote: I think you can see the request ulr root by calling ((WebRequest)RequestCycle.get().getRequest()).getRequestURL() Is that what you want? ** Martin 2009/2/23 Wayne Pope waynemailingli...@googlemail.com: Hi, I need to be able to map urls like: foo.myapp.com foo2.myapp.com woo.myapp.com etc.. and be able to have a parameter in my session (say a String) set to either foo, foo2, woo, etc These subdomains are database driven and therefore I don't want to add any subdomains hardcoded to web.xml or apache . I was thinking about doing a mod rewrite in apache and either appending an extra parameter or mapping to something like: /webappurl/foo /webappurl/foo2 /webappurl/woo and then (by majic!) be able to pick this up in the wicket session. Anyone got any idea's on how I could go about this? I did think about adding another servlet filter and setting some threadlocal variable, but this doesn't feel right. many thanks - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: subdomains and setting up WebSession
Hi Nino, thanks for that. I wasn't aware that I can get apache to append a cookie. I've done things in the past using mod-rewrite like: Redirect subdomain.example.org/path to www.example.org/subdomain/path Which directive are you using? On Mon, Feb 23, 2009 at 5:17 PM, Nino Martinez nino.martinez.w...@gmail.com wrote: Hi Wayne Thats exactly what I've done with my traningslog.dk and exerciselog.eu , both are pointing at the same app...I just used apache http to append a special cookie containing the domain.. There are several ways of doing this with apache http.. I did this since I am running several apps on the same tomcat so I need some logic in front of tomcat anyhow.. regards Nino Wayne Pope wrote: Hi Martin, basically I need subdomains to map to a context within the application. For example if you have a application that has several customers, I want to have a separate subdomain for each customer: william.myapp.com jo.myapp.com sarah.myapp.com I'd like 'william' to always see his URLS like: http://william.myapp.com/?wicket:interface=:4 However in the application I need to figure out that I'm in the 'william' context, so i can serve williams content only. On Mon, Feb 23, 2009 at 5:00 PM, Martin Makundi martin.maku...@koodaripalvelut.com wrote: I think you can see the request ulr root by calling ((WebRequest)RequestCycle.get().getRequest()).getRequestURL() Is that what you want? ** Martin 2009/2/23 Wayne Pope waynemailingli...@googlemail.com: Hi, I need to be able to map urls like: foo.myapp.com foo2.myapp.com woo.myapp.com etc.. and be able to have a parameter in my session (say a String) set to either foo, foo2, woo, etc These subdomains are database driven and therefore I don't want to add any subdomains hardcoded to web.xml or apache . I was thinking about doing a mod rewrite in apache and either appending an extra parameter or mapping to something like: /webappurl/foo /webappurl/foo2 /webappurl/woo and then (by majic!) be able to pick this up in the wicket session. Anyone got any idea's on how I could go about this? I did think about adding another servlet filter and setting some threadlocal variable, but this doesn't feel right. many thanks - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: subdomains and setting up WebSession
ok thanks Martin, I'll give it a go On Mon, Feb 23, 2009 at 5:27 PM, Martin Makundi martin.maku...@koodaripalvelut.com wrote: ((WebRequest)RequestCycle.get().getRequest()).getRequestURL() should work for you. ** Martin 2009/2/23 Wayne Pope waynemailingli...@googlemail.com: Hi Martin, basically I need subdomains to map to a context within the application. For example if you have a application that has several customers, I want to have a separate subdomain for each customer: william.myapp.com jo.myapp.com sarah.myapp.com I'd like 'william' to always see his URLS like: http://william.myapp.com/?wicket:interface=:4 However in the application I need to figure out that I'm in the 'william' context, so i can serve williams content only. On Mon, Feb 23, 2009 at 5:00 PM, Martin Makundi martin.maku...@koodaripalvelut.com wrote: I think you can see the request ulr root by calling ((WebRequest)RequestCycle.get().getRequest()).getRequestURL() Is that what you want? ** Martin 2009/2/23 Wayne Pope waynemailingli...@googlemail.com: Hi, I need to be able to map urls like: foo.myapp.com foo2.myapp.com woo.myapp.com etc.. and be able to have a parameter in my session (say a String) set to either foo, foo2, woo, etc These subdomains are database driven and therefore I don't want to add any subdomains hardcoded to web.xml or apache . I was thinking about doing a mod rewrite in apache and either appending an extra parameter or mapping to something like: /webappurl/foo /webappurl/foo2 /webappurl/woo and then (by majic!) be able to pick this up in the wicket session. Anyone got any idea's on how I could go about this? I did think about adding another servlet filter and setting some threadlocal variable, but this doesn't feel right. many thanks - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Using AbstractDefaultAjaxBehavior on a Bookmarkable page?
Hi, when I use an AbstractDefaultAjaxBehavior on a Bookmarkable page I get a : org.apache.wicket.protocol.http.PageExpiredException: Cannot find the rendered page in session [pagemap=null,componentPath=37,versionNumber=0] However if the AbstractDefaultAjaxBehavior is on a none nookmarkable page it works fine. Is this normal? thanks - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Using AbstractDefaultAjaxBehavior on a Bookmarkable page?
Ok I figured out the issue (I have a quick start if you want) The problem occures if you add a AbstractDefaultAjaxBehavior to a Page. If its a component it works fine. Wayne www.glasscubes.com On Tue, Jan 20, 2009 at 4:17 PM, Igor Vaynberg igor.vaynb...@gmail.com wrote: no, it is not normal. please provide a quickstart. -igor On Tue, Jan 20, 2009 at 4:20 AM, Wayne Pope waynemailingli...@googlemail.com wrote: Hi, when I use an AbstractDefaultAjaxBehavior on a Bookmarkable page I get a : org.apache.wicket.protocol.http.PageExpiredException: Cannot find the rendered page in session [pagemap=null,componentPath=37,versionNumber=0] However if the AbstractDefaultAjaxBehavior is on a none nookmarkable page it works fine. Is this normal? thanks - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: [OT] wicket users around the world
Brit, working down here in france with the original Mr Francisco T, on an uber web2.0 app. ;-) Ah monday morning, back to technical things... On Mon, Dec 15, 2008 at 8:01 AM, Juri Prokofjev proj...@gmail.com wrote: Estonia, Tallinn I've tried many frameworks, but wicket is one of my favorite. On Mon, Dec 15, 2008 at 8:39 AM, Ashika Umanga Umagiliya auma...@biggjapan.com wrote: Sri Lankan ,working in Japan Kathmandu, Nepal - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- http://www.autoladu.ee - kõik varuosad ühes kohas - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: passing list from java class to javascript
definitly json. On Thu, Dec 11, 2008 at 10:29 AM, KAN [EMAIL PROTECTED] wrote: http://json.org/ ? 2008/12/11 Ashis [EMAIL PROTECTED]: Hello all, I have a question i need to pass list from java class to javascript. How can i do this stuff? Thanks -- View this message in context: http://www.nabble.com/passing-list-from-java-class-to-javascript-tp20949804p20949804.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- WBR, kan. - 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: Looking for the previous thread about pagingnavigator with infinite pages
not sure if this is the one you mean - it was titled : Is there any other way? DataProviders must hit the Db twice On Wed, Dec 3, 2008 at 3:41 PM, Serkan Camurcuoglu [EMAIL PROTECTED] wrote: Hi all, Sorry for disturbing but I remember I've read a discussion about implementing a paging navigator for an unknown (possibly infinite) number of pages in the list recently, but I haven't been able to find it on Nabble. Can somebody send me the link of this thread if you can find or remember the original discussion? Best regards, SerkanC - 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: Is there any other way? DataProviders must hit the Db twice for (possible) large datasets
you mentioned that you implemented such a repeater yourself. didn't you use any navigation or did you write that yourself? just wondering. i implemented a simple prev/next pager which is all that was required or that usecase. Matej's implementation from inMethods works perfectly. I suggest you use that Stefan if you need such a thing. (Thanks Matej!) On Thu, Nov 27, 2008 at 7:51 PM, Igor Vaynberg [EMAIL PROTECTED]wrote: On Thu, Nov 27, 2008 at 10:28 AM, Stefan Fußenegger [EMAIL PROTECTED] wrote: Hi Igor, thanks for implementing this minimal version. i totally agree with your reasoning. Is there any chance though that this goes into 1.3 branch as well? I'd really appreciate that. done you mentioned that you implemented such a repeater yourself. didn't you use any navigation or did you write that yourself? just wondering. i implemented a simple prev/next pager which is all that was required for that usecase. shall i open a ticket against 1.5 to track this issue/enhancement? i added it to the wishlist wiki page. if you add a jira ticket please add the number to the wiki page. -igor best regards, stefan igor.vaynberg wrote: On Thu, Nov 27, 2008 at 12:46 AM, Stefan Fußenegger [EMAIL PROTECTED] wrote: I don't think IDataProvider is only about databases. you started off with your core assumption being wrong. idataprovider was written exclusively for accessing databases. my thinking, at the time, was that 99% of people use wicket to build applications that access databases, and i dare say it was a good guess because in its ~3 years of existence only a handful of people had a problem with the way it works. There are other data sources and some return the total amount and the desired subset at the same time (Lucene as a famous example). Such data sources would really benefit of a single-query-approach. i am not disputing this fact. i am simply saying that we are not going to fix this right now because this is not a bug. you are trying to use the components for something they were not designed to be used. in 1.5 we may address this. I faced this issue myself in a search (read Lucene) centered application. I successfully went down the road of implementing a custom repeater. i had to do the same myself. But when the repeater was working as desired, I figured out that PagingNavigationLink is the real showstopper, not IDataProvider (see my JIRA comment [0]). The fix would be rather trivial, as PagingNavigationLink is doing something it needn't do (checking the requested page against the valid range of pages). Let me answer 2 possible questions in advance: Q: Why is this check in PagingNavigationLink a problem? A: Obviously, you can't fetch size and data as long as the page isn't known. the check is there because we code defensively. we do not assume that every implementation of ipageable will cull the number when you call setcurrentpage(x). Q: How would a custom repeater that fetches data and size at the same tame handle invalid (out of range) pages? A: Out of range pages will return the size and an empty dataset. In this case, the repeater would change the page number to the last valid and do a second query. Yeah, two queries again. But this should only happen rarely though. this will change the existing behavior. if you are on page 5 and click page 10 (which happens to not exist) you would end up back on 5 with your suggestion where as currently you would properly end up on 9. looking at WICKET-1784, i extracted the code you want into an overridable int cullPageNumber(int x). so feel free to subclass the link and override that to return x without any extra checks. we may properly fix this in 1.5, but for right now this is too big a refactor because it changes the basic assumptions with which the code was written. -igor Best regards, Stefan [0] https://issues.apache.org/jira/browse/WICKET-1784?focusedCommentId=12651278#action_12651278 igor.vaynberg wrote: On Wed, Nov 26, 2008 at 9:32 AM, Wayne Pope [EMAIL PROTECTED] wrote: so you think pushing all that extra data over the network is actually more efficient then doing another query wtf. The point is I'd rather avoid 2 calls where 1 will do. AbstractPageableView will do fine I believe. the number of calls itself is meaningless, i dont comprehend why people have a hard time understanding this simple fact. if you have one call that takes 1000ms and ten calls that each take 10ms you should concentrate on the one call that takes a long time rather then eliminating all ten 10ms calls which only saves you 100ms. if you can optimize the 1000ms and shave off 20% then your eleven calls are still faster then the one call. and since connection pools have been inventind many years ago there is no more overhead
Is there any other way? DataProviders must hit the Db twice for (possible) large datasets
Ok, I was just having a bit of code clean up and I realized that in our IDataProviders we are loading all rows for a given dataset. So looking at the iterator method I see we can limit the result (and the offset). Great I thought - however I see that that the size() method is called as part of the getViewSize() in the AbstractPageableView. Thus I need to call the database here to figure out the size. Am I doing sonething wrong or have I got to hit the database twice for each DataProvider render. Obvously I don't want to hard code a size. Is there any other way ? Thanks Wayne
Re: Is there any other way? DataProviders must hit the Db twice for (possible) large datasets
Hi, thanks for the replies. Micheal O/Hoover - I still don't see how this works as you don't have the limit and offset (that is used in Iterator). How do you know how many rows to load in your size() method? Michael S - thanks for the link - it it appears I must completely rewrite the whole pagable/provider code (not looked at the code) to get this to work? I'm sure I must be missing something still, as I can't beleive that we need to either a) load the whole data set b) call count on the Db , then load in the iterator mehod. Thats going to kill the database in prod (or really not help.) On Wed, Nov 26, 2008 at 3:58 PM, Michael Sparer [EMAIL PROTECTED]wrote: have a look at https://issues.apache.org/jira/browse/WICKET-1784 Wayne Pope-2 wrote: Ok, I was just having a bit of code clean up and I realized that in our IDataProviders we are loading all rows for a given dataset. So looking at the iterator method I see we can limit the result (and the offset). Great I thought - however I see that that the size() method is called as part of the getViewSize() in the AbstractPageableView. Thus I need to call the database here to figure out the size. Am I doing sonething wrong or have I got to hit the database twice for each DataProvider render. Obvously I don't want to hard code a size. Is there any other way ? Thanks Wayne - Michael Sparer http://talk-on-tech.blogspot.com -- View this message in context: http://www.nabble.com/Is-there-any-other-way--DataProviders-must-hit-the-Db-twice-for-%28possible%29-large-datasets-tp20701684p20702476.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Is there any other way? DataProviders must hit the Db twice for (possible) large datasets
Hi James, its not killing anything at the moment, I just don't like the idea of hitting the database with due cause. However I thinking about this some more I believe perhaps I should not use DataViews full stop - but RefreshingView instead?. Essentially I have in several places a large data set. I'm only interested in displaying say the first 10 rows. Then the user can click on load next 10 and thus display the next 'page' of results. They then have a choice of loading the next 10 or the previous 10, etc. Perhaps DataView is not really suited to this type of behaviour? more used where you want to see the number of pages a search result finds for example? If we're at the edge condition that there are exactly 20 results, when asking for the next 10, we simply disply the message 'no more results'. We just issue a count(*) query first to get the count Yes so this will be called every time the page is rendered no unless you cache as you stated, but you run the risk changing dataset? thanks Wayne On Wed, Nov 26, 2008 at 5:05 PM, James Carman [EMAIL PROTECTED]wrote: We just issue a count(*) query first to get the count. Then, we use individual queries to get each page's data. If you feel confident enough that the count won't change (or you don't really care if it does), you can cache the value returned from it the count query (I don't know how often that gets called, really). If calling the queries to get the individual page's data is killing your database, then you're doing something wrong, IMHO. On Wed, Nov 26, 2008 at 10:32 AM, Wayne Pope [EMAIL PROTECTED] wrote: Hi, thanks for the replies. Micheal O/Hoover - I still don't see how this works as you don't have the limit and offset (that is used in Iterator). How do you know how many rows to load in your size() method? Michael S - thanks for the link - it it appears I must completely rewrite the whole pagable/provider code (not looked at the code) to get this to work? I'm sure I must be missing something still, as I can't beleive that we need to either a) load the whole data set b) call count on the Db , then load in the iterator mehod. Thats going to kill the database in prod (or really not help.) On Wed, Nov 26, 2008 at 3:58 PM, Michael Sparer [EMAIL PROTECTED] wrote: have a look at https://issues.apache.org/jira/browse/WICKET-1784 Wayne Pope-2 wrote: Ok, I was just having a bit of code clean up and I realized that in our IDataProviders we are loading all rows for a given dataset. So looking at the iterator method I see we can limit the result (and the offset). Great I thought - however I see that that the size() method is called as part of the getViewSize() in the AbstractPageableView. Thus I need to call the database here to figure out the size. Am I doing sonething wrong or have I got to hit the database twice for each DataProvider render. Obvously I don't want to hard code a size. Is there any other way ? Thanks Wayne - Michael Sparer http://talk-on-tech.blogspot.com -- View this message in context: http://www.nabble.com/Is-there-any-other-way--DataProviders-must-hit-the-Db-twice-for-%28possible%29-large-datasets-tp20701684p20702476.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Is there any other way? DataProviders must hit the Db twice for (possible) large datasets
Hi Matej, The idea is always to load one row more than required on page which tells the grid if there will be a next page or not. Great idea. I looked at the code and I think I'll do my own (simplied version) of your refreashingpage. I believe thats what we really want here, as we don't care about telling the user the total amount of rows. Thanks everyone for your comments and help Wayne On Wed, Nov 26, 2008 at 5:21 PM, Matej Knopp [EMAIL PROTECTED] wrote: Hi Wayne, if you feel brave enough you can take a look at inmethod grid components (available in wicket stuff svn - http://wicket-stuff.svn.sourceforge.net/svnroot/wicket-stuff in trunk and 1.3 branch). The grid contains AbstractPageableView that can perform paging without having to know the number of rows upfront. The idea is always to load one row more than required on page which tells the grid if there will be a next page or not. -Matej On Wed, Nov 26, 2008 at 5:15 PM, Wayne Pope [EMAIL PROTECTED] wrote: Hi James, its not killing anything at the moment, I just don't like the idea of hitting the database with due cause. However I thinking about this some more I believe perhaps I should not use DataViews full stop - but RefreshingView instead?. Essentially I have in several places a large data set. I'm only interested in displaying say the first 10 rows. Then the user can click on load next 10 and thus display the next 'page' of results. They then have a choice of loading the next 10 or the previous 10, etc. Perhaps DataView is not really suited to this type of behaviour? more used where you want to see the number of pages a search result finds for example? If we're at the edge condition that there are exactly 20 results, when asking for the next 10, we simply disply the message 'no more results'. We just issue a count(*) query first to get the count Yes so this will be called every time the page is rendered no unless you cache as you stated, but you run the risk changing dataset? thanks Wayne On Wed, Nov 26, 2008 at 5:05 PM, James Carman [EMAIL PROTECTED]wrote: We just issue a count(*) query first to get the count. Then, we use individual queries to get each page's data. If you feel confident enough that the count won't change (or you don't really care if it does), you can cache the value returned from it the count query (I don't know how often that gets called, really). If calling the queries to get the individual page's data is killing your database, then you're doing something wrong, IMHO. On Wed, Nov 26, 2008 at 10:32 AM, Wayne Pope [EMAIL PROTECTED] wrote: Hi, thanks for the replies. Micheal O/Hoover - I still don't see how this works as you don't have the limit and offset (that is used in Iterator). How do you know how many rows to load in your size() method? Michael S - thanks for the link - it it appears I must completely rewrite the whole pagable/provider code (not looked at the code) to get this to work? I'm sure I must be missing something still, as I can't beleive that we need to either a) load the whole data set b) call count on the Db , then load in the iterator mehod. Thats going to kill the database in prod (or really not help.) On Wed, Nov 26, 2008 at 3:58 PM, Michael Sparer [EMAIL PROTECTED] wrote: have a look at https://issues.apache.org/jira/browse/WICKET-1784 Wayne Pope-2 wrote: Ok, I was just having a bit of code clean up and I realized that in our IDataProviders we are loading all rows for a given dataset. So looking at the iterator method I see we can limit the result (and the offset). Great I thought - however I see that that the size() method is called as part of the getViewSize() in the AbstractPageableView. Thus I need to call the database here to figure out the size. Am I doing sonething wrong or have I got to hit the database twice for each DataProvider render. Obvously I don't want to hard code a size. Is there any other way ? Thanks Wayne - Michael Sparer http://talk-on-tech.blogspot.com -- View this message in context: http://www.nabble.com/Is-there-any-other-way--DataProviders-must-hit-the-Db-twice-for-%28possible%29-large-datasets-tp20701684p20702476.html Sent from the Wicket - User mailing list archive at Nabble.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]
Re: Is there any other way? DataProviders must hit the Db twice for (possible) large datasets
Thanks Matej, I just noticed org.apache.wicket.markup.repeater.AbstractPageableViewT which seems what I'm ofter - I'll have a look and both and get something working. On Wed, Nov 26, 2008 at 5:57 PM, Matej Knopp [EMAIL PROTECTED] wrote: You can just take AbstractPageableView, IDataSource and IGridSortState from the code. It should do exactly what you want and It shouldn't have any dependencies on the rest of grids. -Matej On Wed, Nov 26, 2008 at 5:39 PM, Wayne Pope [EMAIL PROTECTED] wrote: Hi Matej, The idea is always to load one row more than required on page which tells the grid if there will be a next page or not. Great idea. I looked at the code and I think I'll do my own (simplied version) of your refreashingpage. I believe thats what we really want here, as we don't care about telling the user the total amount of rows. Thanks everyone for your comments and help Wayne On Wed, Nov 26, 2008 at 5:21 PM, Matej Knopp [EMAIL PROTECTED] wrote: Hi Wayne, if you feel brave enough you can take a look at inmethod grid components (available in wicket stuff svn - http://wicket-stuff.svn.sourceforge.net/svnroot/wicket-stuff in trunk and 1.3 branch). The grid contains AbstractPageableView that can perform paging without having to know the number of rows upfront. The idea is always to load one row more than required on page which tells the grid if there will be a next page or not. -Matej On Wed, Nov 26, 2008 at 5:15 PM, Wayne Pope [EMAIL PROTECTED] wrote: Hi James, its not killing anything at the moment, I just don't like the idea of hitting the database with due cause. However I thinking about this some more I believe perhaps I should not use DataViews full stop - but RefreshingView instead?. Essentially I have in several places a large data set. I'm only interested in displaying say the first 10 rows. Then the user can click on load next 10 and thus display the next 'page' of results. They then have a choice of loading the next 10 or the previous 10, etc. Perhaps DataView is not really suited to this type of behaviour? more used where you want to see the number of pages a search result finds for example? If we're at the edge condition that there are exactly 20 results, when asking for the next 10, we simply disply the message 'no more results'. We just issue a count(*) query first to get the count Yes so this will be called every time the page is rendered no unless you cache as you stated, but you run the risk changing dataset? thanks Wayne On Wed, Nov 26, 2008 at 5:05 PM, James Carman [EMAIL PROTECTED]wrote: We just issue a count(*) query first to get the count. Then, we use individual queries to get each page's data. If you feel confident enough that the count won't change (or you don't really care if it does), you can cache the value returned from it the count query (I don't know how often that gets called, really). If calling the queries to get the individual page's data is killing your database, then you're doing something wrong, IMHO. On Wed, Nov 26, 2008 at 10:32 AM, Wayne Pope [EMAIL PROTECTED] wrote: Hi, thanks for the replies. Micheal O/Hoover - I still don't see how this works as you don't have the limit and offset (that is used in Iterator). How do you know how many rows to load in your size() method? Michael S - thanks for the link - it it appears I must completely rewrite the whole pagable/provider code (not looked at the code) to get this to work? I'm sure I must be missing something still, as I can't beleive that we need to either a) load the whole data set b) call count on the Db , then load in the iterator mehod. Thats going to kill the database in prod (or really not help.) On Wed, Nov 26, 2008 at 3:58 PM, Michael Sparer [EMAIL PROTECTED] wrote: have a look at https://issues.apache.org/jira/browse/WICKET-1784 Wayne Pope-2 wrote: Ok, I was just having a bit of code clean up and I realized that in our IDataProviders we are loading all rows for a given dataset. So looking at the iterator method I see we can limit the result (and the offset). Great I thought - however I see that that the size() method is called as part of the getViewSize() in the AbstractPageableView. Thus I need to call the database here to figure out the size. Am I doing sonething wrong or have I got to hit the database twice for each DataProvider render. Obvously I don't want to hard code a size. Is there any other way ? Thanks Wayne - Michael Sparer http://talk-on-tech.blogspot.com -- View this message
Re: Is there any other way? DataProviders must hit the Db twice for (possible) large datasets
Hi Igor, what? why would you ever load the whole dataset? just to avoid 2 calls on smallish datasets, especially when there are multiple joins and database isnt on the same box. yeah. because select count() queries are the most expensive queries you can run on the database. you are right, its totally going to kill it. you know how all those sites on the internet that have a pager above the pageable view that shows you the number of the last available page...you know how those work without doing a select count()? Ouch. I just want to limit calls if possible to the database as waiting for i/o's is never great for scalability. I'm not 'having a go' at wicket or DataViews or anything, just trying to understand it. I never claimed to be a guru - far from it. Wayne On Wed, Nov 26, 2008 at 5:58 PM, Igor Vaynberg [EMAIL PROTECTED]wrote: On Wed, Nov 26, 2008 at 7:32 AM, Wayne Pope [EMAIL PROTECTED] wrote: I'm sure I must be missing something still, as I can't beleive that we need to either a) load the whole data set what? why would you ever load the whole dataset? b) call count on the Db , then load in the iterator mehod. Thats going to kill the database in prod (or really not help.) yeah. because select count() queries are the most expensive queries you can run on the database. you are right, its totally going to kill it. you know how all those sites on the internet that have a pager above the pageable view that shows you the number of the last available page...you know how those work without doing a select count()? -igor On Wed, Nov 26, 2008 at 3:58 PM, Michael Sparer [EMAIL PROTECTED] wrote: have a look at https://issues.apache.org/jira/browse/WICKET-1784 Wayne Pope-2 wrote: Ok, I was just having a bit of code clean up and I realized that in our IDataProviders we are loading all rows for a given dataset. So looking at the iterator method I see we can limit the result (and the offset). Great I thought - however I see that that the size() method is called as part of the getViewSize() in the AbstractPageableView. Thus I need to call the database here to figure out the size. Am I doing sonething wrong or have I got to hit the database twice for each DataProvider render. Obvously I don't want to hard code a size. Is there any other way ? Thanks Wayne - Michael Sparer http://talk-on-tech.blogspot.com -- View this message in context: http://www.nabble.com/Is-there-any-other-way--DataProviders-must-hit-the-Db-twice-for-%28possible%29-large-datasets-tp20701684p20702476.html Sent from the Wicket - User mailing list archive at Nabble.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]
Re: Is there any other way? DataProviders must hit the Db twice for (possible) large datasets
so you think pushing all that extra data over the network is actually more efficient then doing another query wtf. The point is I'd rather avoid 2 calls where 1 will do. AbstractPageableView will do fine I believe. i can only assume that you have actually profiled your app and that one select count() call was what was taking a significant chunk of processing time in the database server? to the point where eliminating it will actually reduce enough load on the database to increase your throughput? No I haven't, as mentioned before, I just want to avoid 2 calls when one will do. I have however seen several times in production systems waiting on i/o's reduces your scalability. I'd rather keep server count down as money is tight. I'll be mindfull not to ask 'stupid' questions again. On Wed, Nov 26, 2008 at 6:19 PM, Igor Vaynberg [EMAIL PROTECTED]wrote: On Wed, Nov 26, 2008 at 9:06 AM, Wayne Pope [EMAIL PROTECTED] wrote: Hi Igor, what? why would you ever load the whole dataset? just to avoid 2 calls on smallish datasets, especially when there are multiple joins and database isnt on the same box. so you think pushing all that extra data over the network is actually more efficient then doing another query wtf. yeah. because select count() queries are the most expensive queries you can run on the database. you are right, its totally going to kill it. you know how all those sites on the internet that have a pager above the pageable view that shows you the number of the last available page...you know how those work without doing a select count()? Ouch. I just want to limit calls if possible to the database as waiting for i/o's is never great for scalability. I'm not 'having a go' at wicket or DataViews or anything, just trying to understand it. I never claimed to be a guru - far from it. i can only assume that you have actually profiled your app and that one select count() call was what was taking a significant chunk of processing time in the database server? to the point where eliminating it will actually reduce enough load on the database to increase your throughput? -igor Wayne On Wed, Nov 26, 2008 at 5:58 PM, Igor Vaynberg [EMAIL PROTECTED] wrote: On Wed, Nov 26, 2008 at 7:32 AM, Wayne Pope [EMAIL PROTECTED] wrote: I'm sure I must be missing something still, as I can't beleive that we need to either a) load the whole data set what? why would you ever load the whole dataset? b) call count on the Db , then load in the iterator mehod. Thats going to kill the database in prod (or really not help.) yeah. because select count() queries are the most expensive queries you can run on the database. you are right, its totally going to kill it. you know how all those sites on the internet that have a pager above the pageable view that shows you the number of the last available page...you know how those work without doing a select count()? -igor On Wed, Nov 26, 2008 at 3:58 PM, Michael Sparer [EMAIL PROTECTED] wrote: have a look at https://issues.apache.org/jira/browse/WICKET-1784 Wayne Pope-2 wrote: Ok, I was just having a bit of code clean up and I realized that in our IDataProviders we are loading all rows for a given dataset. So looking at the iterator method I see we can limit the result (and the offset). Great I thought - however I see that that the size() method is called as part of the getViewSize() in the AbstractPageableView. Thus I need to call the database here to figure out the size. Am I doing sonething wrong or have I got to hit the database twice for each DataProvider render. Obvously I don't want to hard code a size. Is there any other way ? Thanks Wayne - Michael Sparer http://talk-on-tech.blogspot.com -- View this message in context: http://www.nabble.com/Is-there-any-other-way--DataProviders-must-hit-the-Db-twice-for-%28possible%29-large-datasets-tp20701684p20702476.html Sent from the Wicket - User mailing list archive at Nabble.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] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Is there any other way? DataProviders must hit the Db twice for (possible) large datasets
the number of calls itself is meaningless, i dont comprehend why people have a hard time understanding this simple fact. The point for me is : something like select count(*) from user user1 inner join company com1 on user1.company_id= com1.id where com1.code='dht2' - called in size() followed by select firstName,lastName from user user1 inner join company com1 on user1.company_id=com1.id where com1.code='dht2' limit 10 offset 20 - called in iterator is going to cost more than just: select firstName,lastName from user user1 inner join company com1 on user1.company_id=com1.id where com1.code='dht2' limit 10 offset 20 which is all that is needed hence avoiding 2 calls where 1 will do.
Re: Is there any other way? DataProviders must hit the Db twice for (possible) large datasets
If you must display the total rows, which I don't then use a different component and avoid the first call Which is what i said in my 3rd post. On Wed, Nov 26, 2008 at 7:51 PM, Jeremy Thomerson [EMAIL PROTECTED] wrote: But the second call is much longer and has a much different point. If you must display the total rows, you need to do the first call anyway. If you don't, then use a different component and avoid the first call, only getting the necessary rows, perhaps plus one to see if there is another page needed (ala inmethod). A count call will be very quick. And it transfers minimal data. On Wed, Nov 26, 2008 at 12:45 PM, Wayne Pope [EMAIL PROTECTED] wrote: the number of calls itself is meaningless, i dont comprehend why people have a hard time understanding this simple fact. The point for me is : something like select count(*) from user user1 inner join company com1 on user1.company_id= com1.id where com1.code='dht2' - called in size() followed by select firstName,lastName from user user1 inner join company com1 on user1.company_id=com1.id where com1.code='dht2' limit 10 offset 20 - called in iterator is going to cost more than just: select firstName,lastName from user user1 inner join company com1 on user1.company_id=com1.id where com1.code='dht2' limit 10 offset 20 which is all that is needed hence avoiding 2 calls where 1 will do. -- Jeremy Thomerson http://www.wickettraining.com
Re: swarm wicket 1.4
Hi, we've not decided here whether we'll use SWARM for our security needs for our super duper new online app (!). I think next month will be taking a long look at this as see if it fits the needs etc. I was also looking at jsecurity but theres no documentation and Les has yet to fully integrate into wicket. Getting SWARM to work with 1.4 m3 was no problem, just a couple of code changes, and it works as expected. If we commit to swarm then of course we can try and keep it more up to date. Wayne On Tue, Nov 18, 2008 at 5:46 PM, danelav [EMAIL PROTECTED] wrote: I am wondering the same thing. The most information I've found is here: http://www.nabble.com/WASP-SWARM-status-td20318330.html . It sounds like Wayne Pope may be taking up the torch. Marc Ende-2 wrote: Hi, currently I'm using swarm securing some webpages build on wicket. Now, that's wicket 1.4 is getting nearer, I would like to know if there is something planned with swarm for wicket 1.4. Do you know if it's compatible or is there a new release needed? yours Marc -- View this message in context: http://www.nabble.com/swarm---wicket-1.4-tp20549342p20563418.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Using continueToOriginalDestination() in a constructor - will it mess up the PageMap?
Hi, as part of my SWARM 1.4 integration I'm looking trying to get a silent login functionality working, and have used continueToOriginalDestination() in constructor of a Login page. However I saw this thread: http://www.nabble.com/redirect-page-in-the-constructor-td18111387.html#a18204061 So I have implemented: if (!getPage().continueToOriginalDestination()) { throw new RestartResponseException(Application.get().getHomePage()); } This works fine however am I messing up the PageMap? Its not clear to me how the continueToOriginalDestination() works (looks like just a boolean value). Is it Ok to do this? Or is there a way to get the actual intercepted page class and throw a RestartResponseException? Thanks Wayne
WASP/SWARM status
Hi, After the staggering loss of Maurice I was wondering if anyone had picked up the baton with WASP/SWARM? I look at svn and the last update was from mrmean so I presume not. I just wanted to check Thanks Wayne
Re: WASP/SWARM status
hi Nino, no I was looking at : https://wicket-stuff.svn.sourceforge.net/svnroot/wicket-stuff/trunk/wicket-security/ let me checkout the other and have a look I never know where I'm ment to find things with Wicket! On Tue, Nov 4, 2008 at 10:10 AM, Nino Saturnino Martinez Vazquez Wael [EMAIL PROTECTED] wrote: I've been wondering the same thing... Where this what you looked at? https://wicket-stuff.svn.sourceforge.net/svnroot/wicket-stuff/branches/wicket-security-1.4-earlyaccess/ Wayne Pope wrote: Hi, After the staggering loss of Maurice I was wondering if anyone had picked up the baton with WASP/SWARM? I look at svn and the last update was from mrmean so I presume not. I just wanted to check Thanks Wayne -- -Wicket for love Nino Martinez Wael Java Specialist @ Jayway DK http://www.jayway.dk +45 2936 7684 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: WASP/SWARM status
I'm going to see if I can get it working against 1.4 m3 On Tue, Nov 4, 2008 at 10:25 AM, Nino Saturnino Martinez Vazquez Wael [EMAIL PROTECTED] wrote: Hehe, I can understand... I figure that Maurice where playing around with wicket 1.4 and wicket security, and created a branch for it.. So my bet are that it probably need a lot of updates, to get it going.. If it's still unmaintained. And I actually wrote an mail to the dev list about the continuation of swarm, but thats a while ago.. http://www.nabble.com/In-memoriam%3A-Maurice-Marrink-td18813738.html#a18932415 I might have been asking too quickly. But the question still remains to be answered. And it would be a real shame if nobody continued it. Wayne Pope wrote: hi Nino, no I was looking at : https://wicket-stuff.svn.sourceforge.net/svnroot/wicket-stuff/trunk/wicket-security/ let me checkout the other and have a look I never know where I'm ment to find things with Wicket! On Tue, Nov 4, 2008 at 10:10 AM, Nino Saturnino Martinez Vazquez Wael [EMAIL PROTECTED] wrote: I've been wondering the same thing... Where this what you looked at? https://wicket-stuff.svn.sourceforge.net/svnroot/wicket-stuff/branches/wicket-security-1.4-earlyaccess/ Wayne Pope wrote: Hi, After the staggering loss of Maurice I was wondering if anyone had picked up the baton with WASP/SWARM? I look at svn and the last update was from mrmean so I presume not. I just wanted to check Thanks Wayne -- -Wicket for love Nino Martinez Wael Java Specialist @ Jayway DK http://www.jayway.dk +45 2936 7684 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- -Wicket for love Nino Martinez Wael Java Specialist @ Jayway DK http://www.jayway.dk +45 2936 7684 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: WASP/SWARM status
Last touched in July by maurice: 'initial compilation against wicket 1.4 (no generics yet)' On Tue, Nov 4, 2008 at 10:16 AM, Wayne Pope [EMAIL PROTECTED] wrote: hi Nino, no I was looking at : https://wicket-stuff.svn.sourceforge.net/svnroot/wicket-stuff/trunk/wicket-security/ let me checkout the other and have a look I never know where I'm ment to find things with Wicket! On Tue, Nov 4, 2008 at 10:10 AM, Nino Saturnino Martinez Vazquez Wael [EMAIL PROTECTED] wrote: I've been wondering the same thing... Where this what you looked at? https://wicket-stuff.svn.sourceforge.net/svnroot/wicket-stuff/branches/wicket-security-1.4-earlyaccess/ Wayne Pope wrote: Hi, After the staggering loss of Maurice I was wondering if anyone had picked up the baton with WASP/SWARM? I look at svn and the last update was from mrmean so I presume not. I just wanted to check Thanks Wayne -- -Wicket for love Nino Martinez Wael Java Specialist @ Jayway DK http://www.jayway.dk +45 2936 7684 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: attribute modifier on onclick
not sure but perhaps try modelchanged on the label On Mon, Nov 3, 2008 at 9:32 PM, miro [EMAIL PROTECTED] wrote: I have a linkthis contains a label , now I want to change the style of the label whenever user clicks on the link , to do this I override the method onClick() in link component I am retrieving the label and adding simpleattributemodifier to the label , but there is no change , when I see the generated html it does not include the added style , can I change the style of a component in any of the events of a component ? -- View this message in context: http://www.nabble.com/attribute-modifier-on-onclick-tp20310246p20310246.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: date picker
it probably hasn't been updated. just download the source and do it yourself - its usually very trivial change. On Tue, Nov 4, 2008 at 8:37 AM, tbt [EMAIL PROTECTED] wrote: Hi I'm using wicket 1.3.2 and downloaded wicket-contrib-datepicker-1.2 because I want to use a date picker for my application. But this release is not compatible with wicket 1.3 because it gives errors. Can someone give me the link to download a date picker component that is compatible with wicket 1.3 Thanks -- View this message in context: http://www.nabble.com/date-picker-tp20317456p20317456.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: CompoundModel based on proxies
Hi, Francisco and I here where discussing whether we could figure a way of having some form of static/compile time checking on our (Compound)PropertyModels, as I'm a bit concerned long term about some nasty runtime bugs that might slip through the testing coverage. Francisco found this thread - I'm wondering what the status is? I had a look at: https://issues.apache.org/jira/browse/WICKET-1327 and there doesn't look like any activity since Feb. Anyone been using this or come up with a different solution? Ideally I think it would be just great if we had an eclipse plugin that could just check for this (a bit like checkstyle or something) but a runtime solution as proposed above seems really smart as well. However I'd rather keep is 100% java (ie not cglib) if possible. Thanks for any update if anyone knows anything! Wayne Johan Compagner wrote: no i really dont like that then everywhere there code they need to do that, that is not an option. and they have to program themselfs agains the proxy api. I dont want that developers also have the learn/do that This is something commons-proxy needs to do On Sat, Mar 8, 2008 at 3:29 PM, James Carman [EMAIL PROTECTED] wrote: Couldn't you also do: ProxyFactory pf = ...; new SharedPropertyModelCustomer(pf, customer); So, the client tells you what proxy factory implementation to use. On 3/8/08, James Carman [EMAIL PROTECTED] wrote: I see the JIRA, I'll go ahead and start the discussion on the dev list. On 3/8/08, James Carman [EMAIL PROTECTED] wrote: On 3/8/08, Johan Compagner [EMAIL PROTECTED] wrote: for wicket this is a feature it really should have now it defeats the purpose i have to make a decission in wicket which factory i use Then i can just as well directly compile against cglib. I cant make the api that way that the developer has to give that factory to use. That would be completely horrible, You could always implement your own brand of discovery for your project (perhaps by using the service discovery feature built into the jdk). I like the idea of splitting it (and doing it the slf4j way rather than the JCL way). I have actually suggested that we start an exploratory branch of JCL to make it work more like slf4j (we've been talking about this since 2005). Anyway, if you file a JIRA issue, I'll make sure we have a discussion with the other devs. For your immediate purposes, commons-discovery is available also. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/CompoundModel-based-on-proxies-tp15317807p20222077.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: using wicket
I cannot comment on the stabiliy, but for the javadoc you'll need to download the source and generate the javadoc (use maven for the quickest) as I don;t beleive its online anywhere On Tue, Oct 28, 2008 at 5:53 PM, miro [EMAIL PROTECTED] wrote: I am new to wicket and no guru to help me answer questions , I am starting a new project , is it ok to work with wicket 1.4 , i mean is it a stable release ,of should I use wicket 1.3 ? Please help me , also please point me to java docs of wicket 1.4 if 1.4 is all teste3d and ready for use -- View this message in context: http://www.nabble.com/using-wicket-tp20211179p20211179.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: CompoundModel based on proxies
Hi Maarten interesting idea thanks. I think the major issue is the null pointer checking. for your: public class Customer implements Serializable { public final IModelString firstName = new ModelString(); public final IModelString lastName = new ModelString(); } do you wrap this around you (hibernate/other) pojo's or are this additional fields? On Wed, Oct 29, 2008 at 10:42 AM, Maarten Bosteels [EMAIL PROTECTED]wrote: On Wed, Oct 29, 2008 at 8:35 AM, Wayne Pope [EMAIL PROTECTED] wrote: Hi, Francisco and I here where discussing whether we could figure a way of having some form of static/compile time checking on our (Compound)PropertyModels, as I'm a bit concerned long term about some nasty runtime bugs that might slip through the testing coverage. Francisco found this thread - I'm wondering what the status is? I had a look at: https://issues.apache.org/jira/browse/WICKET-1327 and there doesn't look like any activity since Feb. Anyone been using this or come up with a different solution? Ideally I think it would be just great if we had an eclipse plugin that could just check for this (a bit like checkstyle or something) but a runtime solution as proposed above seems really smart as well. However I'd rather keep is 100% java (ie not cglib) if possible. Hello, If you want something 100% java you could copde your domain models like this: public class Customer implements Serializable { public final IModelString firstName = new ModelString(); public final IModelString lastName = new ModelString(); } and use it like this: form.add(new TextFieldString(firstName, customer.firstName)); form.add(new TextFieldString(lastName, customer.lastName)); = no need to generate ugly getters/setters for all your properties = pure java = refactoring-safe = navigation + code-completion from IDE = you can still override setObject() and/or setObject() when needed In this example I have used wicket's IModel and Model but you could also use PropertyString from https://bean-properties.dev.java.net/ which has a lot of other benefits (a pity that the project is stalled a bit). Note that I haven't used this extensively but I sure do want to test it out in the near future.. One problem I see with this approach is when you need null-checking for nested properties: eg: new TextFieldString(city, customer.address.getObject().city ); Let me know what you think about it. Maarten Thanks for any update if anyone knows anything! Wayne Johan Compagner wrote: no i really dont like that then everywhere there code they need to do that, that is not an option. and they have to program themselfs agains the proxy api. I dont want that developers also have the learn/do that This is something commons-proxy needs to do On Sat, Mar 8, 2008 at 3:29 PM, James Carman [EMAIL PROTECTED] wrote: Couldn't you also do: ProxyFactory pf = ...; new SharedPropertyModelCustomer(pf, customer); So, the client tells you what proxy factory implementation to use. On 3/8/08, James Carman [EMAIL PROTECTED] wrote: I see the JIRA, I'll go ahead and start the discussion on the dev list. On 3/8/08, James Carman [EMAIL PROTECTED] wrote: On 3/8/08, Johan Compagner [EMAIL PROTECTED] wrote: for wicket this is a feature it really should have now it defeats the purpose i have to make a decission in wicket which factory i use Then i can just as well directly compile against cglib. I cant make the api that way that the developer has to give that factory to use. That would be completely horrible, You could always implement your own brand of discovery for your project (perhaps by using the service discovery feature built into the jdk). I like the idea of splitting it (and doing it the slf4j way rather than the JCL way). I have actually suggested that we start an exploratory branch of JCL to make it work more like slf4j (we've been talking about this since 2005). Anyway, if you file a JIRA issue, I'll make sure we have a discussion with the other devs. For your immediate purposes, commons-discovery is available also. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/CompoundModel-based-on-proxies-tp15317807p20222077.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e
Re: CompoundModel based on proxies
Hi Johan, we're now maigrating to 1.4 M3 - do you have any idea roughly when the release proper of 1.4 would be? thanks Wayne On Wed, Oct 29, 2008 at 10:34 AM, Johan Compagner [EMAIL PROTECTED]wrote: wicket 1.5 first 1.4 has to be released On Wed, Oct 29, 2008 at 8:35 AM, Wayne Pope [EMAIL PROTECTED] wrote: Hi, Francisco and I here where discussing whether we could figure a way of having some form of static/compile time checking on our (Compound)PropertyModels, as I'm a bit concerned long term about some nasty runtime bugs that might slip through the testing coverage. Francisco found this thread - I'm wondering what the status is? I had a look at: https://issues.apache.org/jira/browse/WICKET-1327 and there doesn't look like any activity since Feb. Anyone been using this or come up with a different solution? Ideally I think it would be just great if we had an eclipse plugin that could just check for this (a bit like checkstyle or something) but a runtime solution as proposed above seems really smart as well. However I'd rather keep is 100% java (ie not cglib) if possible. Thanks for any update if anyone knows anything! Wayne Johan Compagner wrote: no i really dont like that then everywhere there code they need to do that, that is not an option. and they have to program themselfs agains the proxy api. I dont want that developers also have the learn/do that This is something commons-proxy needs to do On Sat, Mar 8, 2008 at 3:29 PM, James Carman [EMAIL PROTECTED] wrote: Couldn't you also do: ProxyFactory pf = ...; new SharedPropertyModelCustomer(pf, customer); So, the client tells you what proxy factory implementation to use. On 3/8/08, James Carman [EMAIL PROTECTED] wrote: I see the JIRA, I'll go ahead and start the discussion on the dev list. On 3/8/08, James Carman [EMAIL PROTECTED] wrote: On 3/8/08, Johan Compagner [EMAIL PROTECTED] wrote: for wicket this is a feature it really should have now it defeats the purpose i have to make a decission in wicket which factory i use Then i can just as well directly compile against cglib. I cant make the api that way that the developer has to give that factory to use. That would be completely horrible, You could always implement your own brand of discovery for your project (perhaps by using the service discovery feature built into the jdk). I like the idea of splitting it (and doing it the slf4j way rather than the JCL way). I have actually suggested that we start an exploratory branch of JCL to make it work more like slf4j (we've been talking about this since 2005). Anyway, if you file a JIRA issue, I'll make sure we have a discussion with the other devs. For your immediate purposes, commons-discovery is available also. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- View this message in context: http://www.nabble.com/CompoundModel-based-on-proxies-tp15317807p20222077.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: have anyone tried empire-DB?
Nino what do you recommend in terms orf DB framework. We're currently using Hibernate and I'm personally finding it a pain - it seems to influence the java code way too much and it create some horrible joins if we're not carefull. Any suggestions that you've used in the real world? On Fri, Oct 17, 2008 at 8:15 PM, Nino Saturnino Martinez Vazquez Wael [EMAIL PROTECTED] wrote: This is interesting: (JaQu) Provide API level compatibility with JPA (so that JaQu can be used as an extension of JPA). But I think something similar are on its way for JPA 2.0..? marco.behler wrote: I gave empireDB a quick look a while ago and it looks interesting. Besides JPersist I also stumbled upon JaQu (http://www.h2database.com/html/jaqu.html), which is still in its infancy. I'm sure there's more LINQ-like clones out there. As far as I'm concerned, I'd really like to have a thorough look at stuff like db4o or couchDB, especially performance wise. I did Hibernate/iBatis in the past and am currently working on a project with iBatis again. Both have advantages and disadvantages and I don't love either. I would rather not have to care about tables, objects,the mighty mismatch (and in Hibernate's case the mighty session) anymore, but just shove that damn thing into an object database ;) *hides from enraged DBAs and their optimised queries* Nino.Martinez wrote: Yeah seems to be nice... At WUG DK we discussed. That if using stuff like hibernate, for simple cruds it's nice but if you have a complex object graph it becomes very troublesome to use (if you use cascade all etc.).. Ames, Tim wrote: Looks like it has a lot in common with JPersist. That is what I have been using. No XML, all POJO. -Original Message- From: Nino Saturnino Martinez Vazquez Wael [mailto:[EMAIL PROTECTED] Sent: Thursday, October 16, 2008 11:28 AM To: users@wicket.apache.org Subject: have anyone tried empire-DB? So have you tried it with wicket? http://incubator.apache.org/empire-db/ -- -Wicket for love Nino Martinez Wael Java Specialist @ Jayway DK http://www.jayway.dk +45 2936 7684 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ EMAIL CONFIDENTIALITY NOTICE This Email message, and any attachments, may contain confidential patient health information that is legally protected. This information is intended only for the use of the individual or entity named above. The authorized recipient of this information is prohibited from disclosing this information to any other party unless required to do so by law or regulation and is required to destroy the information after its stated need has been fulfilled. If you are not the intended recipient, you are hereby notified that any disclosure, copying, distribution, or action taken in reliance on the contents of this message is strictly prohibited. If you have received this information in error, please notify the sender immediately by replying to this message and delete the message from your system. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- -Wicket for love Nino Martinez Wael Java Specialist @ Jayway DK http://www.jayway.dk +45 2936 7684 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- -Wicket for love Nino Martinez Wael Java Specialist @ Jayway DK http://www.jayway.dk +45 2936 7684 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: have anyone tried empire-DB?
well I'm new to Hibernate, and it seems that you must be extremely consious of how hibernate handles mapping etc. This may also be the same with other object to relational frameworks. An example is the the behaviour of OneToMany mappings using List as this uses bag sematics. Hibernate's handling of these relationships is somewhat brute force i.e. it deletes existing entries and re-inserts to match the current collection and therefore you need to use Set's or use collectionid to create an idbag. Therefore straight away I can't use a List (which is all I need) in the code. There seems (to me) many many gotchas with Hibernate that you need to be aware of and the error messages don't tell you much compare to say Wicket. I come from a world where we used stored proceedures before and you simply provided the straight mapping from the result columns to your pojos. This was very flexible as you could change your pojos with no impact to the db structure and vice-versa we could completly change the db schema (for performance or any reason) with no impact on the code. This seems to work well. On Thu, Oct 23, 2008 at 8:36 AM, Igor Vaynberg [EMAIL PROTECTED]wrote: im curious in what way does it influence java code... -igor On Wed, Oct 22, 2008 at 10:59 PM, Wayne Pope [EMAIL PROTECTED] wrote: Nino what do you recommend in terms orf DB framework. We're currently using Hibernate and I'm personally finding it a pain - it seems to influence the java code way too much and it create some horrible joins if we're not carefull. Any suggestions that you've used in the real world? On Fri, Oct 17, 2008 at 8:15 PM, Nino Saturnino Martinez Vazquez Wael [EMAIL PROTECTED] wrote: This is interesting: (JaQu) Provide API level compatibility with JPA (so that JaQu can be used as an extension of JPA). But I think something similar are on its way for JPA 2.0..? marco.behler wrote: I gave empireDB a quick look a while ago and it looks interesting. Besides JPersist I also stumbled upon JaQu (http://www.h2database.com/html/jaqu.html), which is still in its infancy. I'm sure there's more LINQ-like clones out there. As far as I'm concerned, I'd really like to have a thorough look at stuff like db4o or couchDB, especially performance wise. I did Hibernate/iBatis in the past and am currently working on a project with iBatis again. Both have advantages and disadvantages and I don't love either. I would rather not have to care about tables, objects,the mighty mismatch (and in Hibernate's case the mighty session) anymore, but just shove that damn thing into an object database ;) *hides from enraged DBAs and their optimised queries* Nino.Martinez wrote: Yeah seems to be nice... At WUG DK we discussed. That if using stuff like hibernate, for simple cruds it's nice but if you have a complex object graph it becomes very troublesome to use (if you use cascade all etc.).. Ames, Tim wrote: Looks like it has a lot in common with JPersist. That is what I have been using. No XML, all POJO. -Original Message- From: Nino Saturnino Martinez Vazquez Wael [mailto:[EMAIL PROTECTED] Sent: Thursday, October 16, 2008 11:28 AM To: users@wicket.apache.org Subject: have anyone tried empire-DB? So have you tried it with wicket? http://incubator.apache.org/empire-db/ -- -Wicket for love Nino Martinez Wael Java Specialist @ Jayway DK http://www.jayway.dk +45 2936 7684 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ EMAIL CONFIDENTIALITY NOTICE This Email message, and any attachments, may contain confidential patient health information that is legally protected. This information is intended only for the use of the individual or entity named above. The authorized recipient of this information is prohibited from disclosing this information to any other party unless required to do so by law or regulation and is required to destroy the information after its stated need has been fulfilled. If you are not the intended recipient, you are hereby notified that any disclosure, copying, distribution, or action taken in reliance on the contents of this message is strictly prohibited. If you have received this information in error, please notify the sender immediately by replying to this message and delete the message from your system. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- -Wicket for love Nino Martinez Wael Java Specialist @ Jayway DK http://www.jayway.dk +45 2936 7684
Re: have anyone tried empire-DB?
seems to me you just dont grasp how the mappings work. lol yes, I am new to it so lots to grasp. To be fair I did sort out the mappings to use List after a lot of messing about. I just find things take a long time to behave correctly in Hibernate, and thus not very productive - for me it one of the harder frameworks to get up to speed with , especially as I'm using the annotations and most of the doc/knowledge base is around the xml form. Perhaps I should switch. However my original quesiton still stands - any other db frameworks that anyone recommends? On Thu, Oct 23, 2008 at 9:03 AM, Igor Vaynberg [EMAIL PROTECTED]wrote: seems to me you just dont grasp how the mappings work. eg if you use a @OneToMany with mappedby and let the other side control the association then nothing is automatically inserted or deleted. further, even if you do not use mappedby then nothing is deleted unless you declare the delete orphan cascade. the problem here is that List is a specific type of collection where each element is uniquely identified by its index. that is just the nature of lists and has nothing to do with hibenrate. this generally does not map nicely to database collections unless you actually have an index column in your table, so lists are rarely used when dealing with databases... i will agree with you as far as hibernate's horrible error reporting, but other then that i find it a good tool and do not see many cases where the abstraction leaks into actual coding style. some concepts are very leaky, such as lazy loading, but that cant really be helped. -igor On Wed, Oct 22, 2008 at 11:56 PM, Wayne Pope [EMAIL PROTECTED] wrote: well I'm new to Hibernate, and it seems that you must be extremely consious of how hibernate handles mapping etc. This may also be the same with other object to relational frameworks. An example is the the behaviour of OneToMany mappings using List as this uses bag sematics. Hibernate's handling of these relationships is somewhat brute force i.e. it deletes existing entries and re-inserts to match the current collection and therefore you need to use Set's or use collectionid to create an idbag. Therefore straight away I can't use a List (which is all I need) in the code. There seems (to me) many many gotchas with Hibernate that you need to be aware of and the error messages don't tell you much compare to say Wicket. I come from a world where we used stored proceedures before and you simply provided the straight mapping from the result columns to your pojos. This was very flexible as you could change your pojos with no impact to the db structure and vice-versa we could completly change the db schema (for performance or any reason) with no impact on the code. This seems to work well. On Thu, Oct 23, 2008 at 8:36 AM, Igor Vaynberg [EMAIL PROTECTED] wrote: im curious in what way does it influence java code... -igor On Wed, Oct 22, 2008 at 10:59 PM, Wayne Pope [EMAIL PROTECTED] wrote: Nino what do you recommend in terms orf DB framework. We're currently using Hibernate and I'm personally finding it a pain - it seems to influence the java code way too much and it create some horrible joins if we're not carefull. Any suggestions that you've used in the real world? On Fri, Oct 17, 2008 at 8:15 PM, Nino Saturnino Martinez Vazquez Wael [EMAIL PROTECTED] wrote: This is interesting: (JaQu) Provide API level compatibility with JPA (so that JaQu can be used as an extension of JPA). But I think something similar are on its way for JPA 2.0..? marco.behler wrote: I gave empireDB a quick look a while ago and it looks interesting. Besides JPersist I also stumbled upon JaQu (http://www.h2database.com/html/jaqu.html), which is still in its infancy. I'm sure there's more LINQ-like clones out there. As far as I'm concerned, I'd really like to have a thorough look at stuff like db4o or couchDB, especially performance wise. I did Hibernate/iBatis in the past and am currently working on a project with iBatis again. Both have advantages and disadvantages and I don't love either. I would rather not have to care about tables, objects,the mighty mismatch (and in Hibernate's case the mighty session) anymore, but just shove that damn thing into an object database ;) *hides from enraged DBAs and their optimised queries* Nino.Martinez wrote: Yeah seems to be nice... At WUG DK we discussed. That if using stuff like hibernate, for simple cruds it's nice but if you have a complex object graph it becomes very troublesome to use (if you use cascade all etc.).. Ames, Tim wrote: Looks like it has a lot in common with JPersist. That is what I have been using. No XML, all POJO. -Original Message- From: Nino Saturnino Martinez Vazquez Wael [mailto
Why is Wicket called Wicket?
We where just chating here, and we're wondering where the name wicket comes from ? Looking it up on in the dictionary I couldn't really see the connection. Anyone know how the name came about? thanks Wayne
Re: Why is Wicket called Wicket?
thanks Nino, I knew I'd seen it somewhere but couldn't remember. so it was reference to the game of cricket stumps rather than to quote a dictionary: a window or opening, often closed by a grating or the like, as in a door, or forming a place of communication in a ticket office, a teller's cage in a bank, etc. On Wed, Oct 22, 2008 at 10:59 AM, Nino Saturnino Martinez Vazquez Wael [EMAIL PROTECTED] wrote: Jonathan Locke wrote something about it in his foreword in WIA: Several 60-hour weeks later, the first version of Wicket was born. (In case you're wondering, Wicket was the first fun and unique-sounding short word that Miko also liked and that wasn't being used for a major software project. It also appears in some dictionaries as a cricket term for a small framework at which the bowler aims the ball.) I'm happy to say that after more than four years and the input of many manyears of effort from the open source community, Wicket now meets most if not all of my criteria for a web framework Wayne Pope wrote: We where just chating here, and we're wondering where the name wicket comes from ? Looking it up on in the dictionary I couldn't really see the connection. Anyone know how the name came about? thanks Wayne -- -Wicket for love Nino Martinez Wael Java Specialist @ Jayway DK http://www.jayway.dk +45 2936 7684 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to pass parameters to a BreadCrumbPanel
Hi Naveen, I do it something like this: TabbedPanel tabbedPanel = new TabbedPanel(tabs, tabs){ @Override protected WebMarkupContainer newLink(String linkId, final int index) { PageParameters parameters = new PageParameters(); parameters.put(selected, ((ITab) getTabs().get(index)) .getTitle().getObject()); parameters.put(somethingIneedID, somethingIneedID); return new BookmarkablePageLink(linkId, MyPage.class, parameters); } }; if (found) tabbedPanel.setSelectedTab(selected); if (tabSelect != null) tabbedPanel.setSelectedTab(tabSelect); add(tabbedPanel); you should be able to figue it out from there. Wayne On Tue, Oct 21, 2008 at 9:06 PM, Nav Che [EMAIL PROTECTED] wrote: Hello All, How do i pass parameters between panels. Basically i have panels in my appilcation which use breadcrumb model. Say on panel A i display list of users and I want the user Id to be a link upon clickin it should show the edit panel ( panel B ) of user and for which it shld either pass user object or userid. Please advise. Thanks in advance Regards naveen
Re: Wicket Markup parse doesn't handle Conditional Comments
Its definitely not working for me. I've used a header contributor for know, but its not ideal. Should I report this as a bug? On Mon, Sep 22, 2008 at 6:57 PM, Jörn Zaefferer [EMAIL PROTECTED] wrote: We are using conditional comments in our base page without any issues. Dunno if that page isn't parsed my the MarkupParser for some reason... Jörn On Mon, Sep 22, 2008 at 5:49 PM, Matej Knopp [EMAIL PROTECTED] wrote: Well, if it is a valid xml then it is bug in our parser. -Matej On Mon, Sep 22, 2008 at 5:44 PM, Igor Vaynberg [EMAIL PROTECTED] wrote: you are going to have to output the whole thing using a label or header contributor. our parser cant handle the non-standard comment tags yet. -igor On Mon, Sep 22, 2008 at 1:40 AM, Wayne Pope [EMAIL PROTECTED] wrote: Hi, I just tried to put some conditional comments in my page: !--[if lt IE 7] style type=text/css .dock img { behavior: url(css/iepngfix.htc) } /style ![endif]-- and the Markupparser just can't seem to handle it: Caused by: java.text.ParseException: Unclosed comment beginning at line:9 column:3 at org.apache.wicket.markup.parser.XmlPullParser.specialTagHandling(XmlPullParser.java:332) at org.apache.wicket.markup.parser.XmlPullParser.next(XmlPullParser.java:243) at org.apache.wicket.markup.parser.XmlPullParser.nextTag(XmlPullParser.java:423) at org.apache.wicket.markup.parser.filter.WicketTagIdentifier.nextTag(WicketTagIdentifier.java:77) at org.apache.wicket.markup.parser.filter.TagTypeHandler.nextTag(TagTypeHandler.java:76) at org.apache.wicket.markup.parser.filter.HtmlHandler.nextTag(HtmlHandler.java:78) at org.apache.wicket.markup.parser.filter.WicketRemoveTagHandler.nextTag(WicketRemoveTagHandler.java:60) at org.apache.wicket.markup.parser.filter.WicketLinkTagHandler.nextTag(WicketLinkTagHandler.java:94) at org.apache.wicket.markup.parser.AbstractMarkupFilter.nextComponentTag(AbstractMarkupFilter.java:82) at org.apache.wicket.markup.parser.filter.WicketNamespaceHandler.nextTag(WicketNamespaceHandler.java:72) at org.apache.wicket.markup.parser.AbstractMarkupFilter.nextComponentTag(AbstractMarkupFilter.java:82) at org.apache.wicket.markup.parser.filter.WicketMessageTagHandler.nextTag(WicketMessageTagHandler.java:81) at org.apache.wicket.markup.parser.AbstractMarkupFilter.nextComponentTag(AbstractMarkupFilter.java:82) at org.apache.wicket.markup.parser.filter.HtmlHeaderSectionHandler.nextTag(HtmlHeaderSectionHandler.java:77) at org.apache.wicket.markup.parser.filter.HeadForceTagIdHandler.nextTag(HeadForceTagIdHandler.java:77) at org.apache.wicket.markup.parser.AbstractMarkupFilter.nextComponentTag(AbstractMarkupFilter.java:82) at org.apache.wicket.markup.parser.filter.OpenCloseTagExpander.nextTag(OpenCloseTagExpander.java:51) at org.apache.wicket.markup.parser.AbstractMarkupFilter.nextComponentTag(AbstractMarkupFilter.java:82) at org.apache.wicket.markup.parser.filter.EnclosureHandler.nextTag(EnclosureHandler.java:76) at org.apache.wicket.markup.parser.filter.RelativePathPrefixHandler.nextTag(RelativePathPrefixHandler.java:116) at org.apache.wicket.markup.MarkupParser.getNextTag(MarkupParser.java:302) at org.apache.wicket.markup.MarkupParser.parseMarkup(MarkupParser.java:322) ... 35 more Any way of handling this? thanks - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Wicket Markup parse doesn't handle Conditional Comments
Hi, I just tried to put some conditional comments in my page: !--[if lt IE 7] style type=text/css .dock img { behavior: url(css/iepngfix.htc) } /style ![endif]-- and the Markupparser just can't seem to handle it: Caused by: java.text.ParseException: Unclosed comment beginning at line:9 column:3 at org.apache.wicket.markup.parser.XmlPullParser.specialTagHandling(XmlPullParser.java:332) at org.apache.wicket.markup.parser.XmlPullParser.next(XmlPullParser.java:243) at org.apache.wicket.markup.parser.XmlPullParser.nextTag(XmlPullParser.java:423) at org.apache.wicket.markup.parser.filter.WicketTagIdentifier.nextTag(WicketTagIdentifier.java:77) at org.apache.wicket.markup.parser.filter.TagTypeHandler.nextTag(TagTypeHandler.java:76) at org.apache.wicket.markup.parser.filter.HtmlHandler.nextTag(HtmlHandler.java:78) at org.apache.wicket.markup.parser.filter.WicketRemoveTagHandler.nextTag(WicketRemoveTagHandler.java:60) at org.apache.wicket.markup.parser.filter.WicketLinkTagHandler.nextTag(WicketLinkTagHandler.java:94) at org.apache.wicket.markup.parser.AbstractMarkupFilter.nextComponentTag(AbstractMarkupFilter.java:82) at org.apache.wicket.markup.parser.filter.WicketNamespaceHandler.nextTag(WicketNamespaceHandler.java:72) at org.apache.wicket.markup.parser.AbstractMarkupFilter.nextComponentTag(AbstractMarkupFilter.java:82) at org.apache.wicket.markup.parser.filter.WicketMessageTagHandler.nextTag(WicketMessageTagHandler.java:81) at org.apache.wicket.markup.parser.AbstractMarkupFilter.nextComponentTag(AbstractMarkupFilter.java:82) at org.apache.wicket.markup.parser.filter.HtmlHeaderSectionHandler.nextTag(HtmlHeaderSectionHandler.java:77) at org.apache.wicket.markup.parser.filter.HeadForceTagIdHandler.nextTag(HeadForceTagIdHandler.java:77) at org.apache.wicket.markup.parser.AbstractMarkupFilter.nextComponentTag(AbstractMarkupFilter.java:82) at org.apache.wicket.markup.parser.filter.OpenCloseTagExpander.nextTag(OpenCloseTagExpander.java:51) at org.apache.wicket.markup.parser.AbstractMarkupFilter.nextComponentTag(AbstractMarkupFilter.java:82) at org.apache.wicket.markup.parser.filter.EnclosureHandler.nextTag(EnclosureHandler.java:76) at org.apache.wicket.markup.parser.filter.RelativePathPrefixHandler.nextTag(RelativePathPrefixHandler.java:116) at org.apache.wicket.markup.MarkupParser.getNextTag(MarkupParser.java:302) at org.apache.wicket.markup.MarkupParser.parseMarkup(MarkupParser.java:322) ... 35 more Any way of handling this? thanks
Any wicket based (or plain java) Calendars out there? (not a datepicker)
Hi, does anyone know of a Calendar out there - something comparible to Google's calander in terms of functionality. I've found plenty of php ones and a couple of 'clunky' java ones. Any pointers much appreciated. thanks
Re: newbie problem witch wicket...
Hi, I've only been using Wicket a very short time, but why don;t you just create a simple login form page. Then look at the source and you'll see something like: form action=?wicket:bookmarkablePage=:com.youpackage.LoginPageamp;wicket:interface=:0:signInPanel:signInForm::IFormSubmitListener:: wicket:id=signInForm id=signInForm method=post Then you need to just to POST the username and password parameters to the above URL , and it'll log you in. I not sure how you set to us GET in wicket which would be more easy for you. But I''m sure someone get tell you how to set that up for a form. cheers Wayne On Mon, Sep 8, 2008 at 9:59 PM, dlipski [EMAIL PROTECTED] wrote: Hi Im developing with Wicket for short time so forgive me if I misanderstood some Wicket concepts. Recently I was asked for develop SSO-like feature for Wicket powered web application. Application uses wicket-auth-roles + Acegi for securing wicket pages. What I have to do is to let authenticate users to this web app only by typing URL in their web browsers (or clicking some prepared link). This URL will contain username and password but user will not be forced to fill in any form or press any button - just typing url or cliciking some prepared link. Actual way of uthentication (via Wicket page) must remain, so there will be two ways to login to application: either by filling in form or typing url in web browser. Because this application is using wicket-auth-roles what I have to do is to retrive from request user login and password and call signIn(username, password) on Session object. This is the moment where problem begins (for me). I've tried to write simple servlet to do this but when I've accessed Wicket session by: Session.get() runtime exception was thrown because Wicket session cant be created outside request cycle... ...so I decided to do this inside request cycle, but actually I dont know any simple solution to execute some code (after sending bookmarkable request) and redirect to some WicketPage. What I need is something like BookmarkablePage but dont displaying any page, only redirecting to other page (after executing autentication,or some other code), something which might be called BookmarkableAction ;). Probably it is possible to write custom request target and extend request target processor (to create such target) but it looks too complicated for me to perform some simple task. In action oriented frameworks (Struts/SpringMVC/...) its trivial, I know that Wicket is page oriented framework but Im wondering if there is any support for such 'actions'. Maybe there is some other way to achive such SSO-like feature ? Regards Daniel -- View this message in context: http://www.nabble.com/newbie-problem-witch-wicket...-tp19379967p19379967.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
PropertyModel/TextArea keeps reference to my detached object!
Ok, this has take me ages to figure out what is happening. I have a model that represents a hibernate entity (called Document). I have a form with a couple of fields which uses PropertyModel on the model and I set the model on this forms contructor.ie.: setModel(model); add(new TextField(title, new PropertyModel(getModelObject(),latestVersion.title))); add(new TextArea(quicksummary, new PropertyModel(getModelObject(),latestVersion.summary))); this model is : public class DocumentModel extends Model { Document doc; Long id; public DocumentModel() { } public DocumentModel(Long docId) { id = docId; } @Override public Object getObject() { if (doc != null) return doc; if (id == null) { doc = new Document(); } else { doc = DAOFactory.getFactory().getDocumentDAO().findByPrimaryKey(id); } return doc; } @Override public void setObject(Object obj) { doc = (Document)obj; id = (doc == null) ? null : doc.getId(); } @Override public void detach() { doc = null; } } When the constructor for the form is called I see that the PropertyModel gets the Document entity from my model and populates the fields. My DocumentModel is detached and page displayed. So far far so good. However when the form is submitted, I see that during the Form validation the method TextArea,setModelObject is calling model.setObject(object). (The model here is the PropertyModel class instance that was contructed in my forms constructor) - I see that this has a reference to my detached Document entity. THe problems is that in my onSubmit method which is called after the above validation etc, is when I call getModelObject() it in turns calls getObject() which (as its detached) loads the entity again from the database - however this is a different object to the one PropertyModels updated So the PropertyModel's are updating an object that was detached! So plainly I don;t understand what I'm ment to do with Wicket and detached models - how to you have a form that represents an entity and make it detached? Thanks Wayne
Jobs, opertunities and this mailing list
Hi everyone, whats the policy here about advertising jobs or project/dev oppertunities? I'm creating something new and I'm looking for talented people. I don't want to annoy anyone here, so would like to know the rules about this and any suggestions on how I can get in contact with fellow wicket people. I'm going to be joining the wicket events here in europe as I'd like to get involved long term with this framework. Ok I'll leave it at that for now, but any pointers would be appreciated. thanks Wayne
Re: Jobs, opertunities and this mailing list
Ok thanks, its pure Wicket UI oppertunity. I'll create a new posting rather than attaching it to this. If Martijn (or anyone here) needs to approve it first please let me know and I'll email it direct. If I don't hear anything I'll post it on mailing list. thanks Wayne On Thu, Aug 21, 2008 at 4:16 PM, Martijn Dashorst [EMAIL PROTECTED] wrote: Yep, We're *NOT* looking for blanket job offers that list all available java frameworks. The job has to actually involve Wicket (related) programming. Martijn On Thu, Aug 21, 2008 at 4:13 PM, Matej Knopp [EMAIL PROTECTED] wrote: Go ahead, feel free to post the job ads, as long as they are wicket related. -Matej On Thu, Aug 21, 2008 at 4:07 PM, Wayne Pope [EMAIL PROTECTED] wrote: Hi everyone, whats the policy here about advertising jobs or project/dev oppertunities? I'm creating something new and I'm looking for talented people. I don't want to annoy anyone here, so would like to know the rules about this and any suggestions on how I can get in contact with fellow wicket people. I'm going to be joining the wicket events here in europe as I'd like to get involved long term with this framework. Ok I'll leave it at that for now, but any pointers would be appreciated. thanks Wayne - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Become a Wicket expert, learn from the best: http://wicketinaction.com Apache Wicket 1.3.4 is released Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
I have some Wicket based opportunities/jobs if you're interested.
Hi, Ok following my last email I have some opportunities for the right people. I'm in the middle of creating a new start-up with funding already sorted. We've got a great idea for an online application totally based on Wicket. I'm activity seeking 2 to 4 developers who would like to get involved in this new startup. We're based in the South of France/Cannes area (though I'm personally from the UK) and ideally looking for people to join us here for a 6 month contract to start with. However I realise that many of you a) already have jobs b) happy living where you are. So with this in mind I'm looking at perhaps creating a distributed/remote team to work on this. - think 37signals.com for those who are aware. We can pay a straight daily rate, or perhaps more motivating - to have shares in the company and grow with it. It's a strong business case, and I believe we have to right people onboard outside of development. I wanted to go with an Agile/XP approach to this - so lots of fun coding and constant working version. This however isn't going to work as well if it ends up being a remote team so may have to adopt. Like I said previously - we're looking to create the small team here on the Riviera *ideally*. So if this sounds interesting please do email me or reply to this, and we can talk some more. Thanks Wayne
Re: I have some Wicket based opportunities/jobs if you're interested.
Hi, just to perhaps say - please just contact me directly as I don't want to spam this list in anyway. thanks Wayne On Thu, Aug 21, 2008 at 5:38 PM, Erik van Oosten [EMAIL PROTECTED]wrote: Cristi Manole wrote: Please share more details like when the project is planned to start, how many hours per day, etc. But not on this list please. Regards, Erik. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
(WebRequest)getRequestCycle() is always null on first request
Hi, I've got a problem that I have no idea how to fix. I'm using IAuthorizationStrategy to authenticate the users of my application. However on the first request to the server (WebRequest)getRequestCycle() returns null all the time, so I therefore cannot get an cookies (which I want). This is a real pain. Why is it the case that its null here, but later in the flow its there? Stack trace of nullpointer exception: Root cause: java.lang.NullPointerException at mypackage.context.DefaultSession.isAuthenticated(DefaultSession.java:69) at mypackage.security.IntranetAuthorizationStrategy.isInstantiationAuthorized(IntranetAuthorizationStrategy.java:33) at org.apache.wicket.Application$1.onInstantiation(Application.java:276) at org.apache.wicket.Application.notifyComponentInstantiationListeners(Application.java:974) at org.apache.wicket.Component.init(Component.java:874) at org.apache.wicket.MarkupContainer.init(MarkupContainer.java:105) at org.apache.wicket.Page.init(Page.java:236) at org.apache.wicket.markup.html.WebPage.init(WebPage.java:184) at org.apache.wicket.security.components.SecureWebPage.init(SecureWebPage.java:48) etc.. DefaultSession.java:69 is: Cookie cookie = ((WebRequest)getRequestCycle()).getCookie(user); Any ideas? thanks Wayne
Re: (WebRequest)getRequestCycle() is always null on first request
Please ignore this, I am being stupid. getRequestCycle() is not available from the session, I had (auto)created that method in my class by mistake... On Tue, Aug 19, 2008 at 10:28 AM, Wayne Pope [EMAIL PROTECTED] wrote: Hi, I've got a problem that I have no idea how to fix. I'm using IAuthorizationStrategy to authenticate the users of my application. However on the first request to the server (WebRequest)getRequestCycle() returns null all the time, so I therefore cannot get an cookies (which I want). This is a real pain. Why is it the case that its null here, but later in the flow its there? Stack trace of nullpointer exception: Root cause: java.lang.NullPointerException at mypackage.context.DefaultSession.isAuthenticated(DefaultSession.java:69) at mypackage.security.IntranetAuthorizationStrategy.isInstantiationAuthorized(IntranetAuthorizationStrategy.java:33) at org.apache.wicket.Application$1.onInstantiation(Application.java:276) at org.apache.wicket.Application.notifyComponentInstantiationListeners(Application.java:974) at org.apache.wicket.Component.init(Component.java:874) at org.apache.wicket.MarkupContainer.init(MarkupContainer.java:105) at org.apache.wicket.Page.init(Page.java:236) at org.apache.wicket.markup.html.WebPage.init(WebPage.java:184) at org.apache.wicket.security.components.SecureWebPage.init(SecureWebPage.java:48) etc.. DefaultSession.java:69 is: Cookie cookie = ((WebRequest)getRequestCycle()).getCookie(user); Any ideas? thanks Wayne
Re: Markup Inheritance - not working for head element
:-) that might be it! Its a none issue really, just would be 'nice to have' On Tue, Aug 19, 2008 at 12:19 PM, Martijn Dashorst [EMAIL PROTECTED] wrote: There is the slight possibility that the wiki is inaccurate. Martijn On Tue, Aug 19, 2008 at 11:52 AM, Wayne Pope [EMAIL PROTECTED] wrote: Hi, I just wanted to check I'm not alone on this, before going to the dev group. I've created a simple base page and markup and using market inheritance I have a child page with the content. This worsd fine, except that Wicket does not interprets head as wicket:head automatically in the child page - as stated on the Wiki. I need to use wicket:head to get it work. Anyone have this working without using wicket:head? -- Become a Wicket expert, learn from the best: http://wicketinaction.com Apache Wicket 1.3.4 is released Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Markup Inheritance - not working for head element
yes good point. On Tue, Aug 19, 2008 at 12:31 PM, Martijn Dashorst [EMAIL PROTECTED] wrote: I think it is a nice *not* to have. If head sections were included automatically, there is no way to distinguish between stuff that is there for design purposes and runtime purposes. Martijn On Tue, Aug 19, 2008 at 12:28 PM, Wayne Pope [EMAIL PROTECTED] wrote: :-) that might be it! Its a none issue really, just would be 'nice to have' On Tue, Aug 19, 2008 at 12:19 PM, Martijn Dashorst [EMAIL PROTECTED] wrote: There is the slight possibility that the wiki is inaccurate. Martijn On Tue, Aug 19, 2008 at 11:52 AM, Wayne Pope [EMAIL PROTECTED] wrote: Hi, I just wanted to check I'm not alone on this, before going to the dev group. I've created a simple base page and markup and using market inheritance I have a child page with the content. This worsd fine, except that Wicket does not interprets head as wicket:head automatically in the child page - as stated on the Wiki. I need to use wicket:head to get it work. Anyone have this working without using wicket:head? -- Become a Wicket expert, learn from the best: http://wicketinaction.com Apache Wicket 1.3.4 is released Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Become a Wicket expert, learn from the best: http://wicketinaction.com Apache Wicket 1.3.4 is released Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: I'm adding a new item to a ListView via ajax - how to get reference to the new item?
HI everyone, thanks very much for your help. So much to learn at the moment so I really appreciate you all helping me out - it takes a while to get to know what you can and can't do with wicket. AjaxRequestTarget.get() worked just fine. On Sun, Aug 17, 2008 at 7:17 PM, Peter Ertl [EMAIL PROTECTED] wrote: use AjaxRequestTarget.get() Am 17.08.2008 um 15:36 schrieb Martin Grigorov: On Sun, 2008-08-17 at 13:36 +0200, Wayne Pope wrote: Hi, But how do I get that target? As the items are being rendered using a ListView - the only time I can get access is during the populateItem - but thats a ListItem, I need a AjexRequestTarget to append the javascript? You could append Javascript at render time (in populateItem(ListItem()) by adding AjaxCallDecorator to your AjaxButton. Or with AttributePrepender/Appender for the 'onclick' AjaxButton attribute On Sun, Aug 17, 2008 at 1:28 PM, Vitaly Tsaplin [EMAIL PROTECTED]wrote: Hi, The item is already on your page so just use its html id in the javascript script you use to highlight it. Vitaly On Sun, Aug 17, 2008 at 1:22 PM, Wayne Pope [EMAIL PROTECTED] wrote: Hi everyone, I have a ListView that displays a list of cars (say). I have a small form on the page whereby they can add a new car using a AjaxFallbackButton. I can enter a new car and it updates the ListView However I want to highlight the newly added item, and I just can't seemt to figure out how I can 'target' the item. I'd like to do something like protected void onSubmit(AjaxRequestTarget target, Form arg1) { // add new car... if (target!=null) { target.addComponent(carList); target.addCompoent(THENEWITEM.addJavascript(new Effect.Highlight(this).toJavascript())); } - the question is how do I get the target reference to the new item added? - 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]
I'm adding a new item to a ListView via ajax - how to get reference to the new item?
Hi everyone, I have a ListView that displays a list of cars (say). I have a small form on the page whereby they can add a new car using a AjaxFallbackButton. I can enter a new car and it updates the ListView However I want to highlight the newly added item, and I just can't seemt to figure out how I can 'target' the item. I'd like to do something like protected void onSubmit(AjaxRequestTarget target, Form arg1) { // add new car... if (target!=null) { target.addComponent(carList); target.addCompoent(THENEWITEM.addJavascript(new Effect.Highlight(this).toJavascript())); } - the question is how do I get the target reference to the new item added?