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

Can the timer be turned off; or, can it be shown on the game? #7

Open
cyberkev63 opened this issue Aug 24, 2020 · 7 comments
Open

Can the timer be turned off; or, can it be shown on the game? #7

cyberkev63 opened this issue Aug 24, 2020 · 7 comments

Comments

@cyberkev63
Copy link

I tend to be a slower player. (I like to think of it as "more thoughtful"...) [grin]
I ran into an issue in an online multiplayer with a friend where the game was canceled just as I was about to end a round.
Can the timer be turned off, or set longer?
Or, can it be shown on the game?
Or, at least, can we know what the timer is set to?
(Otherwise, great implementation of the game, by the way!)

@ondras
Copy link
Owner

ondras commented Aug 24, 2020

Hi @cyberkev63,

sorry for your game that got canceled. I understand it must have been unpleasant.

I had a look in the source code to discover that the server automatically closes games that have been idle for 10 minutes. I suppose I could increase that to 20 or 30, what do you think?

@cyberkev63
Copy link
Author

Sorry to be slow to reply! Thank you for getting back to me (and so quickly)!
Nice to know the current value of the timer.
Part of the reason for the delay was that we were playing the Lakes Expansion for the first time, so there was even more to think about and get used to.
I am all for increasing the timer to 20 or 30 minutes! In general, I think the more the better (just to be safe), and I can't immediately think of a downside in the current environment of the game for making it 30 minutes (which should clearly be more than enough).
I hope that you will reply here if you make the change, so that interested players will know what to expect.
And, again, thank you for this cool implementation of the game!

@ondras
Copy link
Owner

ondras commented Aug 27, 2020

Hi @cyberkev63,

I have adjusted the timeout to 30 minutes.

I am not closing this issue ATM, becasue updating the code revealed the following Deno issue that is currently preventing me from commiting the fix. Will close once this gets resolved.

And, again, thank you for this cool implementation of the game!

Thanks!

@grybykm
Copy link

grybykm commented Oct 24, 2023

@ondras denoland/deno#7217 is now resolved.

@ondras
Copy link
Owner

ondras commented Oct 25, 2023

@ondras denoland/deno#7217 is now resolved.

Great!

Now onto the issue. The concept of the "garbage collection timer" is necessary, because if we want to enable re-connects, we cannot simply erase the game once all players have disconnected. On the other hand, I see no performance-related reason to pick the timer interval value that is so small that it limits the player experience.

The timer obviously prevents memory hogs and DoS attacks, but these have been - so far, fortunately - purely theoretical aspects. I would suggest setting the timer to a value that is high enough that it does not limit anyone: an hour? two? a day? Suggestions?

(I see no real point in displaying the value, though: it changes often and is an implementation detail; players should not be bothered by its existence.)

@grybykm
Copy link

grybykm commented Oct 26, 2023

I'd personally like it to be a day.
I think there are different other ways to perform the DoS attacks even with a very small timeout limit.

@ondras
Copy link
Owner

ondras commented Oct 29, 2023

I'd personally like it to be a day.

A day it is then! @cyberkev63 would you find this value sufficient?

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

3 participants