RemoteFunction causing "deadlock" on servers with maxplayers set to 1

So this has been something I’ve been trying to debug for awhile, because it seems to happen at random- but it can occur a lot. I have been able to reproduce it, to a point. Sorry about the wall of text, but I wanted to go into detail of how I found this bug so hopefully a developer can make sense of it.

My place has a max players of 1, with one RemoteFunction. I use this same RemoteFunction for all of my calls to my server from the client. But, at what seems to be at random, when I make a simple call to the server with some information asking for a response, the server completely locks on me.

When I say lock, I mean the server is no longer communicating with my client.

Here is an example, when I click a button wishing to view information about a ‘weapon’, I send a request through a RemoteFunction asking for some simple information about said weapon.

During the request, I hide the button temporarily. Normally, this would happen very fast, but when the server decides to “lock”, it can take up to 2-10 minutes for the server to finally respond. I was baffled at how long this takes, and was confused. When it first happened, I thought something had broken on the server-end so I pressed F9 to open the developer console. When I went to click the ‘server logs’ tab, nothing appeared, at all. The first time you go to open the server logs tab, the client downloads recent logs from the server. This did not happen for me. I then went to open the server stats tab, at which I found to have a very high ping as seen in this screenshot.

After 2-10 minutes the server finally responded, with the information I wanted, and the server logs finally appeared and my ping returned to normal. What happened, though? This is something I’ve been getting PMs about for my game, saying that the button disappears when they go to see weapon information, thinking that it broke, but eventually the button returns after 2-10 minutes. This means it wasn’t just happening to me.

So how do I go about debugging this? Well, the function that receives calls on the server-end is very straight forward, no weird loops or calls. So the first thing I did was start adding up the time the server is taking to process my calls. I simply compared two tick() variables, one at the beginning and one at the end. In order to have the lock occur again, it took a few times rejoining the game (new servers each time) for it to occur.

After finally getting the server to lock me again, I was hoping to see some sort of result from what the server returns from the two tick()'s. After about 5 minutes of waiting for a response to the server (and at the same time, server logs weren’t showing and server stats showed a high ping again), what I got was not what I wanted, as the server simply responded a number that was small (~0.2 seconds). It obviously didn’t take that long, so there must be something on Roblox’s end while processing the call for the RemoteFunction.

I use a similar system for another game (with a higher maxplayers count), but this “locking” bug does not occur at all. So the only difference I am seeing is that this game is set to 1 players max.

In order to reproduce this bug in a simpler setting for a developer to take a look at, I created a new place with maxplayers set to 1. I wrote a simple script with a RemoteFunction where the server returns the time it took to process. Again, after having to rejoin several times the bug finally occurred again and I was able to reproduce the bug in a simple place.

External Media

In this screenshot I had a button do a call to the server. The server responded how long it took to process the call, while the client did its own count. The client had to wait a full 30 seconds for the server to respond, whereas the server thought it only took 0.5 seconds. I was not able to reproduce this bug on servers with a higher player count.

Also, this may have nothing to do with it, but these 1 player servers after the player leaves the server sticks on the player list for about 2 minutes until they seem to time out.

External Media

Here is the place I was able to reproduce the problem: http://www.roblox.com/Stuff-place?id=183384830

Here is a video I started recording when the lock occurred. It took 2 minutes for the server to respond, and as you can see throughout the bug I had a very large amount of ping. https://www.youtube.com/watch?v=-yObn4n8pzM

It only occurs in online mode, and it just happens randomly. It took several times rejoining the game on different servers for it to occur to me. Perhaps it only occurs on certain servers you guys use to host the games, or its just something with the back-end for remotefunctions. This is weird bug, and I hate reporting these kinds of bugs but it’s a problem for a game I want to release where people would have to potentially wait a long time for information to be sent through RemoteFunction’s.

Just wanted to post an update for this. I was hoping maybe anyone could shine a thought on what they think of this.

After simply changing the max players in my game from 1 to 10 (everything is filteredenabled and local anyways) the “deadlock” bug was completely gone and I had not experienced any lag between the server and any of the clients in the game throughout the day of testing.

I believe there is a bug with RemoteFunction. I don’t know the differences internally between a 1 player server and a 10 player server, but the proof is somewhere.

In my screenshot before is a JobId and an IP of the server, so I would assume you guys keep some logs for game servers based on their JobId.

What’s strange is that you’re getting something like this, which is what I get when I brute forced a RemoteEvent.
Are you sure you’re not sending too many RemoteFunction/RemoteEvent requests a second?

oh, and by the way, I got this in Studio.

I’m not able to reproduce the issue. I joined your game about 30 times on my main and 50 times on Guest accounts and the button always flashed.

I can confirm that this happens to my game. I use many RemoteFunctions and RemoteEvents. Check my thread out for more info: Documentation - Roblox Creator Hub (As you read down, my situation gets more and more similar to yours)