REMINDER: Apache EU Roadshow 2018 in Berlin is less than 2 weeks away!

2018-05-31 Thread sharan

Hello Apache Supporters and Enthusiasts

This is a reminder that our Apache EU Roadshow in Berlin is less than 
two weeks away and we need your help to spread the word. Please let your 
work colleagues, friends and anyone interested in any attending know 
about our Apache EU Roadshow event.


We have a great schedule including tracks on Apache Tomcat, Apache Http 
Server, Microservices, Internet of Things (IoT) and Cloud Technologies. 
You can find more details at the link below:


https://s.apache.org/0hnG

Ticket prices will be going up on 8^th June 2018, so please make sure 
that you register soon if you want to beat the price increase. 
https://foss-backstage.de/tickets


Remember that registering for the Apache EU Roadshow also gives you 
access to FOSS Backstage so you can attend any talks and workshops from 
both conferences. And don’t forget that our Apache Lounge will be open 
throughout the whole conference as a place to meet up, hack and relax.


We look forward to seeing you in Berlin!

Thanks
Sharan Foga,  VP Apache Community Development

http://apachecon.com/
@apachecon

PLEASE NOTE: You are receiving this message because you are subscribed 
to a user@ or dev@ list of one or more Apache Software Foundation projects.


Re: Paint UI before starting long running tasked

2018-05-31 Thread Zbynek Vavros
I did used a nasty way by using AjaxLazyLoadPanel and providing my custom
loading as both - lazy load component (with code in renderHead) and loading
component (empty renderHead) . Not the most elegant way but from user point
of view its ideal :)

Zbynek

On Thu, May 31, 2018, 16:25 Martin Grigorov  wrote:

> On Wed, May 30, 2018 at 6:00 PM, Zbynek Vavros 
> wrote:
>
> > Hey,
> >
> > this is weird, I can see the Ajax loading during renderHead() processing
> > and then switch to my loading.
> >
> > Maybe I could describe what I'm doing in more details (with
> > AjaxLazyLoadPanel  being used):
> > Loader from AjaxLazyLoadPanel is displayed.
> > Remote REST is being called, response from REST is passed to JS function
> -
> > at this moment my panel is rendered.
> > JS then calls remote service via websocket, receives response, passed
> that
> > response to Wicket JS callback function.
> > This calls yet another REST endpoint and saves result into DB.
> >
> > After that I replace my loading with success message.
> >
> > I would like to "ideally" have all this covered by single loading panel.
> >
>
> You will need to create a custom Panel to do all this.
> I guess you can still use AjaxLazyLoadPanel if you use Java WebSocket
> client, but this is something you have to decide.
>
>
> >
> > Zbynek
> >
> >
> > On Wed, May 30, 2018 at 3:32 PM, Martin Grigorov 
> > wrote:
> >
> > > Hi,
> > >
> > > Do you use AjaxLazyLoadPanel for the loading image + result panel ?
> > > You can move your #renderHead() logic to the result panel's
> renderHead().
> > >
> > > On Wed, May 30, 2018 at 3:05 PM, Zbynek Vavros  >
> > > wrote:
> > >
> > > > Hi,
> > > >
> > > > I got a wizard and one of its steps display loading image while
> > > > processing long running task. After this task JavaScript is being
> > called.
> > > >
> > > > I've put the code into render renderHead() method of the step itself:
> > > >
> > > > @Override
> > > > public void renderHead(IHeaderResponse response) {
> > > > // process task
> > > > String taskResult = ...
> > > > // call JavaScript with result
> > > > response.render(OnDomReadyHeaderItem.forScript("jsFunction(" +
> > > > taskResult + ")"));
> > > > }
> > > >
> > > > When I click the NEXT button, this long running task is executed
> before
> > > > the step with loading image is rendered.
> > > > I guess I need to move the code somewhere else than renderHead() but
> > > where?
> > > >
> > > > Thanks,
> > > > Zbynek
> > > >
> > >
> >
>


Re: Paint UI before starting long running task

2018-05-31 Thread Martin Grigorov
On Wed, May 30, 2018 at 6:00 PM, Zbynek Vavros 
wrote:

> Hey,
>
> this is weird, I can see the Ajax loading during renderHead() processing
> and then switch to my loading.
>
> Maybe I could describe what I'm doing in more details (with
> AjaxLazyLoadPanel  being used):
> Loader from AjaxLazyLoadPanel is displayed.
> Remote REST is being called, response from REST is passed to JS function -
> at this moment my panel is rendered.
> JS then calls remote service via websocket, receives response, passed that
> response to Wicket JS callback function.
> This calls yet another REST endpoint and saves result into DB.
>
> After that I replace my loading with success message.
>
> I would like to "ideally" have all this covered by single loading panel.
>

You will need to create a custom Panel to do all this.
I guess you can still use AjaxLazyLoadPanel if you use Java WebSocket
client, but this is something you have to decide.


>
> Zbynek
>
>
> On Wed, May 30, 2018 at 3:32 PM, Martin Grigorov 
> wrote:
>
> > Hi,
> >
> > Do you use AjaxLazyLoadPanel for the loading image + result panel ?
> > You can move your #renderHead() logic to the result panel's renderHead().
> >
> > On Wed, May 30, 2018 at 3:05 PM, Zbynek Vavros 
> > wrote:
> >
> > > Hi,
> > >
> > > I got a wizard and one of its steps display loading image while
> > > processing long running task. After this task JavaScript is being
> called.
> > >
> > > I've put the code into render renderHead() method of the step itself:
> > >
> > > @Override
> > > public void renderHead(IHeaderResponse response) {
> > > // process task
> > > String taskResult = ...
> > > // call JavaScript with result
> > > response.render(OnDomReadyHeaderItem.forScript("jsFunction(" +
> > > taskResult + ")"));
> > > }
> > >
> > > When I click the NEXT button, this long running task is executed before
> > > the step with loading image is rendered.
> > > I guess I need to move the code somewhere else than renderHead() but
> > where?
> > >
> > > Thanks,
> > > Zbynek
> > >
> >
>


Re: How to use language/locale from url without creating a session?

2018-05-31 Thread Bas Gooren
Thank you, Martin! That’s an interesting way to fix this.


Didn’t think of that, and it fits quite well with our current code, too. We
can put our own “requestedLocale” field in our WebSession subclass, and use
that if the session is temporary.


Thanks!

Met vriendelijke groet,
Kind regards,

Bas Gooren

Op 26 mei 2018 bij 13:41:25, Martin Grigorov (mgrigo...@apache.org) schreef:

Hi,

Here is another solution:
- put the locale in RequestCycle's metadata
- override Session#getLocale() and if Session#isTemporary() then use the
metadata, otherwise use the session's locale

On Fri, May 25, 2018 at 7:20 PM, Bas Gooren  wrote:

> Hi!
>
> We build mainly e-commerce websites on wicket, which means most pages are
> publicly visible and indexable.
> Since our websites are multi-language we have a custom
> CompoundRequestMapper which checks if the url contains a valid locale,
and
> updates the session locale accordingly.
>
> This works great! With one small issue we would ideally like to fix:
wicket
> binds the session once you call setLocale on it. As a result, every
> (stateless) public url that is requested leads to a session being
created,
> and a cookie being sent to the requester.
>
> Since every component (effectively) depends on Session.get().getLocale()
to
> get the current locale, we see no other way to handle this cleanly.
>
> Writing this now and having another look at the wicket source code, I
> reckon we could wrap the wicket request and override its getLocale()
> method. I probably hesitated to do so before because wicket expects a
> ServletWebRequest in some places, so the wrapper cannot simply extend the
> base Request class.
> Anyone here that has a good solution for this? Otherwise we have to check
> for implementations and decide on the wrapper based on that, but that’s
> rather ugly code.
>
> Also, I realize that we don’t just want to wrap the request for request
> mapping purposes (in our compound mapper). We need to wrap the request
> earlier, since we need to ensure the actual request passed in to the
> session constructor returns a locale that matches with the url.
>
> Would appreciate any thoughts you have on this.
>
> Thanks!
>
> Met vriendelijke groet,
> Kind regards,
>
> Bas Gooren
>


Re: wicketstuff datatabes /jQuery Datatables

2018-05-31 Thread Martin Grigorov
Hi,

Please check the example.
https://github.com/wicketstuff/core/blob/1fa257603ed918d54a32f0e92bd949aa86afb65c/datatables-parent/datatables-examples/src/main/java/org/wicketstuff/datatables/demo/infiniteScroll/VirtualScrollDemoResourceReference.java#L38
Here you can use the page parameters to filter out or paginate the result.

On Thu, May 31, 2018 at 9:41 AM, trlt  wrote:

> Hi,
>
> I'm using DemoDatatable in wicketstuff package to develop a table with fair
> amount of data (>= 10,000 rows) to display.  Can anyone point me to the
> right direction as how to implement this with server side processing?  I've
> already implemented a SortableDataProvider, but I am not too sure how to
> invoke it in my program.
>
> --
> Sent from: http://apache-wicket.1842946.n4.nabble.com/Users-forum-
> f1842947.html
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


wicketstuff datatabes /jQuery Datatables

2018-05-31 Thread trlt
Hi,

I'm using DemoDatatable in wicketstuff package to develop a table with fair
amount of data (>= 10,000 rows) to display.  Can anyone point me to the
right direction as how to implement this with server side processing?  I've
already implemented a SortableDataProvider, but I am not too sure how to
invoke it in my program.

--
Sent from: http://apache-wicket.1842946.n4.nabble.com/Users-forum-f1842947.html

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



wicketstuff datatabes /jQuery Datatables

2018-05-31 Thread trlt
Hi,

I'm using DemoDatatable in wicketstuff package to develop a table with large
amount of data (>= 10,000 rows) to display.  Can anyone point me to the
right direction as how to implement server side processing?  I've already
implemented a SortableDataProvider, but I am not too sure how to invoke it
in my program.

--
Sent from: http://apache-wicket.1842946.n4.nabble.com/Users-forum-f1842947.html

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org