Goodbye CoreProtect, Hello Oasis

Telesphoreo

System Administrator
Forum Administrator
Executive
Developer
402
IGN
Telesphoreo
Hey everyone,

We've migrated from CoreProtect to a new in-house solution called Oasis. This thread documents everything you need to know including why we're switching and the new command syntax.

Why

CoreProtect has historically us for years. However, given TotalFreedom's chaotic environment, CoreProtect's performance was not cutting it. For example, one griefer put 78 million rows into the database, and it took nearly 40 minutes to roll these changes back. This was after I spent about six hours trying to make CoreProtect cope with large rollbacks. However, I was unsuccessful for many reasons and decided a brand new plugin built from the ground up was better. Oasis came out of a 24 hour+ coding marathon. It does the three things we care about: rollbacks that finish in seconds no matter how big the history is, minimal impact on server performance, and commands you do not need a cheat sheet for.

What came over

I ran the migration from CoreProtect to Oasis tonight. All of the data from CoreProtect came over with some caveats.
  • Edits that were already rolled back in CoreProtect were left out. There were a lot of them, about two thirds of all block edits, which obviously tells you we handle a lot of griefers. They are not in lookups any more.
  • Chest contents and sign text from the old data are not restorable. CoreProtect never stored them, so a rollback puts the block back but not what was in it. I am happy to say this won't be a problem going forward as items logged from tonight on will have their NBT and other data stored.
  • Mob kills show in lookups but a rollback cannot bring the mob back. Same reason. This will not be a constraint going forward.
  • This does not include data from the old 2024 server.

I still have the old CoreProtect database for now, so if you find something odd in the history, tell me and I can check it against the original.

The commands

The commands are the same idea, just without the flag soup. There is no u:, t:, r:, a:. You write a word and then its value, in any order. If you forget a word or don't know which to use, we have simple to follow tab completions and they work on all commands. One really cool feature is that you can hover over the tab completions to see what it means. Obviously, this is dependent on if your client supports it as older clients may not. Here's an example:
VbaHmrPpcR.png

The main commands:
CommandShortWhat it does
/inspect/insclick blocks to see who changed them
/lookup .../losearch the history
/rollback .../rbundo what players did
/restore .../rsput back what a rollback removed
/undoreverse the last operation you ran

The words you put after them:
WordWhat it takesExample
userwhose edits, also actors like #fire, #water, #explosionuser Steve
lasthow far back: 10m, 2h, 1d, daylast 2h
olderolder thanolder 30d
nearblocks around younear 50
ina world, or sel for your WorldEdit selectionin world_nether
blocka block or item, with * as a wildcardblock *_sign
causewhat happened: breaking, placing, explosion, fire, worldedit, sign...cause explosion
kindblocks, containers, entities, items, chat, commands, sessions, bookskind containers
notleaves out the next block, cause, or kindnot cause worldedit
pagenext page of your last lookuppage 2

Here is the part most of you actually want, side by side with what you used to type:
CoreProtectOasis
/co i/inspect
/co l u:Steve t:2h r:50/lookup user Steve last 2h near 50
/co l r:20 t:10m/lookup near 20 last 10m
/co rollback u:Steve t:2h r:100/rollback user Steve last 2h near 100
/co rollback u:Steve r:#global/rollback user Steve
/co rollback t:1h r:#worldedit/rollback in sel last 1h
/co rollback u:Steve e:worldedit/rollback user Steve not cause worldedit
/co rollback a:explosion r:200/rollback cause explosion near 200
/co restore u:Steve t:2h/restore user Steve last 2h
/co l u:Steve a:chat/lookup kind chat user Steve
/co l u:Steve a:command/lookup kind commands user Steve
/co l u:Steve a:session/lookup kind sessions user Steve
/co l u:Steve b:diamond/lookup user Steve block diamond
/co purge t:30dstaff cannot purge, ask me

Some things that are new and worth knowing:
  • If you leave out user, the rollback will run for every player who matches, one after another, with one summary at the end. /rollback cause explosion near 200 cleans up a creeper field in one go, whoever set it off. /undo reverses the whole set.
  • A rollback that would touch more than 100,000 edits stops and asks first. You get the count and a [confirm] link. Click it if you meant it.
  • Lookup results have clickable coordinates. Click one and you teleport there. Hover a sign to read it, click [read] on a book to open it as the player wrote it.
  • A wrong word does not give you a usage wall. It tells you which word was wrong, what you probably meant, and which words are allowed.
  • The inspector does not change anything you click. Left click for the block, right click for the block on the face you clicked, /inspect again to turn it off.

If something breaks

I have done extensive testing with Alco, but there is always the chance I missed something. If a rollback does something you did not expect, run /undo right away and then DM me what you typed and what happened. If a lookup shows something that looks wrong, the old database is still around and I can compare.

One more thing

If you run a server of your own, Oasis is free to use and you can download it at https://github.com/oasis-protection/oasis-downloads/releases. It requires ClickHouse and other options like MySQL or SQLite are not supported. We built around one engine only which is why a history of 57 million edits rolls back in seconds on hardware that CoreProtect choked on. The API is public if you want to hook other plugins into it. Plex is already hooked into it and bans with the -rb flag will roll back automatically. The source itself is not open, but I have a good reason for this. The plugin most servers use for this job keeps its updates behind a paywall, and a server that does not pay can end up waiting months for a build that runs on the current Minecraft version. I do not want this design, or this code, to end up behind that wall, and if the source were open today I think that is where it would go. So the jar is free, the API is public, but the source code will remain private.

Thanks,
Telesphoreo
 
Last edited:
This plugin has shown exceptional promise both during testing on the test server and live server. If only we had this back in 2023-2024...
 
  • Like
Reactions: Telesphoreo