Results 1 to 3 of 3
  1. #1
    Member
    Join Date
    Mar 2009
    Location
    Madsrid
    Posts
    7

    Preventing user access after notifyUser call

    Good morning,

    I have implemented notifyUser java method where I check in a database the user/password for a client. If the check fails ( not in my database ) I trigger an AccessException. That works fia but the problem is that after that the javascript client keeps working without any problem. How can I prevent the access for that user after the notifyUSer check ?. Thanks very much in advanced

  2. #2
    Administrator
    Join Date
    Feb 2012
    Location
    Milano
    Posts
    716
    Hi sarbao,

    When the notifyUser method throws an AccessException the Lightstreamer server prevents the client that made the request to successfully establish a working session.
    Without an active session the JavaScript client is unable to make any further request to the server and also to receive any real time data.

    On the client side, you should implement the onServerError event handler of the ClientListener interface in order to handle the case with the desired behavior.
    Please can you confirm that when your metadata Adapter throws the exception the onServerError handler is fired on the client side?

    Regards,
    Giuseppe

  3. #3
    Member
    Join Date
    Mar 2009
    Location
    Madsrid
    Posts
    7
    Thanks very much Giuseppe. I don't know what I did the other day but today is working and the onServerError event is triggered perfectly. Thanks very much for your help. Best regards, SAlavdor

 

 

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT +1. The time now is 03:42 PM.