Calling all F.A.Q. requests....

34 views
Skip to first unread message

drthink

unread,
Jun 30, 2010, 9:28:40 PM6/30/10
to GWTP
Hi,

I am compiling a list of FAQs for GWTP. As a newbie to the project I
thought this might be a good exercise for me to get to grips with the
framework but also contribute in some meaningful way.

Therefore I am posting an announcement here for any FAQ questions you
think should go into this page?

Cheers
G

Jay

unread,
Jul 2, 2010, 3:18:14 AM7/2/10
to GWTP
Well, for me, I wish that there were more documentation for server
side, working with dispatch within a traditional web server, which I
mean working with Tomcat with database (mySQL or Postgres). Currently,
also of examples focus on App Engine, which is a plus, but I would
like get more input for best practices such as persistence, and user
authorization. There has been a few questions towards login, and using
the ActionValidator and Cookies within the forum. Also, related to
this question is that because app engine uses UserServices, also of
new developers find it difficult to understand how to perform these
tasks such as cookies, security, etc.

Christian Goudreau

unread,
Jul 2, 2010, 10:20:53 AM7/2/10
to gwt-pl...@googlegroups.com
Secury with ActionValidator is only a matter of saying : Can HE do this action ?

The HE is up to you to indentify the user with cookies and to set up some user restrictions based on whatever security you use. Like I do in AppEngine, I'm creating a User Object that contains his right and some informations. When an action is executed, I'm checking the user right.

If you don't use AppEngine, simply use HttpSession.  

You can then identify the user with the session Id or create one yourself. Cookie work in the same way, use standard Http request.

With guice, you can easily inject HttpSession, HttpServletRequest and HttpServletResponse anywhere in server side.

Since there's a lot of ways to identify someone (OpenID, homeMade, facebook connect, etc, etc...) How to is really something that can't be easily answered but I hope what I said can help you. I recall that users using spring security asked this questions 2-3 times. Unfortunatly, the answer is the same as above since I never used it... yet :)

Regards,

Christian
--
Christian Goudreau

PhilBeaudoin

unread,
Jul 6, 2010, 3:15:13 AM7/6/10
to GWTP
I've started looking at the FAQ page, drthink. Looking good! I've
edited it to remove the undesirable wiki links on CamelCase words.
What I do:
- Prefix it with ! if it's not code (i.e. !AppEngine)
- Use the inline code notation if it's code (i.e. `PresenterWidget`)

Here are some questions I can think of based on my own experience with
the framework:
- Should my ginjector method to return an Provider<MyPresenter> or an
AsyncProvider<MyPresenter>?
- What is a good way of disabling browser navigation when a modal
dialog is displayed?
- How do I choose between onReveal() and onReset()?
- How can I use two leaf Presenter on the same page? (i.e. the link
column bar and the main content)

Thanks again for doing this, it's much appreciated.

Cheers,

Philippe

On Jul 2, 7:20 am, Christian Goudreau <goudreau.christ...@gmail.com>
wrote:
> Secury with ActionValidator is only a matter of saying : Can HE do this
> action ?
>
> The HE is up to you to indentify the user with cookies and to set up some
> user restrictions based on whatever security you use. Like I do in
> AppEngine, I'm creating a User Object that contains his right and some
> informations. When an action is executed, I'm checking the user right.
>
> If you don't use AppEngine, simply use HttpSession.http://tomcat.apache.org/tomcat-5.5-doc/servletapi/javax/servlet/http...
>
> You can then identify the user with the session Id or create one yourself.
> Cookie work in the same way, use standard Http request.
>
> With guice, you can easily inject HttpSession, HttpServletRequest and
> HttpServletResponse anywhere in server side.http://code.google.com/p/google-guice/wiki/ServletModule

Gene Conroy-Jones

unread,
Jul 6, 2010, 11:09:03 AM7/6/10
to GWTP
Philippe,

Thanks for the heads up. Great tips was wondering how to get rid of
those ?'s in the text.

I am going to work through the questions over the coming weeks so will
probably be asking some questions in here.

I also got your note about contributing to the project in code form.
I would be very interested in doing that, just waiting to get more
familiar with the framework before I investigate.

Out of interest I added a Google Wave Discussion Thread, here:
https://wave.google.com/wave/waveref/googlewave.com/w+ZB23zxzcA

I haven't really had an opportunity to use Wave but it might be
interesting to try it out for discussing GWTP that isn't relevant in
this forum.

Cheers
Gene

Cheers
Gene

Philippe Beaudoin

unread,
Jul 6, 2010, 11:16:16 AM7/6/10
to gwt-pl...@googlegroups.com
Good idea, add me to the wave:
philippe...@googlewave.com

Philippe

Christian Goudreau

unread,
Jul 6, 2010, 11:18:28 AM7/6/10
to gwt-pl...@googlegroups.com
You don't need to be added, just follow the link :D

Christian
--
Christian Goudreau

Philippe Beaudoin

unread,
Jul 6, 2010, 11:19:59 AM7/6/10
to gwt-pl...@googlegroups.com
Guess what, I did. :) I get the following message:
"You are not a participant in this wave."

Christian Goudreau

unread,
Jul 6, 2010, 11:21:05 AM7/6/10
to gwt-pl...@googlegroups.com
Then I wonder why I was LOL

Christian
--
Christian Goudreau

Gene Conroy-Jones

unread,
Jul 6, 2010, 6:25:40 PM7/6/10
to GWTP
Ok Try again. I added a public wave user to make it public, but
apparently it was the wrong one.

https://wave.google.com/wave/waveref/googlewave.com/w+ZB23zxzcA

Let me know how you get on with that one.

Cheers
Gene

On Jul 6, 8:21 am, Christian Goudreau <goudreau.christ...@gmail.com>
wrote:
> Then I wonder why I was LOL
>
> Christian
>
> On Tue, Jul 6, 2010 at 11:19 AM, Philippe Beaudoin <
>
>
>
>
>
> philippe.beaud...@gmail.com> wrote:
> > Guess what, I did. :)  I get the following message:
> > "You are not a participant in this wave."
>
> > On Tue, Jul 6, 2010 at 8:18 AM, Christian Goudreau
> > <goudreau.christ...@gmail.com> wrote:
> > > You don't need to be added, just follow the link :D
> > > Christian
>
> > > On Tue, Jul 6, 2010 at 11:16 AM, Philippe Beaudoin
> > > <philippe.beaud...@gmail.com> wrote:
>
> > >> Good idea, add me to the wave:
> > >> philippe.beaud...@googlewave.com
>
> > >> Philippe
>
> > >> On Tue, Jul 6, 2010 at 8:09 AM, Gene Conroy-Jones <
> > drgenejo...@gmail.com>
Reply all
Reply to author
Forward
0 new messages