Re: 6.0.0-beta2 IClusterable
Hi, It is moved from o.a.w.util to o.a.w.core.util package. This was part of the fix for OSGi-friendliness. And yes, it is OK to use java.io.Serializable instead. IClusterable is a special interface for the integration with Terracotta. On Thu, Jun 14, 2012 at 2:52 AM, Rafał Krupiński r.krupin...@gmail.com wrote: Hi What happened to IClusterable interface? It's missing both from jar and from wiki page on migration :-) Is it OK to simply replace it with Serializable? -- Pozdrawiam / Best Regards Rafal Krupinski - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Wicket as Jboss Modules
Hi, Well done! Let us know if there are any problems with this shared usage. On Thu, Jun 14, 2012 at 4:57 AM, Илья Нарыжный phan...@ydn.ru wrote: Finally I did it! As jboss module I created 2 modules: wicket and wicketstuff. Configuration: ?xml version=1.0 encoding=UTF-8? module xmlns=urn:jboss:module:1.0 name=org.apache.wicket resources resource-root path=wicket-core-1.5.7.jar/ resource-root path=wicket-request-1.5.7.jar/ resource-root path=wicket-auth-roles-1.5.7.jar/ resource-root path=wicket-extensions-1.5.7.jar/ resource-root path=wicket-datetime-1.5.7.jar/ resource-root path=wicket-util-1.5.7.jar/ /resources dependencies module name=org.apache.commons.collections/ module name=javaee.api/ module name=org.jboss.logging/ module name=org.jboss.as.web/ module name=org.slf4j/ /dependencies /module and ?xml version=1.0 encoding=UTF-8? module xmlns=urn:jboss:module:1.0 name=org.wicketstuff resources resource-root path=wicketstuff-autocomplete-tagit-1.5.5.jar/ resource-root path=wicketstuff-tinymce-1.5.5.jar/ resource-root path=jazzy-0.5.2-rtext-1.4.1.jar/ /resources dependencies module name=org.apache.commons.collections/ module name=org.apache.wicket/ module name=org.slf4j/ !--module name=org.springframework export=true/-- /dependencies /module But I found that wicketstuff-anotation can't be organized as a module because in class org.wicketstuff.config.MatchingResources in method getClass page class is constructed in current classloader. I would like to recommend to rewrite this class in a way when classloader for corresponding initial application is used. File an issue in WicketStuff issue tracker. Send a Pull Request with the fix too ;-) Thanks, Ilia 2012/6/13 Martin Grigorov mgrigo...@apache.org: Good point! https://issues.apache.org/jira/browse/WICKET-4604 On Wed, Jun 13, 2012 at 9:31 AM, Igor Vaynberg igor.vaynb...@gmail.com wrote: we have to be sure we do not use any static fields anywhere in the code...it's not just the singletons that break this use case. eg we do not want caches to be shared across applications because it's not performant and can result in cross application object leakage. -igor On Tuesday, June 12, 2012, Martin Grigorov wrote: Hi, Wicket uses ThreadLocal for the Application, Session and RequestCycle. There are no JVM singletons. Some people are against putting jars in the shared lib folder. I personally see the benefit and I'd do it if I need to If you use shared jars then make sure that none of the applications provide these jars or another version of them because in this case you will see some ClassLoader related problems, e.g.: ClassCastException: o.a.w.Session class is not o.a.w.Session. On Tue, Jun 12, 2012 at 11:04 PM, Martin Sachs sachs.mar...@gmail.comjavascript:; wrote: Hello, i think that is in general not a good idea. If you deploy the wicket-lib outside the war and run multiple Wicket-Applications, then you could not use all applications, because wicket stores (as far as i know) e.g. the application instance in a static field. There is one application per WAR-deployment with wicket, but if you use the libs from ear/lib or modules there will be only one application. best Martin Илья Нарыжный schrieb: Hello, I have several projects which use wicket and various wicket sun-modules. Every project (*.ear file) took about 10Mb and about 8Mb is for wicket libraries. Recently I have move my projects to Jboss AS 7 and now I'm thinking about putting all wicket related jars to JBOSS_HOME/modules. Have anyone tried that? Do you have some suggestions for Jboss module structure for this? It will be great to have IMPLICIT( https://docs.jboss.org/author/display/AS7/Implicit+module+dependencies+for+deployments ) deploy of wicket related jars to the project. Thanks, Ilia - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.orgjavascript:; For additional commands, e-mail: users-h...@wicket.apache.orgjavascript:; - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.orgjavascript:; For additional commands, e-mail: users-h...@wicket.apache.orgjavascript:; -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org javascript:; For additional commands, e-mail: users-h...@wicket.apache.orgjavascript:; -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com - To unsubscribe, e-mail:
Re: using links in feedback panels
Hi, You can extend FeedbackPanel and add a AttributeModifier(onclick, ...) to the Label that is used for the feedback message. Use plain JavaScript to focus the form component. This will be easier and better for the user experience. On Wed, Jun 13, 2012 at 11:04 PM, Carter, Isaac isaac.car...@mantech.com wrote: Does anyone know if it's possible to have an error message in a feedback panel link to the error that caused it? Such as the user has filled in a given number of fields and puts in the wrong data in one field...an error message is presented in a feedback paneluser clicks on the error message and it takes them directly to the field that contains the error. That's the scenario I have in mind. Suggestions anyone? Thanks, Isaac Carter This e-mail and any attachments are intended only for the use of the addressee(s) named herein and may contain proprietary information. If you are not the intended recipient of this e-mail or believe that you received this email in error, please take immediate action to notify the sender of the apparent error by reply e-mail; permanently delete the e-mail and any attachments from your computer; and do not disseminate, distribute, use, or copy this message and any attachments. -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: PackageResourceBlockedException after migration to 6.0.0-beta2
Hi, Please create a quickstart and attach it to Jira. Both 1.5.7 and 6.0.0-beta2 should behave the same way. For some reason the mounted page doesn't match and Wicket tries to serve this url with Resource mapper and thus it makes the security check ... On Thu, Jun 14, 2012 at 4:08 AM, Rafał Krupiński r.krupin...@gmail.com wrote: I've just changed wicket dependency from 1.5.6 to 6.0.0-beta2 and s/IClusterable/Serializable/ ...and this is what I got: Unexpected RuntimeException Last cause: Access denied to (static) package resource com/hashnot/nbp. See IPackageResourceGuard Root cause: org.apache.wicket.request.resource.PackageResource$PackageResourceBlockedException: Access denied to (static) package resource com/hashnot/nbp. See IPackageResourceGuard at org.apache.wicket.request.resource.PackageResource.internalGetResourceStream(PackageResource.java:459) [snip] This is the situation: mypackage.MyApplication{ void init(){ mountPage(nbp, MyPage.class) //other similar mounts } } mypackage.BasePage{ //base Page with links to all mounted pages } mypackage.nbp.MyPage extends BasePage{} (and of course the markup) All links between mounted pages are handled by BasePage class and its markup. From the BasePage's point of view there is page mounted under nbp and a subpackage nbp. After I changed the mount from nbp to nbp-rates it started working, so it looks like in case of conflicting mount-path and relative package name there is a regression: * in 1.5.x linking to X meant linking to mounted page * in 6.0 it means linking to package Can someone confirm it? -- Pozdrawiam / Best Regards Rafal Krupinski - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: stateless resources vs. no cookies
Hi, Wicket creates temporary o.a.w.Session object only if Session.get() is called during the request lifecycle. Until you call Session().get().bind() no javax.servlet.HttpSession will be created and Wicket's Session will be garbage collected at the end of the request processing. On Wed, Jun 13, 2012 at 10:39 PM, Jan Loose jan.lo...@cleverlance.com wrote: Hi, I found this problem in Wicket 1.4.20 if cookies are disabled. If there is used a stateless resource then no jsessionid is rendered. It is removed on the line 390 of the class WebRequestCodingStrategy. I hope this is OK. Once the browser makes a request to this resource, then there is created a new session, because there is no jsessionid - neither defined by cookie nor defined by the URL. The class RequestLogger, line 229 - from my point of view the method 'requestTime' shouldn't work with the session in this case. The class WicketFilter, line 1197 - if the resource is cacheable then the session is obtained, why? The problem is that there is no session because no jsessionid is defined. What is the reason for this? Does anyone have any idea how to fix it/do a workaround? Thank you very much, Jan - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: example to avoid pagemap locks
Hi, You can put the search result (and the start of the search process) into a Panel and wrap this with a AjaxLazyLoadPanel. Not sure about the cancel thing. At least you can have a look at the AjaxLazyLoadPanel for inspiration. Regards Bert On Thu, Jun 14, 2012 at 7:34 AM, fachhoch fachh...@gmail.com wrote: One of my page is a search page this sometimes gets stuck because the users search criteria is time consuming and I get page map is still locked error. To avoid this I want to modify this page to use a job to execute the search in a thread and a timer to check every 5 second 's if search is complete and option to cancel the search (job). If user does not like to wait. Are there any examples of this kind ? -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/example-to-avoid-pagemap-locks-tp4649956.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
Re: Wicket as Jboss Modules
given that I have not dug deep into the contract that JBoss promises for jar Files in the JBOSS_HOME/modules folder, I'd still be quite surprised that putting the jars into a shared folder would imply that the class instances created from those jars would be shared between applications on a single JBoss container. Isn't it the responsibility of the container to keep separate class instances for each application it is running? mf 2012/6/13 Martin Grigorov mgrigo...@apache.org Hi, Wicket uses ThreadLocal for the Application, Session and RequestCycle. There are no JVM singletons. Some people are against putting jars in the shared lib folder. I personally see the benefit and I'd do it if I need to If you use shared jars then make sure that none of the applications provide these jars or another version of them because in this case you will see some ClassLoader related problems, e.g.: ClassCastException: o.a.w.Session class is not o.a.w.Session. On Tue, Jun 12, 2012 at 11:04 PM, Martin Sachs sachs.mar...@gmail.com wrote: Hello, i think that is in general not a good idea. If you deploy the wicket-lib outside the war and run multiple Wicket-Applications, then you could not use all applications, because wicket stores (as far as i know) e.g. the application instance in a static field. There is one application per WAR-deployment with wicket, but if you use the libs from ear/lib or modules there will be only one application. best Martin Илья Нарыжный schrieb: Hello, I have several projects which use wicket and various wicket sun-modules. Every project (*.ear file) took about 10Mb and about 8Mb is for wicket libraries. Recently I have move my projects to Jboss AS 7 and now I'm thinking about putting all wicket related jars to JBOSS_HOME/modules. Have anyone tried that? Do you have some suggestions for Jboss module structure for this? It will be great to have IMPLICIT( https://docs.jboss.org/author/display/AS7/Implicit+module+dependencies+for+deployments ) deploy of wicket related jars to the project. Thanks, Ilia - 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 -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Wicket as Jboss Modules
The classes are shared, not the instances. The same classloader loads JBoss' modules for all apps. This is what Igor meant with 'static caches'. If you have a static field then it is also shared for all apps. On Thu, Jun 14, 2012 at 11:27 AM, Martin Funk mafulaf...@googlemail.com wrote: given that I have not dug deep into the contract that JBoss promises for jar Files in the JBOSS_HOME/modules folder, I'd still be quite surprised that putting the jars into a shared folder would imply that the class instances created from those jars would be shared between applications on a single JBoss container. Isn't it the responsibility of the container to keep separate class instances for each application it is running? mf 2012/6/13 Martin Grigorov mgrigo...@apache.org Hi, Wicket uses ThreadLocal for the Application, Session and RequestCycle. There are no JVM singletons. Some people are against putting jars in the shared lib folder. I personally see the benefit and I'd do it if I need to If you use shared jars then make sure that none of the applications provide these jars or another version of them because in this case you will see some ClassLoader related problems, e.g.: ClassCastException: o.a.w.Session class is not o.a.w.Session. On Tue, Jun 12, 2012 at 11:04 PM, Martin Sachs sachs.mar...@gmail.com wrote: Hello, i think that is in general not a good idea. If you deploy the wicket-lib outside the war and run multiple Wicket-Applications, then you could not use all applications, because wicket stores (as far as i know) e.g. the application instance in a static field. There is one application per WAR-deployment with wicket, but if you use the libs from ear/lib or modules there will be only one application. best Martin Илья Нарыжный schrieb: Hello, I have several projects which use wicket and various wicket sun-modules. Every project (*.ear file) took about 10Mb and about 8Mb is for wicket libraries. Recently I have move my projects to Jboss AS 7 and now I'm thinking about putting all wicket related jars to JBOSS_HOME/modules. Have anyone tried that? Do you have some suggestions for Jboss module structure for this? It will be great to have IMPLICIT( https://docs.jboss.org/author/display/AS7/Implicit+module+dependencies+for+deployments ) deploy of wicket related jars to the project. Thanks, Ilia - 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 -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: After 1 minute the Pagemap null is still locked by: Thread how to kill this request ?
I am still facing this problem root cause of my issues are database related, it takes time time to respond what can I do to avoid pagemap lock? can I set timeout for all my pages in a global way ? Please advice. I saw this post http://apache-wicket.1842946.n4.nabble.com/Removing-Pagemap-lock-post-1-5-td3387575.html I am using wicket 1.4.12 , using wicket 1.5.1 or above will resolve this problem? or is there any hack in wicket 1.4.xx Please advice. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/After-1-minute-the-Pagemap-null-is-still-locked-by-Thread-how-to-kill-this-request-tp4565091p4649966.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
Re: After 1 minute the Pagemap null is still locked by: Thread how to kill this request ?
See org.apache.wicket.settings.IRequestCycleSettings#setTimeout() On Thu, Jun 14, 2012 at 11:50 AM, fachhoch fachh...@gmail.com wrote: I am still facing this problem root cause of my issues are database related, it takes time time to respond what can I do to avoid pagemap lock? can I set timeout for all my pages in a global way ? Please advice. I saw this post http://apache-wicket.1842946.n4.nabble.com/Removing-Pagemap-lock-post-1-5-td3387575.html I am using wicket 1.4.12 , using wicket 1.5.1 or above will resolve this problem? or is there any hack in wicket 1.4.xx Please advice. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/After-1-minute-the-Pagemap-null-is-still-locked-by-Thread-how-to-kill-this-request-tp4565091p4649966.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 -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Wicket as Jboss Modules
Just read SRV.9.7.1 Dependencies On Extensions in the servlet 2.5 specs. Obviously my assumption was wrong... mf 2012/6/14 Martin Grigorov mgrigo...@apache.org The classes are shared, not the instances. The same classloader loads JBoss' modules for all apps. This is what Igor meant with 'static caches'. If you have a static field then it is also shared for all apps. On Thu, Jun 14, 2012 at 11:27 AM, Martin Funk mafulaf...@googlemail.com wrote: given that I have not dug deep into the contract that JBoss promises for jar Files in the JBOSS_HOME/modules folder, I'd still be quite surprised that putting the jars into a shared folder would imply that the class instances created from those jars would be shared between applications on a single JBoss container. Isn't it the responsibility of the container to keep separate class instances for each application it is running? mf 2012/6/13 Martin Grigorov mgrigo...@apache.org Hi, Wicket uses ThreadLocal for the Application, Session and RequestCycle. There are no JVM singletons. Some people are against putting jars in the shared lib folder. I personally see the benefit and I'd do it if I need to If you use shared jars then make sure that none of the applications provide these jars or another version of them because in this case you will see some ClassLoader related problems, e.g.: ClassCastException: o.a.w.Session class is not o.a.w.Session. On Tue, Jun 12, 2012 at 11:04 PM, Martin Sachs sachs.mar...@gmail.com wrote: Hello, i think that is in general not a good idea. If you deploy the wicket-lib outside the war and run multiple Wicket-Applications, then you could not use all applications, because wicket stores (as far as i know) e.g. the application instance in a static field. There is one application per WAR-deployment with wicket, but if you use the libs from ear/lib or modules there will be only one application. best Martin Илья Нарыжный schrieb: Hello, I have several projects which use wicket and various wicket sun-modules. Every project (*.ear file) took about 10Mb and about 8Mb is for wicket libraries. Recently I have move my projects to Jboss AS 7 and now I'm thinking about putting all wicket related jars to JBOSS_HOME/modules. Have anyone tried that? Do you have some suggestions for Jboss module structure for this? It will be great to have IMPLICIT( https://docs.jboss.org/author/display/AS7/Implicit+module+dependencies+for+deployments ) deploy of wicket related jars to the project. Thanks, Ilia - 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 -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: PackageResourceBlockedException after migration to 6.0.0-beta2
On Thu, Jun 14, 2012 at 8:20 AM, Martin Grigorov mgrigo...@apache.org wrote: Hi, Please create a quickstart and attach it to Jira. Both 1.5.7 and 6.0.0-beta2 should behave the same way. For some reason the mounted page doesn't match and Wicket tries to serve this url with Resource mapper and thus it makes the security check ... #WICKET-4607 -- Pozdrawiam / Best Regards Rafal Krupinski - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: After 1 minute the Pagemap null is still locked by: Thread how to kill this request ?
by default its supposed to timeout after 1 minute , but whenever my pagemap is locked only way to call new resource is close the browser relogin as if new session. Please advice me. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/After-1-minute-the-Pagemap-null-is-still-locked-by-Thread-how-to-kill-this-request-tp4565091p4649970.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
Re: After 1 minute the Pagemap null is still locked by: Thread how to kill this request ?
In 1.5+ it should release the lock when your DB operation finishes. I guess it should be the same in 1.4.x. On Thu, Jun 14, 2012 at 4:32 PM, fachhoch fachh...@gmail.com wrote: by default its supposed to timeout after 1 minute , but whenever my pagemap is locked only way to call new resource is close the browser relogin as if new session. Please advice me. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/After-1-minute-the-Pagemap-null-is-still-locked-by-Thread-how-to-kill-this-request-tp4565091p4649970.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 -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: After 1 minute the Pagemap null is still locked by: Thread how to kill this request ?
if my dboperation is pending and taking long time, there is now way I can call another resource ? -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/After-1-minute-the-Pagemap-null-is-still-locked-by-Thread-how-to-kill-this-request-tp4565091p4649973.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
Re: After 1 minute the Pagemap null is still locked by: Thread how to kill this request ?
run such slow operations in a separate thread in 1.5+ the lock is per page instance so you can just start a new page (i.e. remove the ?pageId ffrom the url) and all will be fine. In 1.4 I guess you need to use a different pageMap. The default pageMap is null. I.e. you need to provide a non-null one: ?wicket:pageMapName=blah On Thu, Jun 14, 2012 at 4:51 PM, fachhoch fachh...@gmail.com wrote: if my dboperation is pending and taking long time, there is now way I can call another resource ? -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/After-1-minute-the-Pagemap-null-is-still-locked-by-Thread-how-to-kill-this-request-tp4565091p4649973.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 -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: After 1 minute the Pagemap null is still locked by: Thread how to kill this request ?
Maybe you should think about an asynchronous approach, i.e. poll the state of your long-time-backend-operation e.g. by using an AjaxSelfUpdatingTimerBehavior. -Tom On 14.06.2012 at 15:51 fachhoch wrote: if my dboperation is pending and taking long time, there is now way I can call another resource ? - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: After 1 minute the Pagemap null is still locked by: Thread how to kill this request ?
I cannot run this in seperate thread becasue this could happen in anypage not just one page , all my pages uses db operations and for some reason once in a while some db operation takes time and the page is stuck.Please tell more on using a different pagemap . I encode all my urls. can I provide a link in my basepage through which this link is accessible to all pages ,can you provide me simple code waht should be called in onclick ? Thanks a lot for you support. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/After-1-minute-the-Pagemap-null-is-still-locked-by-Thread-how-to-kill-this-request-tp4565091p4649976.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
Detach Model Objects when user leaves page
Hi, i have a list view with content from a Repository that is input to a wicket DataProvider with ModelObject. I get the content of the repository from a webservice. I don't want to load the data from the webservice after each request, but the model gets detached after each request and accordingly my Repository (which is connected to the webservice) is empty after each request (because its objects are set to null in the detachment process). Now, is there a way to influence a LoadableDetachableModel in a way that it gets detached after the user leaves the page/accesses another page. I tried to overwrite the detach-method but without success. As a workaround i'm using the session to store my repository but then i don't have an indication when the data isn't needed any more. I think about time based expiration of session data (time based cache mechanism like in guava library), but i think this is rather cumbersome. Detaching the model object after the user leaves the page would be more elegant. Thanks for any suggestions or hints how you fixed this scenario. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Detach-Model-Objects-when-user-leaves-page-tp4649977.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
Re: Detach Model Objects when user leaves page
How would you notice if the user leaves the page? If you have only Wicket controlled Links on your page then you could null your Repository data in their onclick() implementation (if you do a setResponsePage(someOtherPage). If there's also non-Wicket links on your page, well, you would probably have to use some JS magic (+ AJAX) to react upon page leave event. I don't like either of those solutions but would prefer a cache including expiry strategy instead. About how much data are we talking here? Isn't it possible to do some kind of paging or do you need to fetch the whole dataset? -Tom On 14.06.2012 at 16:57 brazz wrote: Hi, i have a list view with content from a Repository that is input to a wicket DataProvider with ModelObject. I get the content of the repository from a webservice. I don't want to load the data from the webservice after each request, but the model gets detached after each request and accordingly my Repository (which is connected to the webservice) is empty after each request (because its objects are set to null in the detachment process). Now, is there a way to influence a LoadableDetachableModel in a way that it gets detached after the user leaves the page/accesses another page. I tried to overwrite the detach-method but without success. As a workaround i'm using the session to store my repository but then i don't have an indication when the data isn't needed any more. I think about time based expiration of session data (time based cache mechanism like in guava library), but i think this is rather cumbersome. Detaching the model object after the user leaves the page would be more elegant. Thanks for any suggestions or hints how you fixed this scenario. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: on click on a label in a listview - onClicke method never used localy
add ajaxeventbehavior to the label On Thu, Jun 14, 2012 at 8:57 PM, oliver.stef ova...@gmail.com wrote: Hi, i want to use a label inside listView and i want the user will press on the label - and the onClick method will work. but what i get is this msg.: The method onClick() from the type new Label(){} is never used locally. I don't know why?!?!?!?!?! this is my implement: List list = Arrays.asList(new String[] { a, b, c }); @SuppressWarnings(unchecked) ListView listview = new ListView(listview, list) { protected void populateItem(ListItem item) { String s = (String)item.getModelObject(); item.add(new Label(label, item.getModel()) { private static final long serialVersionUID = 1L; private void onClick() { System.out.println(Hello); } } ); } }; add(listview); thanks! -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/on-click-on-a-label-in-a-listview-onClicke-method-never-used-localy-tp4649981.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 -- thanks, Vineet Semwal - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Detach Model Objects when user leaves page
Hi Thomas, thanks for your reply. Data is not that much, but i think it's no good practice to have data in memory that is not used any more. So i'd like to have a general solution to this. Your right, the user could leave the page by any means. But for me it would be enough to discard the data when the user goes to one of my (other) wicket pages. Maybe i should have a look at the seam framework which adresses conversation scope... -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Detach-Model-Objects-when-user-leaves-page-tp4649977p4649982.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
Re: on click on a label in a listview - onClicke method never used localy
currently what you have done is you have defined *your own* method so it never gets used up unless you yourself use it. On Thu, Jun 14, 2012 at 9:05 PM, vineet semwal vineetsemwa...@gmail.com wrote: add ajaxeventbehavior to the label On Thu, Jun 14, 2012 at 8:57 PM, oliver.stef ova...@gmail.com wrote: Hi, i want to use a label inside listView and i want the user will press on the label - and the onClick method will work. but what i get is this msg.: The method onClick() from the type new Label(){} is never used locally. I don't know why?!?!?!?!?! this is my implement: List list = Arrays.asList(new String[] { a, b, c }); @SuppressWarnings(unchecked) ListView listview = new ListView(listview, list) { protected void populateItem(ListItem item) { String s = (String)item.getModelObject(); item.add(new Label(label, item.getModel()) { private static final long serialVersionUID = 1L; private void onClick() { System.out.println(Hello); } } ); } }; add(listview); thanks! -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/on-click-on-a-label-in-a-listview-onClicke-method-never-used-localy-tp4649981.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 -- thanks, Vineet Semwal -- thanks, Vineet Semwal - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: on click on a label in a listview - onClicke method never used localy
Label does not have an onClick() method, so nobody will be calling your onClick() ;) If you want to attach AJAX behavior to the label you should do the following: final Label label = new Label(label, item.getModel()); label.add(new AjaxEventBehavior(click) { @Override protected void onEvent(AjaxRequestTarget target) { // do something } }); item.add(label); On 14.06.2012 at 17:27 oliver.stef wrote: Hi, i want to use a label inside listView and i want the user will press on the label - and the onClick method will work. but what i get is this msg.: The method onClick() from the type new Label(){} is never used locally. I don't know why?!?!?!?!?! this is my implement: List list = Arrays.asList(new String[] { a, b, c }); @SuppressWarnings(unchecked) ListView listview = new ListView(listview, list) { protected void populateItem(ListItem item) { String s = (String)item.getModelObject(); item.add(new Label(label, item.getModel()) { private static final long serialVersionUID= 1L; private void onClick() { System.out.println(Hello); } } ); } }; add(listview); thanks! - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
CompoundPropertyModel problem.. the values are not refreshing
Below are my files HTML input type=text id=firstName name=firstName wicket:id=firstName value= size=20 maxlength=10 / input type=text id=lastName name=lastName wicket:id=lastName value= size=20 maxlength=20 / Bean Customer.java - getters/setters for firstName and lastname Component.java - On URL getting the firstname and lastNames as page parameters Customer customer = new Customer(); CompoundPropertyModelCustomer compoundPropertyModel = new CompoundPropertyModelCustomer (customer ); final Form? addCardForm= new FormCreditCard(addCardForm,compoundPropertyModel); customer.setFirstName(parameters.get(firstName).toString()); customer.setLastName(parameters.get(lastName).toString()); final TextField firstName = new TextField(firstName); final TextField lastName = new TextField(lastName); addCardForm.add(firstName ); addCardForm.add(lastName); add(addCardForm); Here the Problems: 1) Once I load the file with URL : localhost:8080/addcard?firstName=ramlastName=babu, the first name and last name displaying fine but if I change the firstName and lastName in same browser URL like localhost:8080/addcard?firstName=ravilastName=suri, the old values(ram,babu) only displaying in form fields(First Name and Last Name) 2) The form has AjaxSubmitLink- once I load the page with ram and babu, changed the first name ram to raj, and clicked submit button. if the page has any error the error message is writing to feed back panel but the First name is changing to old value that is ram. Is It problem with CompoundPropertyModel or cache probelm.. please suggest me the solution. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/CompoundPropertyModel-problem-the-values-are-not-refreshing-tp4649987.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
Re: CompoundPropertyModel problem.. the values are not refreshing
Could you please provide a Quickstart that describes your problem? This will make it much easier for us to help you. -Tom - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: on click on a label in a listview - onClicke method never used localy
Thanks vineetsemwal and Thomas Götz-2 , but still - not working :( -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/on-click-on-a-label-in-a-listview-onClicke-method-never-used-localy-tp4649981p4649989.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
Re: Detach Model Objects when user leaves page
Thanks for the link! I think i will give this one a try: https://www.42lines.net/2011/11/15/integrating-cdi-into-wicket/ -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Detach-Model-Objects-when-user-leaves-page-tp4649977p4649990.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
FeedbackPanel inside TabbedPanel does not render
Hi, I'm using Wicket 6 beta-2 and have a problem, that my feedback panel inside a TabbedPanel tab panel is not rendered. Even if i set output markupid to true, the tag is not rendered. The only way i have managed to get it to show, is by adding dummy error messages manually. If I do so, my actual messages appear next to the dummy one. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/FeedbackPanel-inside-TabbedPanel-does-not-render-tp4649991.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
validation without form
Hi, I am trying to validate 2 fields(one is a text field and the other is a select) that the user can enter and select. This is inside of a bigger form. I would not want to use a form to validate these fields. Can you let me know how I can validate these fields without doing a form submit? Thank you -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/validation-without-form-tp4649992.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
Re: CompoundPropertyModel problem.. the values are not refreshing
1) In form have 2 text fields, 1) First Name and 2) Last Name. On page load populating the values with request parameters like https:localhost:8080/addcard?firstName=ramlastName=babu. after loading the page with first name and last name field, modified the first name text field with raj , clicked submit button. got the error on page ( have some mandatory fields in the page) and displayed the error on feed back panel but the first name text field changed to old value (ram). it should be raj... 2) after loading the page withurl https:localhost:8080/addcard?firstName=ramlastName=babu . I have changed the URL like https:localhost:8080/addcard?firstName=ravilastName=babu in same browser and clicked enter but the first name text field value populating with old value ram not with ravi. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/CompoundPropertyModel-problem-the-values-are-not-refreshing-tp4649987p4649993.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
Re: CompoundPropertyModel problem.. the values are not refreshing
What Wicket version? BTW a quickstart would enable us to help you. Sven On 06/14/2012 05:45 PM, ramlael wrote: Below are my files HTML input type=text id=firstName name=firstName wicket:id=firstName value= size=20 maxlength=10 / input type=text id=lastName name=lastName wicket:id=lastName value= size=20 maxlength=20 / Bean Customer.java - getters/setters for firstName and lastname Component.java - On URL getting the firstname and lastNames as page parameters Customer customer = new Customer(); CompoundPropertyModelCustomer compoundPropertyModel = new CompoundPropertyModelCustomer(customer ); final Form? addCardForm= new FormCreditCard(addCardForm,compoundPropertyModel); customer.setFirstName(parameters.get(firstName).toString()); customer.setLastName(parameters.get(lastName).toString()); final TextField firstName = new TextField(firstName); final TextField lastName = new TextField(lastName); addCardForm.add(firstName ); addCardForm.add(lastName); add(addCardForm); Here the Problems: 1) Once I load the file with URL : localhost:8080/addcard?firstName=ramlastName=babu, the first name and last name displaying fine but if I change the firstName and lastName in same browser URL like localhost:8080/addcard?firstName=ravilastName=suri, the old values(ram,babu) only displaying in form fields(First Name and Last Name) 2) The form has AjaxSubmitLink- once I load the page with ram and babu, changed the first name ram to raj, and clicked submit button. if the page has any error the error message is writing to feed back panel but the First name is changing to old value that is ram. Is It problem with CompoundPropertyModel or cache probelm.. please suggest me the solution. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/CompoundPropertyModel-problem-the-values-are-not-refreshing-tp4649987.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
Re: validation without form
you can add ajaxformcomponentupdatingbehavior to them On Thu, Jun 14, 2012 at 10:10 PM, srinash avisrid...@gmail.com wrote: Hi, I am trying to validate 2 fields(one is a text field and the other is a select) that the user can enter and select. This is inside of a bigger form. I would not want to use a form to validate these fields. Can you let me know how I can validate these fields without doing a form submit? Thank you -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/validation-without-form-tp4649992.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 -- thanks, Vineet Semwal - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: validation without form
Thanks for the reply. Can you please direct me to some examples. Sri -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/validation-without-form-tp4649992p4649996.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
Re: validation without form
formcomponent.add(validator) formcomponent.add(new ajaxformcomponentupdatingbehavior(the_event){ protected void onError(AjaxRequestTarget target, RuntimeException e){ target.add(feedback); } protected abstract void onUpdate(AjaxRequestTarget target){ target.add(feedback)} } for more concrete example look into the wicket examples that comes with the distribution On Thu, Jun 14, 2012 at 11:04 PM, srinash avisrid...@gmail.com wrote: Thanks for the reply. Can you please direct me to some examples. Sri -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/validation-without-form-tp4649992p4649996.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 -- thanks, Vineet Semwal - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: validation without form
thank you , will take a look Sri -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/validation-without-form-tp4649992p4649998.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
Re: CompoundPropertyModel problem.. the values are not refreshing
Wicket 1.5 -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/CompoundPropertyModel-problem-the-values-are-not-refreshing-tp4649987p464.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
Re: on click on a label in a listview - onClicke method never used localy
What exactly is not working? If you could provide a Quickstart it would be easier to help you. -Tom - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
wicket portlet 1.5 and liferay 6.1
For those who are having troubles making wicket-portlet works with liferay 6.1, here's the solution... I've many wicket 1.4 application that are just working fine in liferay 6.0. But when I put them in liferay 6.1, I get the following message : /20:49:12,379 ERROR [BasePortalLifecycle:45] java.lang.IllegalArgumentException: Error initializing WicketFilter - you have no filter-mapping element with a url-pattern that uses filter: TestApplication java.lang.IllegalArgumentException: Error initializing WicketFilter - you have no filter-mapping element with a url-pattern that uses filter: TestApplication / This is because liferay 6.1 remove the filter and filter-mapping from the web.xml. To prevent this behaviour, you have to add the following properties in your liferay-plugin-package.properties : *liferay-web-xml-enabled=false* By the way if you're using wicket 1.5, you will have the following error instead : /20:48:09,343 WARN [WebXmlFile:265] web.xml: No url-pattern found for 'filter' with name 'wicket.test' 20:48:09,343 INFO [WebXmlFile:113] web.xml: url mapping found for filter with name wicket.test: 20:48:09,343 WARN [WicketFilter:247] Unable to determine filter path from filter init-parm, web.xml, or servlet 3.0 annotations. Assuming user will set filter path manually by calling setFilterPath(String) / Good luck to all liferay users! -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/wicket-portlet-1-5-and-liferay-6-1-tp4650001.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