eduardosuruagy Posted July 9, 2019 Share Posted July 9, 2019 I'm using Hyperserver and would like to know if it has any way to find out if there is any user logged into the system. I have to update my database and I can only do this without any logged in user. Link to comment Share on other sites More sharing options...
eduardosuruagy Posted August 5, 2019 Author Share Posted August 5, 2019 Does support still work? Link to comment Share on other sites More sharing options...
Hayri ASLAN Posted August 5, 2019 Share Posted August 5, 2019 Hi, You can use mainmodule onCreate and OnDestroy events to save and delete logged user. Quote Sessions Another important difference from classical model is that in classical model your application is able to access all available session objects while in HyperServer each Node can only access sessions which are created by that specific Node. Needless to say that each Node holds a set of sessions which are isolated from other Nodes. If you need to query all of the sessions then you need to use different methods such as saving session information in a database table. You can simply create a row in the table when session is created and remove it when session is freed. Link to comment Share on other sites More sharing options...
eduardosuruagy Posted August 5, 2019 Author Share Posted August 5, 2019 10 minutes ago, Hayri ASLAN said: Oi, Você pode usar os eventos onCreate e OnDestroy do módulo principal para salvar e excluir o usuário logado. I already use this way, and when there is a sudden fall of the internet evebnto is not triggered and the user gets stuck in the table. Link to comment Share on other sites More sharing options...
Hayri ASLAN Posted August 5, 2019 Share Posted August 5, 2019 What is your session timeout? At least end of the timeout you will get onDestroy event for sure Link to comment Share on other sites More sharing options...
eduardosuruagy Posted August 5, 2019 Author Share Posted August 5, 2019 5 minutes ago, Hayri ASLAN said: Qual é o tempo limite de sua sessão? Pelo menos, no final do tempo limite você terá um evento onDestroy com certeza Unfortunately it does not work for me, I will have to be giving select x in x time in the bank to know if there are users logged in? The unigui itself when we put http: \\ app \ server it already shows the amount of users logged in, even using the Hyperserver it shows. So why can't I monitor the amount of users logged into my system? Link to comment Share on other sites More sharing options...
Administrators Farshad Mohajeri Posted August 5, 2019 Administrators Share Posted August 5, 2019 Hi, uniGUI server monitor works in same manner. When a user disconnects from server uniGUI will recognize it only after session timeout interval is passed. Link to comment Share on other sites More sharing options...
eduardosuruagy Posted August 5, 2019 Author Share Posted August 5, 2019 12 minutos atrás, Farshad Mohajeri disse: Oi O monitor do servidor uniGUI funciona da mesma maneira. Quando um usuário se desconecta do servidor, o uniGUI o conecta somente após o intervalo de tempo limite da sessão ser passado. Ok, como você obtém o número de conexões ativas, igual ao selecionado na imagem usando o Hyperserver. Link to comment Share on other sites More sharing options...
Hayri ASLAN Posted August 5, 2019 Share Posted August 5, 2019 Hi, It shows peak. It means the maximum active session record at one time. It doesn't reflect current active session count. Link to comment Share on other sites More sharing options...
eduardosuruagy Posted August 5, 2019 Author Share Posted August 5, 2019 Honestly, I give up asking for that. Thank you for your help!! Link to comment Share on other sites More sharing options...
Administrators Farshad Mohajeri Posted August 6, 2019 Administrators Share Posted August 6, 2019 Currently, there is no API in uniGUI that can give you that number. As said before, you must set a DB table and keep track of sessions inside that Table. Do you have a problem with this method? Link to comment Share on other sites More sharing options...
donlego Posted August 6, 2019 Share Posted August 6, 2019 8 minutes ago, Farshad Mohajeri said: Currently, there is no API in uniGUI that can give you that number. As said before, you must set a DB table and keep track of sessions inside that Table. Do you have a problem with this method? http://forums.unigui.com/index.php?/topic/12861-hyperserver-the-best-way-to-clear-a-session-on-database-when-the-web-server-restarts-or-the-server-restarts/ Link to comment Share on other sites More sharing options...
picyka Posted January 15, 2022 Share Posted January 15, 2022 Em 06/08/2019 às 10h07, Farshad Mohajeri disse: Atualmente, não há API no uniGUI que possa lhe dar esse número. Como dito anteriormente, você deve definir uma tabela DB e acompanhar as sessões dentro dessa Tabela. Você tem algum problema com este método? In current versions, is it already possible to get the users logged into the hyperserver? Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now