Re: Is there a way to substitute the application scoped cache?
Thanks Martin. That's very helpful and inspiring. That said, I now think, from web clustering's point of view, it might not be a bad idea to just cluster the page store (which is now in clustered cache) and disable the application scoped cache. (See http://stackoverflow.com/questions/24991767/wicket-cluster-session-store-page-store-data-store) The maximum number of pages (the data store can hold) can be controlled. It would meet our need. Thanks again. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Is-there-a-way-to-substitute-the-application-scoped-cache-tp4676073p4676075.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: Is there a way to substitute the application scoped cache?
Hi, You can create your own IPageManagerProvider that extends from DefaultPageManagerProvider and overrides its #getPageStore() method [1] Then set it in YourApp#init(), like at [2] 1. https://github.com/apache/wicket/blob/936adf7c1658de32cabddfd6acc4994bb3f5ea45/wicket-core/src/main/java/org/apache/wicket/DefaultPageManagerProvider.java#L71 2. https://github.com/apache/wicket/blob/936adf7c1658de32cabddfd6acc4994bb3f5ea45/wicket-core/src/main/java/org/apache/wicket/Application.java#L662 Martin Grigorov Wicket Training and Consulting https://twitter.com/mtgrigorov On Wed, Nov 9, 2016 at 4:39 PM, ygouwrote: > Hi, I'm trying to cluster Wicket web application. I'm using Wicket 6.x. > > In terms of the page store, in our system, all servers now share the http > sessions, while the persistent store is still set to be disk files. (We > prefer not to put persistent store into the session, otherwise the session > size would be too big.) > > Now about the application scoped cache (i.e., the second level cache), we > can control its size (via IStoreSettings.setInmemoryCacheSize()), and so > we > would like to share it across all servers. > > If I understand correctly, the application scoped cache > (SerializedPagesCache) is local and may not be able to be clustered. Is it > possible to re-implement it and inject the new implementation via > configuration, so that the second level cache can be clustered? > > -- > View this message in context: http://apache-wicket.1842946. > n4.nabble.com/Is-there-a-way-to-substitute-the-application- > scoped-cache-tp4676073.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 > >
Is there a way to substitute the application scoped cache?
Hi, I'm trying to cluster Wicket web application. I'm using Wicket 6.x. In terms of the page store, in our system, all servers now share the http sessions, while the persistent store is still set to be disk files. (We prefer not to put persistent store into the session, otherwise the session size would be too big.) Now about the application scoped cache (i.e., the second level cache), we can control its size (via IStoreSettings.setInmemoryCacheSize()), and so we would like to share it across all servers. If I understand correctly, the application scoped cache (SerializedPagesCache) is local and may not be able to be clustered. Is it possible to re-implement it and inject the new implementation via configuration, so that the second level cache can be clustered? -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Is-there-a-way-to-substitute-the-application-scoped-cache-tp4676073.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: DataTable with input columns, refresh values shown in other columns
Hi, I'm assuming you're using Ajax, so you should update the whole row after your behavior/component has changed the field. Each row item has to output a markup id, e.g. you can use a custom Item subclass that calls #setOutputMarkupId(true): protected Item newRowItem(final String id, final int index, final IModel model) { return new RowItem<>(id, index, model); } This has the advantage, that you can update the row from wherever you are inside the row: @Override protected void onUpdate(AjaxRequestTarget target) { RowItem row = findParent(RowItem.class); target.addComponent(row); } Alternatively you can use Wicket event bubbling to notify the rowItem to update itself. Hope this helps Sven Am 09.11.2016 um 09:41 schrieb ganea iulia: Hello, I'm using wicket 7.5. I have a DataTable, where one of the columns is an input textfield with a clickable icon near it. When providing data for the input field, and clicking the icon, some validations are done, and the fields for other columns should be updated accordingly. However they are not updated at all. Could you please advise how I can implement this? Thank you. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
DataTable with input columns, refresh values shown in other columns
Hello, I'm using wicket 7.5. I have a DataTable, where one of the columns is an input textfield with a clickable icon near it. When providing data for the input field, and clicking the icon, some validations are done, and the fields for other columns should be updated accordingly. However they are not updated at all. Could you please advise how I can implement this? Thank you.
Re: WebSocket close is being called if AjaxDownloader is used
Thanks for sharing. I just added a couple of comments/ On Wed, Nov 9, 2016 at 4:23 AM, Maxim Solodovnikwrote: > Hello Martin, > > sorry for the delay > > here is the repo: https://github.com/solomax/wicket-ajax-download > here is the commit with the ajax-download-via-iframe implementation: > https://github.com/solomax/wicket-ajax-download/commit/ > 407936d6f506aa047d9a12a3ecb7aa6c866eb052 > > Looking forward for your comments :) > > On Wed, Nov 9, 2016 at 5:02 AM, Martin Grigorov > wrote: > > Hi Maxim, > > > > Do you have progress on this ? > > > > Martin Grigorov > > Wicket Training and Consulting > > https://twitter.com/mtgrigorov > > > > On Thu, Nov 3, 2016 at 9:46 AM, Maxim Solodovnik > > wrote: > > > >> I was hoping to get answer like: in 7.x you should use .xxx :))) > >> Going to create example on github and will send it for review :) > >> > >> On Thu, Nov 3, 2016 at 3:43 PM, Martin Grigorov > >> wrote: > >> > >> > On Thu, Nov 3, 2016 at 9:40 AM, Maxim Solodovnik < > solomax...@gmail.com> > >> > wrote: > >> > > >> > > It seems iframe is the only option :((( > >> > > > >> > > >> > Why so sad ? > >> > iframe is a good option > >> > > >> > > >> > > here is the JS plugin wrapping this idea: > >> > > http://johnculviner.com/jquery-file-download-plugin- > >> > > for-ajax-like-feature-rich-file-downloads/ > >> > > going to perform additional search > >> > > > >> > > Thanks for the idea! > >> > > > >> > > On Thu, Nov 3, 2016 at 3:36 PM, Ernesto Reinaldo Barreiro < > >> > > reier...@gmail.com> wrote: > >> > > > >> > > > or maybe use a hidden iframe to trigger download... > >> > > > > >> > > > On Thu, Nov 3, 2016 at 9:28 AM, Ernesto Reinaldo Barreiro < > >> > > > reier...@gmail.com> wrote: > >> > > > > >> > > > > I do not know if this is possible but > >> > > > > > >> > > > > 1- Open a new tab > >> > > > > 2- Set location to download URL > >> > > > > 3- Close the new tab > >> > > > > > >> > > > > That way (maybe) page does not close WebSocket connection. It > would > >> > > still > >> > > > > be "AJAX"... > >> > > > > > >> > > > > > >> > > > > On Thu, Nov 3, 2016 at 9:04 AM, Maxim Solodovnik < > >> > solomax...@gmail.com > >> > > > > >> > > > > wrote: > >> > > > > > >> > > > >> I'm afraid It would be not really Ajax . > >> > > > >> > >> > > > >> On Thu, Nov 3, 2016 at 3:03 PM, Ernesto Reinaldo Barreiro < > >> > > > >> reier...@gmail.com> wrote: > >> > > > >> > >> > > > >> > maybe open a second browser tab and do the download there... > >> > > > >> > > >> > > > >> > On Thu, Nov 3, 2016 at 8:51 AM, Maxim Solodovnik < > >> > > > solomax...@gmail.com> > >> > > > >> > wrote: > >> > > > >> > > >> > > > >> > > I'll try to create quick-start ASAP > >> > > > >> > > > >> > > > >> > > On Thu, Nov 3, 2016 at 2:51 PM, Maxim Solodovnik < > >> > > > >> solomax...@gmail.com> > >> > > > >> > > wrote: > >> > > > >> > > > >> > > > >> > > > AjaxDownload was for wicket 1.5.x (or maybe 6.x) > >> > > > >> > > > maybe it can be enhanced to work without unload? > >> > > > >> > > > > >> > > > >> > > > On Thu, Nov 3, 2016 at 2:46 PM, Sven Meier < > s...@meiers.net > >> > > >> > > > wrote: > >> > > > >> > > > > >> > > > >> > > >> AjaxDownload changes the window location - the browser > >> > probably > >> > > > >> > prepares > >> > > > >> > > >> unloading of the page, before opening the attached > download > >> > in > >> > > a > >> > > > >> > > separate > >> > > > >> > > >> window. > >> > > > >> > > >> > >> > > > >> > > >> Sven > >> > > > >> > > >> > >> > > > >> > > >> > >> > > > >> > > >> > >> > > > >> > > >> Am 03.11.2016 um 08:33 schrieb Martin Grigorov: > >> > > > >> > > >> > >> > > > >> > > >>> Hi Maxim, > >> > > > >> > > >>> > >> > > > >> > > >>> I don't see any relation between those. > >> > > > >> > > >>> If it is easy to reproduce please create a quickstart. > >> > > > >> > > >>> > >> > > > >> > > >>> Martin Grigorov > >> > > > >> > > >>> Wicket Training and Consulting > >> > > > >> > > >>> https://twitter.com/mtgrigorov > >> > > > >> > > >>> > >> > > > >> > > >>> On Thu, Nov 3, 2016 at 4:16 AM, Maxim Solodovnik < > >> > > > >> > solomax...@gmail.com > >> > > > >> > > > > >> > > > >> > > >>> wrote: > >> > > > >> > > >>> > >> > > > >> > > >>> Hello, > >> > > > >> > > > >> > > > >> > > Recently we found weird behavior of AjaxDownloader > >> (similar > >> > > to > >> > > > >> this > >> > > > >> > > [1] > >> > > > >> > > one) > >> > > > >> > > For some reason at the moment download is initiated > >> > > > >> > > WebSocketBehavior::onClose is being called > >> > > > >> > > What is the reason for this? > >> > > > >> > > > >> > > > >> > > > >> > > > >> > > https://cwiki.apache.org/confluence/display/WICKET/ > >> > > > >> > > AJAX+update+and+file+download+in+one+blow > >> > > > >> > > > >> > > > >> > > -- > >> > > > >> > > WBR > >> > > > >> > > Maxim aka solomax