• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
redis driver _get_lock set lock_key problem

#11
(09-12-2018, 10:02 AM)jimpannell Wrote:
Code:
session_start([
   'read_and_close' => true,
]);

Is that something to try or am I completely on the wrong track?

If you never intend on writing any session data that would work. Chances are that's not what you want. For the route that you're pinging every 1s go to the controller method and add session_write_close(); after the last session write. Reads can be below this but no other writes can be. That will free the lock before execution ends once all your writes are complete. If that route doesn't write any session data put the close at the very top of the method (assuming you're autoloading the session driver). Generally you're going to want to manually close the session everywhere once writes are done especially in routes you AJAX to.

This is noted in the users guide: https://www.codeigniter.com/user_guide/l...oncurrency
Reply


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


Users browsing this thread:
1 Guest(s)


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2018 MyBB Group.