Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Keep alive method #43

Open
abelrgr opened this issue Nov 27, 2016 · 1 comment
Open

Keep alive method #43

abelrgr opened this issue Nov 27, 2016 · 1 comment

Comments

@abelrgr
Copy link

abelrgr commented Nov 27, 2016

Would be great if there is any way to call a method with a separated time interval to call to an specific service to mantain the backend session alive

Like:

$( document ).idleTimer( {
	keepAlive:{
		timeout: 5000, //every 5 seconds call a determined backend function
		script: 'http://localhost/wakeup.php'
	}
});
@thorst
Copy link
Owner

thorst commented Mar 14, 2018

I have this implemented in my real word example. The various methods of keeping the session alive made me decide to keep it external to the library.

In my situation I have the session renewed automatically every 5 minutes, and then idle timer kills it if inactive for 7 minutes. These are two separate threads if you want to think about it that way.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants