0

max desktop count per session

asked 2009-11-05 07:15:06 +0800

mixgho gravatar image mixgho
193 3

Hi all,

I have

<max-desktops-per-session>1</max-desktops-per-session>

set in my zk.xml file, but i can easily open multiple tabs with the same session.

In my DesktopInit listener i can see, that multiple desktops are created with the same session.

delete flag offensive retag edit

6 Replies

Sort by » oldest newest

answered 2009-11-05 23:23:00 +0800

iantsai gravatar image iantsai
2755 1

yes, but after you create second desktop, does the first one still alive?

link publish delete flag offensive edit

answered 2009-11-06 07:06:08 +0800

mixgho gravatar image mixgho
193 3

updated 2009-11-06 07:07:20 +0800

No :) But wierd is that I can still work with it - page just refreses itself and I can continue in the first tab.
Then I switch to the second tab, I click anywhere, page refreshes and I can work here.

This is kind of strange, isn't it?

If there would be different session in the second tab, wveruthing would be OK from my point of view, because a user would have to login again. But this is strange - both tabs are "active".

In other words, creating a second dekstop in session would fail (binding between session and desktop count).

link publish delete flag offensive edit

answered 2009-11-09 00:54:06 +0800

iantsai gravatar image iantsai
2755 1

I think you misunderstood the meaning of "max-desktops-per-session" .

ZK can't ask JEE web container using different HttpSession to communicate to the broswer, it's out of JEE spec I think.

Currently, if you set max-desktops-per-session = 1, that means only one desktop can survive in one session.
Any other Browser URL request(ex: you press F5) will clean up the old one.

link publish delete flag offensive edit

answered 2009-11-09 01:56:10 +0800

mixgho gravatar image mixgho
193 3

thank you for cleaning up this for me :)
i think i'll have to find other way how to prevent opening multiple tabs in one session.

link publish delete flag offensive edit

answered 2012-01-12 08:53:34 +0800

DaniG gravatar image DaniG
78 1

Hi mixgho.
I know this post is quite old, but as i read it i realized i have the same issue and i can´t figure it out.
Did you solve it? (preventing opening multiple tabs in one session)
Thanks

link publish delete flag offensive edit

answered 2012-01-20 19:12:32 +0800

benbai gravatar image benbai
2228 6
http://www.zkoss.org

Hi DaniG,

I tried it by timer and map, please refer to the Web pages and Maps.java, this sample preventing open multiple page1 and page2 by a user.

Regards,
ben

link publish delete flag offensive edit
Your reply
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

Follow

RSS

Stats

Asked: 2009-11-05 07:15:06 +0800

Seen: 940 times

Last updated: Jan 20 '12

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More