Web Client behavior when accessing solution again

Forum to discuss the Web client version of Servoy.

Web Client behavior when accessing solution again

Postby vincentSchuurhof » Wed Jul 21, 2010 2:34 pm

I have a solution running on the application server which I access through the Web Client. When I am working in that solution and close the browser, the last state the solution was in is displayed again when I reopen it.

What I want is that when I close the browser and reopen the same solution, I need to pass the security again. If I am on someone else's computer and accidently close the browser instead of logging out, somebody else has access to the solution and my data.

I thought about using the onClose method at the solution, but this is tricky since it only works after an amount of time in the Web Client. Is there some way I can force Servoy to restart the solution?
vincentSchuurhof
 
Posts: 26
Joined: Fri Aug 21, 2009 12:39 pm

Re: Web Client behavior when accessing solution again

Postby mboegem » Wed Jul 21, 2010 3:39 pm

Hi Vincent,

problem with a webclient is that a session remains as long as :
a)the browser hasn't been fully quit. (ie. safari on Mac which is often minimized but not quit)
b) the session hasn't timed out yet.

How do you start the solution? Do you use deeplink or pass any arguments when starting?
Marc Boegem
Solutiative / JBS Group, Partner
Servoy Specialist
• Servoy Certified Developer
• Servoy Valued Professional
• Freelance Developer

Image
User avatar
mboegem
 
Posts: 1752
Joined: Sun Oct 14, 2007 1:34 pm
Location: Amsterdam

Re: Web Client behavior when accessing solution again

Postby vincentSchuurhof » Wed Jul 21, 2010 4:12 pm

Yes, you are right about fully closing the browser. Closing a tab (in Firefox at least) doesn't do the trick.

I open the solution by using the link http://<server>:8080/servoy-webclient/solutions/solution/<solution>, so no deeplinking.
vincentSchuurhof
 
Posts: 26
Joined: Fri Aug 21, 2009 12:39 pm

Re: Web Client behavior when accessing solution again

Postby mboegem » Wed Jul 21, 2010 11:53 pm

ok, you could think of writing your own login procedure.
it's less safe, on the other hand it gives you far more control in this case.
Doing so, you need to disable the solutions authentication

Specify a method which will handle startup until login and I think you have what you want.

We've build a support system lately, where we pass in arguments as well.
Based on the arguments we determine what to show, if nothing could be determined then we just quit the solution again.

Hope this helps.
Marc Boegem
Solutiative / JBS Group, Partner
Servoy Specialist
• Servoy Certified Developer
• Servoy Valued Professional
• Freelance Developer

Image
User avatar
mboegem
 
Posts: 1752
Joined: Sun Oct 14, 2007 1:34 pm
Location: Amsterdam

Re: Web Client behavior when accessing solution again

Postby vincentSchuurhof » Wed Jul 28, 2010 5:37 pm

Thanks for the explanation, Marc.

I have been thinking about it and it does makes sense. But what happens when you have accessed the solution by using this method and parameter, close the browser tab and open the solution again by link http://<server>:8080/servoy-webclient/solutions/solution/<solution>? Doesn't Servoy just continues where it left off?
vincentSchuurhof
 
Posts: 26
Joined: Fri Aug 21, 2009 12:39 pm

Re: Web Client behavior when accessing solution again

Postby jcompagner » Wed Jul 28, 2010 5:59 pm

that will show the active client/solution yes.

I guess if really needed we could introduce a property where you can say, if there are no deeplink params, so a "normal" open solution url is given, we will reload it.
You could create a case for this.
Johan Compagner
Servoy
User avatar
jcompagner
 
Posts: 8833
Joined: Tue May 27, 2003 7:26 pm
Location: The Internet

Re: Web Client behavior when accessing solution again

Postby vincentSchuurhof » Fri Jul 30, 2010 1:44 pm

Thanks Johan, that would indeed be a great feature!

I just created a case for this with number 308841.
vincentSchuurhof
 
Posts: 26
Joined: Fri Aug 21, 2009 12:39 pm

Re: Web Client behavior when accessing solution again

Postby sbutler » Sat Jul 31, 2010 4:41 am

Not to hijack this thread, but I also have a similar problem. running 5.2 on the ServoyU server. Basically any of the buttons that do an application.showForm(formName) all break when the below series of events happen. So users can't get into the settings area to upgrade their account. Some of the other buttons work (like playing a video) because they just switch tabs in the main tabpanel. But anything switching the main form breaks whenever the second window gets opened. ideas?

- Open ServoyU: http://app.servoyuniversity.com
- Login
- Open new Window or tab, and go to ServoyU again
- Now Settings link at the top (and several others) break. however videos and tabs at top work because they are just switching tabs in the tabpanel, but settings breaks because it attempts to change the main form.

This also causes the problem:
- Open ServoyU: http://app.servoyuniversity.com
- Login
- Close the window (without quitting the browser)
- Open new Window or tab, and go to ServoyU again
- Now Settings link at the top (and several others) break
Scott Butler
iTech Professionals, Inc.
SAN Partner

Servoy Consulting & Development
Servoy University- Training Videos
Servoy Components- Plugins, Beans, and Web Components
Servoy Guy- Tips & Resources
ServoyForge- Open Source Components
User avatar
sbutler
Servoy Expert
 
Posts: 759
Joined: Sun Jan 08, 2006 7:15 am
Location: Cincinnati, OH

Re: Web Client behavior when accessing solution again

Postby jcompagner » Mon Aug 02, 2010 10:06 am

problem is that what you want is a bit different again.
You do want 2 solutions at the same time active, and even a bit "worse", you want the same solution active twice
And if you show the same form in both tabs (through main or a tabpanel) then that will definitely not work.
Wicket tries to detect a new browser window and that will result in a new mainpage if it goes correct, but if you show the same form in there then that will break the other.

I will try to see if we somehow can fix that, so if you go through the solution loader url (and it is not the current solution with arguments) we could try i we can really create a new client.
Problem is pushing that kind of state to the client, (it must be in every url we generate)
Johan Compagner
Servoy
User avatar
jcompagner
 
Posts: 8833
Joined: Tue May 27, 2003 7:26 pm
Location: The Internet

Re: Web Client behavior when accessing solution again

Postby sbutler » Mon Aug 02, 2010 5:24 pm

I don't actually want a second session/client. I would prefer that it just make the new browser window/tab be the only active one and make the other browser window/tab become inactive. I don't think the user really wants or needs a second session, but it just happens by accident where they close the window or open a new one and don't realize they already had one opened.
Scott Butler
iTech Professionals, Inc.
SAN Partner

Servoy Consulting & Development
Servoy University- Training Videos
Servoy Components- Plugins, Beans, and Web Components
Servoy Guy- Tips & Resources
ServoyForge- Open Source Components
User avatar
sbutler
Servoy Expert
 
Posts: 759
Joined: Sun Jan 08, 2006 7:15 am
Location: Cincinnati, OH

Re: Web Client behavior when accessing solution again

Postby jcompagner » Mon Aug 02, 2010 6:02 pm

if you close a tab and then go through the solution load url, you should see your current solution just fine and it should work just fine.
if you have 2 tabs open that then point to the exact same content, then it can go wrong, because then both are doing there stuff on the same backend.

Problem is that other people do want then a new solution or even that the current one is closed first before going on with the new one..
Johan Compagner
Servoy
User avatar
jcompagner
 
Posts: 8833
Joined: Tue May 27, 2003 7:26 pm
Location: The Internet

Re: Web Client behavior when accessing solution again

Postby sbutler » Mon Aug 02, 2010 7:31 pm

jcompagner wrote:if you close a tab and then go through the solution load url, you should see your current solution just fine and it should work just fine.
if you have 2 tabs open that then point to the exact same content, then it can go wrong, because then both are doing there stuff on the same backend.


Problems is that Both of these are breaking. You can test it out:

-Register for a free account at ServoyU if you don't have one already
- Open ServoyU: http://app.servoyuniversity.com
- Login
- Close the window (without quitting the browser)
- Open new Window or tab, and go to ServoyU again
- Now Settings link at the top (and several others) break

everything else works because it just switches tabs, but the Settings link does an application.showForm, and that doesn't work.
Scott Butler
iTech Professionals, Inc.
SAN Partner

Servoy Consulting & Development
Servoy University- Training Videos
Servoy Components- Plugins, Beans, and Web Components
Servoy Guy- Tips & Resources
ServoyForge- Open Source Components
User avatar
sbutler
Servoy Expert
 
Posts: 759
Joined: Sun Jan 08, 2006 7:15 am
Location: Cincinnati, OH

Re: Web Client behavior when accessing solution again

Postby jcompagner » Tue Aug 03, 2010 9:49 am

i dont know why that it is does contact the server,
and the logout link just right of it works fine..

Wicket does see that you are in a new tab, because you see the extra redirect and the url does change but i have no idea why settings that just wont work.
Johan Compagner
Servoy
User avatar
jcompagner
 
Posts: 8833
Joined: Tue May 27, 2003 7:26 pm
Location: The Internet


Return to Servoy Web Client

Who is online

Users browsing this forum: No registered users and 22 guests

cron