MineColonies

MineColonies

53M Downloads

Suggestion: LoadAllBackups

Patrick-van-Halm opened this issue ยท 14 comments

commented

Hey devs,

So I currently have an issue where it deletes clears the colonies everytime. I can load them with the backup /mc colony loadBackup colony: 1 dimension: 0 but if there are 100 colonies for instance its a bit hard to load them all. So my suggestion is can you make a command that loads all the backups something like /mc colonies loadBackup It would be very apreciated

commented

i would suggest that we fix the underlying issue instead, why are all your colonies being cleared? what version are you using? got some logs?

commented

I agree that server owners/managers need a FULL backup option. There are way too many instances and problems that will cause the issue. From other mods to simple power failure. It is a pain to have to run the backup one by one on a server. It's best to have a command like:
/mc colony loadBackup ALL
F.e. that server owners/managers can run when restoring a full world issue.

commented

I am putting a veto in for that kind of command.

In all honesty I should have never ever put in a command to reset the RS. Everybody and their aunt is using it to try to fix all kinds of bugs, 99% have nothing to do with the RS. The consequence of this command is already that a lot of bugs stay hidden and never get reported.

Adding a command like this has several side effects that I really do not want.
The argument is that this would be used by server admins, but how often do you have to reset ALL, and then i mean ALL colonies, i have never ever seen a single admin that needed to do that, not on our servers, not on any server. So from my perspective even if I take the "masking issues" argument of the table, there is no reason to add it. Yes it happens more often then we like that you have to run a reset on 1 or more colonies, and yes @Raycoms has been fixing a lot of issues with the capabilities not behaving properly, but that is of the past, and with automatically growing colonies coming, I personally think that a lot of these issues will disappear.
Secondly as already stated a command like this does not help with the current culture of not PROPERLY reporting issues and bugs. Yes i know that we get a lot of bug reports, but, especially lately, most of them just say: "worker X is not doing what he is supposed to" without further explanation or anyway we can reproduce said issue reliably, and i do not think it is a good idea to nurture this culture and behaviour even further by giving people a way to magically fix any bug for a couple of hours and then it appears again.

So from a Admin and primary Developers perspective, and I think @Raycoms agrees with me. This is issue is hereby closed. The OP @Patrick-van-Halm is free to reopen the issue if he does not agree, but we highly recommend him to create a proper issue stating his problem, describing his system. Telling us how he shutsdown, what is common between the times the issue occurs etc.

commented

This is not about the RS reset, this is about loading colonies from backup case a crash broke the colony capability and we want to load them from backup.

commented

We should probably wrap the writing to NBT of the colonies into a try and catch block so that one failure doesn't cause a universal failure.

commented

@Raycoms See that is the problem. You do not know that. If his system crashed and corrupted the NBT I would like to see that in his report. He is free to open up a proper Issue stating his problem so we can see how to fix it, and in that context we can add a command to load all colonies.

Allthough I find this highly unlikely that every single colony is corrupt since it is stored with the world, which would mean the world would be corrupt.

commented

We have had this issue recently on the Cavecolonies server, as well as ( a long while ago) on the official minecolonies server.
There are many many reasons that a world gets corrupted and the only way to restore the Colonies is to do it with the command. Doing this manually to restore over 100+ is a real pain and if there is a command that does it and just needs an ALL instead of individually.
I have had to do it at least twice, once on each server due to the lack of the command.
There have been server owners that have asked the same question and had the same issue: World Corrupted, for w/e reason.

commented

@Wissi Then why the hell was that never actually properly reported internally?!?!?!?!?

commented

@OrionDevelopment not sure what the "internal process to properly report it" is.
Raycoms has known about it every time and the most recent one (cavecolonies world corrupt when the "issues" from Strato work denied all access). I went over the issue and solutions with Ray and asked for a full "ALL" command for server, but was basically told... meehh "deal w/it as is..." it's not a common situation and too much code/issues to code it are needed.
So when someone else finally made the Issue here I backed it up.

commented

In more detail Raycoms Thoughts:

yep, unfortunately, that's not so easy because I don't know what ids to restore.

They are listed... can't a small JSOn file be created and used for that purpose (maybe other purposes as well)?

the thing is two things:
a) Deleted colonies are also listed
b) We have to load the chunks of the buildings to set the building data

I mean populate a JSON (or text file) everytime a Town is created with it's ID and when deleted, removed from the file?
Then when the /mc colony loadbackup ALL is executed it parses through that list of ID's?

commented

@Wissi Okey, i discussed this with ray, yesterday. And as I stated to ray, yes I understand the need. But no i do not think this is a good way to get such a command in.

As for internal ways of reporting, you are part of the damn LDT Discord, there was not a single mention there on anything, just reporting this to ray and asking for a command to ease your problem is not getting anything fixed nor implemented.

We got away from storing stuff externally for good reasons, and maybe those have not been so clear, but that does not mean we should go back to them.
A JSON does not fix the problem, what fixes the problem is players and server admins a like, creating at least an issue report, stating hey, i did X and now all my colonies are gone, so that we can investigate and find the issue. In that context we can POSSIBLY add a command that deals with loading a specific set of backups, or allow the existing command to load ranges of ids.

That said, to make this clear, i am not entirely opposed to adding the command. I am however entirely opposed to adding the command to solve this issue this way, in particular since this issue does not follow our explicitly stated issue template, that we created for a reason, and in my eyes should have been closed with a pointer to that and not discussed further.

On internal issues like the one described: Either create a Github Issue, or post in #general of the LDT Discord. Or the #Bugs channel in the LDT Discord would be a great place.

Also @Raycoms Why did you not damn report it to either GitHub or #Bugs so that we could triage this. Keeping these kinds of bugs to your self gets nothing fixed by anyone of us. So, what do we do now?

commented

@Patrick-van-Halm just the explain the problem here in a short way:

  • This bug recently happened the first time on our server but was mostly related to server side issues so we didn't dig into this since it has not been reported before (since we added the new colony storage).
  • You made a report for a workaround for an issue which you had on every world startup seemingly but actually the way to go would have been you reporting the failure to load the colonies on each startup and providing us with a log so that we can find a way to fix it.

We have the single colony command since a single colony not loading is a problem which can occur case it gets corrupted or similar, this affecting other colonies is something rarer. And this occurring regularly is really something that shouldn't happen ever.

Could you please open an issue for the issue of colonies not loading at all on restart and providing us with the following logs:

  • Startup log
  • Shutdown log
    (Or the log of a complete cycle)
commented

@Raycoms the issue is locked, he can't respond (and i don't know if he can see that either)

commented

He can see it. And I do not think it is a good idea that he answers here. He should create a new issue.