![ServerSync](https://media.forgecdn.net/avatars/thumbnails/254/696/256/256/637199290945083080.png)
Feature Request: Skip unchanged configs
cking opened this issue ยท 29 comments
Serversync Version:
3.1.0
Minecraft Version:
1.15.2
Feature Request:
It would be nice if the server sends a checksum of all config files before syncing them, the client then could compare the remote hashsum with the local one and skip downloading/syncing the file in question.
- Included in alpha release
- Included in full release
Are you meaning directory hashing?
The current sync process sends a hash of the file to the client for them to compare against their file, it only sends the actual file if that comparison fails.
Sounds like its probably a bug if you are getting unchanged config files sent to clients.
Notably the config include list has an issue at the moment where it will always replace the files in said list.
I see a suspicious bit of code here: https://github.com/superzanti/ServerSync/blob/master/src/main/java/com/superzanti/serversync/server/ServerWorker.java#L141
Looks like if the client is doing nothing but replying with "I already have the file" for long enough the server will time it out as it only resets the timeout in the transferFile
method.
To address the original issue, I'll look into ways of speeding up the comparison process.
Created #160 to track the client being timed out by the server.
It is related to configs and mods as far as I know.
I have a player on my server that is sitting behind a 4G router with a slower/unstable connection, and serversync is always trying to sync everything.
For him, I am adding a skip flag to my launcher ( https://github.com/mcz0ne/launcher ) so it doesnt invoke server sync.
https://just.awoo.fun/ups/200319195734391.mp4
thats what she send me yesterday
Interesting, I am seeing a flat crash when trying to sync a second time. Do you have server logs for the recent connections?
https://zerotsu.z0ne.moe/share/serversync-connection.log
this is the connection from said person.
i could upload all serversync logs as well if you need them
Hmm, yeah maybe all of them would be good. That one appears to be a successful sync.
https://zerotsu.z0ne.moe/share/serversync.tar.bz2
there are all serversync* log files in the log folder.
i am running as a seperate application, so it should not insert something into the minecraft/forge log files, right?
Could you send me the latest log from 100-101 please. I get the feeling that the server is timing out the client before it manages to finish.
Also does seem to be taking a rather long time per file to resolve if it is up to date or not.
i sent you everything i have. if you tell me where to find more, then sure, i can send more
https://zerotsu.z0ne.moe/share/seversync-conn-101.log
there is nothing more then that in the log file
its always updating every config file. which is annoyingly slow.
ill be posting the logs once it runs through it a second time.
https://zerotsu.z0ne.moe/share/serversync-client-1.log
https://zerotsu.z0ne.moe/share/serversync-client-2.log
and the server connection for 2nd client log:
https://zerotsu.z0ne.moe/share/serversync-server-connection-from--77-20-255-243.log
Here is the newest connection log of them
Client: https://zerotsu.z0ne.moe/share/ssc-20200322.log
Server: https://zerotsu.z0ne.moe/share/sss-20200322.log
from the client log, you can additionally observe that its deleting mods that shouldnt be deleted as well.
the server version is 3.2.0, client version 3.1.0 - but that shouldnt make a big difference IMO.
i hope this helps.
the server log is a bit corrupted bc they started sync process while i was backing the log up. would be nice if serversync would keep the latest 3 logs or so.
I'm thinking of making a second sync mode that server admins can choose if they wish.
General premise:
- Send entire manifest to client (more memory use, less socket traffic)
- Client side processing of which files need updating
- Request specific files from the server.
This should speed up the sync process when you don't need a full sync significantly.
Hello, i'm facing a similar problem with 3.2.0.
Here are my logs : https://pastebin.com/s02UTieQ
Created #163 to track files being deleted. This tickets focus is speeding up the checking for file changes.
@halfama Is the issue you are seeing long sync times or files being deleted that shouldn't be?
Closing this as v4 has released.
Feel free to open new issues if problems persist.
Early access available for manifest style sync available in the 3.7.0 versions
https://github.com/rheimus/ServerSync/releases