WatchFox
WatchFox
No one can outfox a fox
WatchFox is an extremely fast and efficient logging plugin that uses its own custom, self-hosted database to achieve the fastest speeds of any logging plugin yet. Just drop the jar in the plugins folder and you'll be logging at multi-thousand actions per second.
Links: Downloads | API Info | Changelog | How to use | What it logs | Configuration | Permission nodes | Saving | How it works | Test details | Report a bug | Validation
WatchFox was developed in my quest for a superior logging plugin. Since none of the ones currently available appealed to me, I wrote my own. (Of course, this also means I wrote all the documentation myself. If it's a little thick, don't worry, the defaults are perfectly fine, there's just room for tweaking.)
A significant consideration was that most logging plugins required a MySQL database. While many hosts offer such a server now, in my experience, they were unreliable and over-provisioned. Many could not keep up with even a modest server. Additionally, running MySQL on a self-hosted server adds a large amount of overhead, both to the server and the admin. WatchFox avoids all of this by running the database internally to the plugin, with intelligent caching and minimal I/O.
There are also other logging solutions that don't use a MySQL server. However, WatchFox vastly outperforms them. In a self-conducted test (I encourage you to test for yourself if you don't believe me), WatchFox was many times faster, and uses significantly less storage space to store data.
Important tidbits:
- WatchFox is coded in Java 1.7 and requires a Java 7 JRE / runtime to function.
- WatchFox throttles rollbacks to 1000 blocks per second reduce server lag. If you have power to spare, you change this rate in the configuration. See conf.
Naturally, WatchFox has its own set of unique advantages and disadvantages over other plugins. Some notable ones follow:
+NO NMS CODE Confidently use WatchFox on any 1.4.5R1.0+ server.
+No need for a MySQL server
+Fastest Bukkit logger available
+Full search syntax, not restricted to using tools
+Full WorldEdit selection usage support
+Powerful API for other plugins
+Chest inventory rollbacks
+Easier to setup than alternatives
+Rollback preview support
+Ability to keep database in sync with Minecraft world (see saving for details)
+Unique anti-overwrite technology (see below)
+Shift-click to add blocks to your search!
+Ability to sort your search results at a whim
+Session sharing for easy collaboration
+100% active development, long term support
-Possibility of data loss if server crashes
-Additional RAM must be used for the database (not to be used if you're running out of RAM as-is now!)
-Data must be viewed with the in-game browser
In having a unique database, WatchFox also has a similarly unique anti-overwrite system. Basically, when performing a rollback, a particular event will only be undone if the block hasn't been changed by a non-searched party. For example, your standard plugin will check to make sure that block is as it was after the event before rolling back (that is, if a block was broken, it will only rollback if the block is still Air). However, WatchFox has the unique ability to check for any post-event action. For example, if a malicious player spams dirt blocks around someone's house, and the victim later clears it all away, only to then put dirt back selectively, the dirt that the victim placed will not be rolledback. It is considered superseded. No longer will performing a rollback reverse the victim's own work!
If you want to try the most advanced and fastest logging plugin available for yourself, just click Downloads here or in the links bar, drop it into your plugins folder and /reload
. It has no dependencies, although it does support using WorldEdit.
Want to make WatchFox even more awesome? Report any bugs you find or request useful new features by clicking "Report a bug". Even simple things like errors in the documentation will be systematically fixed.
And don't forget to check out the other links available.
A note about downloads. As the main website for WatchFox is located elsewhere, download links on the wiki pages will direct you to my own website which hosts the jars as well. While I will maintain both the downloads here on BukkitDev and there, only the files here are subject to the quality control the BukkitDev staff impose. As such, you are encouraged to use the downloads provided here.
@LanToaster
Well, the latest version has an API at the jvm (code) level which allows for searching and the like, however there no plans for a native, embedded web server like thing.
I could write a plugin that adds a web server + web api though. I wouldn't object if that feature and its bloat were optional.
I'll see what I can do tonight.
I Just meant to Access the Database from outside the Game so i can View/search/display specific Data on the Website or Other means.
@LanToaster
Hmmmm, and what kind of log would you want?
Something like "/wf file {txt | csv | html}" could work quite nicely, where it spits out your in-game search to a file.
Logging _everything_ to a file is impractical. A program to selectively log to a file would be a good demo for the new API.
What did you have in mind?
Are there Plans to make the Data Viewable/Readable Outside of the Game? Like on a WebPage or something?
I would love to Read out the Logs for Statistiks.
I'm releasing my new version in response to the broken API. It's version 2504 or later!
Finally edited:
So, sorry about not doing anything meaningful about the docs and such. Between life and updating the program code, there's been an annoying lack of free time.
BIG BIG BIG NOTE. I incremented WatchFox's main version number. It is NO LONGER compatible with old databases. v1.2.2 is last release in the v1 ecosystem. v2 was made less hackish. This eliminates a hackish system I was using so API users can't inadvertently poke holes in the hack.
The API version was also incremented. Notably, there's a searchN feature so you can reduce system load by say, only getting the most recent matching event. Additionally, there's a wrapper in the BukkitAPI that, for the most part, allows you to use a Location object instead of constantly extracting the world and coords yourself.
An API tutorial that walks through the creation of three demo plugins is in the works. Given the time it took for the last files to be approved, hopefully everything will be ready then.
@Wachabiin
You're probably running with Java 6, WatchFox is written in Java 7 and requires Java 7 to run.
Any idea why I might be getting "Invalid major minor version 51.0" with the newest version?
Thanks for the response.
@Confuzzled77
I have, I wrote WatchFox because I felt CoreProtect was kind of meh.
Feature wise, WatchFox is almost completely supersedes every feature of CoreProtect. Two exceptions are that falling blocks aren't logged and neither is WorldEdit since both are pretty hackish to do and baby-sitting hacks isn't fun. The last being the inability to delete old data. Credit where it's due, this will probably never come to WatchFox for architectural reasons and lack of demand. But, WatchFox also has a few features of its own. The latest build has auto-updating and chest rollbacks for example, and WatchFox, as far as I know, still has the most powerful WorldEdit selection support, that is, _any_ selection is supported for searches, rollbacks, etc.
Speed-wise, it's miles ahead. Same goes with storage space consumption. The database structure is more advanced (I will fully admit this comes with the occasional bug), but it does mean queries are faster and can be significantly more complicated at the same time.
So, in my opinion, which is obviously completely one-sided, I think WatchFox compares favorably and I've had good success with people sticking with it once trying it out.
I'm not sure if you compared this to Core Protect, so do you have any thoughts on how this compares?
Massive update for 1.4.
A lot of stuff was just rolled into one big update. Notable inclusions include 1.4 stuff obviously, mcstats reporting, and auto-updating.
Oh and chest rollbacks, for which I received a decently large number of requests.
Those running pre-1.4 mc servers should use 1.1.4 which contains a backported patch for a fatal DB bug.
@ryvix
Hey, thanks for continuing to try it out. You single-handedly convinced me to add liquid flow logging and fire-spread. I'm glad it works well for you.
And yes, the flows are stripped of the causal player. I realize this may not be the most convenient of things, but I should note that you can also add player "environment" to the search and that will also include all the (tracked) physics events. I also realize there's a complete lack of tutorials or assistance, but 1.4 is in the process of derailing that.
As for the water, I believe it occasionally reflows randomly. The event culler in 1.1.3 helped a bit from 1.1.2, but tracking Minecraft physics is painfully tricky.
The fire pretty much has to be extinguished first or yeah, it'll race ahead.
As always, I sincerely appreciate all the input you have to offer.
Hello, I tested the latest version by dumping lava and water down a wool wall and it actually works great!
The only thing is if you search by player it doesn't remove the chain of events that happened because of the streams of lava and water, only the initial placement of it and so I had to search by time instead. It just sometimes wouldn't roll back the tips of the water that spread out.
Also, it won't stop something burning if it continues to burn after you made your search, even though it's still part of the chain of events caused by the player. However I don't think technically that can be properly determined, for example what if lightning strikes nearby causing something to burn as well. Luckily it still logs these and they can just be rolled back.
Nice work! =)
@supertycoon0
That's great news thanks
@supertycoon0
Make a video with: ''How to rollback'' + ''How to find a griefer''
@Jabulba
So, I changed the event back to the old type that should work with 1.2.5 with WatchFox 1.1.3, which has been released and is available at my repo and will be available here after it is approved.
Testing under 1.2.5 isn't feasible time-wise for me, however, theoretically, WatchFox should now work completely. Tekkit specifically has a bucket of additional problems, but at least this is one less.
Hello, I know this error shows up because i'm using CB 1.2.5, but WatchFox seems to run fine. Do you know if I might have problems because of this? It's a Tekkit server so updating bukkit is not possible.
[INFO] [WatchFox] Enabling WatchFox v1.1.2 [SEVERE] Plugin WatchFox is attempting to register event org/bukkit/event/player/AsyncPlayerChatEvent, which does not exist. Ignoring events registered in class net.supertycoon.mc.watchfox.logger.bukkit.BukkitLogger$17
@Pixiyo
One's in the works, I tried to see how long it would take to go through everything, and it ended up being about an hour and twenty minutes. Do you think it'd be a better idea to cover less and be more concise or annotate the video and encourage skipping around?
A tutorial video would be perfect.
@supertycoon0
Nice, I will give it a shot =)