This page addresses a number of frequently asked questions about the plugin.
## Frequently Asked Questions
< details >
< summary > < b > What data can be synchronized?< / b > < / summary >
HuskSync supports synchronising a wide range of different data elements, each of which can be toggled to your liking. Please check out the [[Sync Features]] page for a full list.
< / details >
< details >
< summary > < b > Are modded items supported?< / b > < / summary >
Modded items are not supported.
< / details >
< details >
v3.0: New modular, more compatible data format, new API, better UX (#160)
* Start work on v3
* More work on task scheduling
* Add comment to notification display slot
* Synchronise branches
* Use new HuskHomes-style task system
* Bump to 2.3
* Remove HuskSyncInitializationException.java
* Optimise database for MariaDB
* Update libraries, move some around
* Tweak command registration
* Remove dummyhusksync
* Fixup core synchronisation logic to use new task system
* Implement new event dispatch subsystem
* Remove last remaining future calls
* Remove `Event#fire()`
* Refactor startup process
* New command subsystem, more initialization improvements, locale fixes
* Update docs, tweak command perms
* Reduce task number during data setting
* add todo
* Start work on data format / serialization refactor
* More work on Bukkit impl
* More serialization work
* Fixes to serialization, data preview system
* Start legacy conversion skeleton
* Handle setting empty inventories
* Start on-the-fly legacy conversion work
* Add advancement conversion
* Rewrite advancement get / apply logic
* Start work on locked map persistence
* More map persistence work
* More work on map serialization
* Move around persistence logic
* Add testing suite
* Fix item synchronisation
* Finalize more reliable locked map persistence
* Remove deprecated method call
* remove sync feature enum
* Fix held item slot syncing
* Make data types modular and API-extensible
* Remove some excessive debugging, minor refactor
* Fixup date formatting, improve menu UIs
* Finish up legacy data converting
* Null safety in item stack serializaiton
* Fix relocation of nbtapi, update dumping docs
* Add v1/MPDB Migrators back in
* Fix pinning/unpinning data not working
* Consumer instead of Function for editing data
* Show file size in DataSnapshotOverview
* Fix getIdentifier always returning empty
* Re-add items and inventory GUI commands
* Improve config file, fixup data restoration
* Add min time between backups (more useful backups!)
* More work on backups
* Fixup backup rotation frequency
* Remove stdout debug print in `#getEventPriority`
* Improve sync complete locale logic, fix synchronization spelling
* Remove `static` on exception
* Use dedicated thread for Redis, properly unsubscribe
* Refactor `player` package -> `user`
* `PlayerDataHolder` -> `UserDataHolder`
* Make `StatisticsMap` public, but `@ApiStatus.Internal`
* Suppress unused warnings on `Data`
* Add option to disable Plan hook
* Decompress legacy data before converting
* Decompress bytes in fromBytes
* Check permission node before serving TAB suggestions
* Actually convert legacy item stack data
* Fix syntax errors
* Minor method refactor in items command
* Fixup case-sensitive parsing in HuskSync command
* Start API work
* More work on API, fix potion effects
* Fix cross-server, config formatting for auto-pinned issue
* Fix confusion with UserData command, update docs images
* Update commands docs
* More docs updating
* Fix sync feature enabled/disabled checking logic
* Fix `#isCustom()`
* Enable persistent_data syncing by default
* docs: update Sync-Features config snippet
* docs: correct typo in Sync Features
* More API work
* bukkit: slightly optimized schedulers
* More API work, various refactorings
* docs: Start new API docs
* bump dependencies
* Add some basic unit tests
* docs: Correct typos
* More docs work, annotate DB methods as `@Blocking`
* Encapsulate `RedisMessage`, minor optimisations
* api: Simplify `#getCurrentData`
* api: Simplify `editCurrentData`, using `ThrowingConsumers` for better error handling
* docs: More Data Snapshot API documenting
* docs: add TOC to Data Snapshot API page
* bukkit: Make data types extend BukkitData
* Move where custom data is stored, finish up Custom Data API docs
* Optimise imports
* Fix `data_manager_advancements_preview_remaining` locale
* Fix advancement and playtime previews
* Fix potion effect deserialization
* Make snapshot_backup_frequency default to 4, more error handling/logging
* docs: Add ToC to Custom Data API
* docs: Minor legacy API tweaks
* Remove some unneeded catch logic
* Suppress a few warnings
* Fix Effect constructor being supplied in wrong order
1 year ago
< summary > < b > Are MMOItems / SlimeFun / ItemsAdder items supported?< / b > < / summary >
v3.0: New modular, more compatible data format, new API, better UX (#160)
* Start work on v3
* More work on task scheduling
* Add comment to notification display slot
* Synchronise branches
* Use new HuskHomes-style task system
* Bump to 2.3
* Remove HuskSyncInitializationException.java
* Optimise database for MariaDB
* Update libraries, move some around
* Tweak command registration
* Remove dummyhusksync
* Fixup core synchronisation logic to use new task system
* Implement new event dispatch subsystem
* Remove last remaining future calls
* Remove `Event#fire()`
* Refactor startup process
* New command subsystem, more initialization improvements, locale fixes
* Update docs, tweak command perms
* Reduce task number during data setting
* add todo
* Start work on data format / serialization refactor
* More work on Bukkit impl
* More serialization work
* Fixes to serialization, data preview system
* Start legacy conversion skeleton
* Handle setting empty inventories
* Start on-the-fly legacy conversion work
* Add advancement conversion
* Rewrite advancement get / apply logic
* Start work on locked map persistence
* More map persistence work
* More work on map serialization
* Move around persistence logic
* Add testing suite
* Fix item synchronisation
* Finalize more reliable locked map persistence
* Remove deprecated method call
* remove sync feature enum
* Fix held item slot syncing
* Make data types modular and API-extensible
* Remove some excessive debugging, minor refactor
* Fixup date formatting, improve menu UIs
* Finish up legacy data converting
* Null safety in item stack serializaiton
* Fix relocation of nbtapi, update dumping docs
* Add v1/MPDB Migrators back in
* Fix pinning/unpinning data not working
* Consumer instead of Function for editing data
* Show file size in DataSnapshotOverview
* Fix getIdentifier always returning empty
* Re-add items and inventory GUI commands
* Improve config file, fixup data restoration
* Add min time between backups (more useful backups!)
* More work on backups
* Fixup backup rotation frequency
* Remove stdout debug print in `#getEventPriority`
* Improve sync complete locale logic, fix synchronization spelling
* Remove `static` on exception
* Use dedicated thread for Redis, properly unsubscribe
* Refactor `player` package -> `user`
* `PlayerDataHolder` -> `UserDataHolder`
* Make `StatisticsMap` public, but `@ApiStatus.Internal`
* Suppress unused warnings on `Data`
* Add option to disable Plan hook
* Decompress legacy data before converting
* Decompress bytes in fromBytes
* Check permission node before serving TAB suggestions
* Actually convert legacy item stack data
* Fix syntax errors
* Minor method refactor in items command
* Fixup case-sensitive parsing in HuskSync command
* Start API work
* More work on API, fix potion effects
* Fix cross-server, config formatting for auto-pinned issue
* Fix confusion with UserData command, update docs images
* Update commands docs
* More docs updating
* Fix sync feature enabled/disabled checking logic
* Fix `#isCustom()`
* Enable persistent_data syncing by default
* docs: update Sync-Features config snippet
* docs: correct typo in Sync Features
* More API work
* bukkit: slightly optimized schedulers
* More API work, various refactorings
* docs: Start new API docs
* bump dependencies
* Add some basic unit tests
* docs: Correct typos
* More docs work, annotate DB methods as `@Blocking`
* Encapsulate `RedisMessage`, minor optimisations
* api: Simplify `#getCurrentData`
* api: Simplify `editCurrentData`, using `ThrowingConsumers` for better error handling
* docs: More Data Snapshot API documenting
* docs: add TOC to Data Snapshot API page
* bukkit: Make data types extend BukkitData
* Move where custom data is stored, finish up Custom Data API docs
* Optimise imports
* Fix `data_manager_advancements_preview_remaining` locale
* Fix advancement and playtime previews
* Fix potion effect deserialization
* Make snapshot_backup_frequency default to 4, more error handling/logging
* docs: Add ToC to Custom Data API
* docs: Minor legacy API tweaks
* Remove some unneeded catch logic
* Suppress a few warnings
* Fix Effect constructor being supplied in wrong order
1 year ago
These plugins, which provide custom items, should be supported as of HuskSync v3.x; but do note we cannot guarantee compatibility with all methods of injecting custom data to create custom items. Be sure to test thoroughly before deploying on production!
< / details >
< details >
< summary > < b > Is Redis required? What is Redis?< / b > < / summary >
HuskSync requires Redis to operate (for reasons demonstrated below). Redis is an in-memory database server used for caching data at scale and sending messages across a network. You have a Redis server in a similar fashion to the way you have a MySQL database server. If you're using a Minecraft hosting company, you'll want to contact their support and ask if they offer Redis. If you're looking for a host, I have a list of some popular hosts and whether they support Redis [available to read here. ](https://william278.net/redis-hosts )
< / details >
< details >
< summary > < b > How does the plugin synchronize data?< / b > < / summary >
HuskSync makes use of both MySQL and Redis for optimal data synchronization. You have the option of using one of two [[Sync Modes]], which synchronize data between servers (`DELAY` or `LOCKSTEP` )
v3.0: New modular, more compatible data format, new API, better UX (#160)
* Start work on v3
* More work on task scheduling
* Add comment to notification display slot
* Synchronise branches
* Use new HuskHomes-style task system
* Bump to 2.3
* Remove HuskSyncInitializationException.java
* Optimise database for MariaDB
* Update libraries, move some around
* Tweak command registration
* Remove dummyhusksync
* Fixup core synchronisation logic to use new task system
* Implement new event dispatch subsystem
* Remove last remaining future calls
* Remove `Event#fire()`
* Refactor startup process
* New command subsystem, more initialization improvements, locale fixes
* Update docs, tweak command perms
* Reduce task number during data setting
* add todo
* Start work on data format / serialization refactor
* More work on Bukkit impl
* More serialization work
* Fixes to serialization, data preview system
* Start legacy conversion skeleton
* Handle setting empty inventories
* Start on-the-fly legacy conversion work
* Add advancement conversion
* Rewrite advancement get / apply logic
* Start work on locked map persistence
* More map persistence work
* More work on map serialization
* Move around persistence logic
* Add testing suite
* Fix item synchronisation
* Finalize more reliable locked map persistence
* Remove deprecated method call
* remove sync feature enum
* Fix held item slot syncing
* Make data types modular and API-extensible
* Remove some excessive debugging, minor refactor
* Fixup date formatting, improve menu UIs
* Finish up legacy data converting
* Null safety in item stack serializaiton
* Fix relocation of nbtapi, update dumping docs
* Add v1/MPDB Migrators back in
* Fix pinning/unpinning data not working
* Consumer instead of Function for editing data
* Show file size in DataSnapshotOverview
* Fix getIdentifier always returning empty
* Re-add items and inventory GUI commands
* Improve config file, fixup data restoration
* Add min time between backups (more useful backups!)
* More work on backups
* Fixup backup rotation frequency
* Remove stdout debug print in `#getEventPriority`
* Improve sync complete locale logic, fix synchronization spelling
* Remove `static` on exception
* Use dedicated thread for Redis, properly unsubscribe
* Refactor `player` package -> `user`
* `PlayerDataHolder` -> `UserDataHolder`
* Make `StatisticsMap` public, but `@ApiStatus.Internal`
* Suppress unused warnings on `Data`
* Add option to disable Plan hook
* Decompress legacy data before converting
* Decompress bytes in fromBytes
* Check permission node before serving TAB suggestions
* Actually convert legacy item stack data
* Fix syntax errors
* Minor method refactor in items command
* Fixup case-sensitive parsing in HuskSync command
* Start API work
* More work on API, fix potion effects
* Fix cross-server, config formatting for auto-pinned issue
* Fix confusion with UserData command, update docs images
* Update commands docs
* More docs updating
* Fix sync feature enabled/disabled checking logic
* Fix `#isCustom()`
* Enable persistent_data syncing by default
* docs: update Sync-Features config snippet
* docs: correct typo in Sync Features
* More API work
* bukkit: slightly optimized schedulers
* More API work, various refactorings
* docs: Start new API docs
* bump dependencies
* Add some basic unit tests
* docs: Correct typos
* More docs work, annotate DB methods as `@Blocking`
* Encapsulate `RedisMessage`, minor optimisations
* api: Simplify `#getCurrentData`
* api: Simplify `editCurrentData`, using `ThrowingConsumers` for better error handling
* docs: More Data Snapshot API documenting
* docs: add TOC to Data Snapshot API page
* bukkit: Make data types extend BukkitData
* Move where custom data is stored, finish up Custom Data API docs
* Optimise imports
* Fix `data_manager_advancements_preview_remaining` locale
* Fix advancement and playtime previews
* Fix potion effect deserialization
* Make snapshot_backup_frequency default to 4, more error handling/logging
* docs: Add ToC to Custom Data API
* docs: Minor legacy API tweaks
* Remove some unneeded catch logic
* Suppress a few warnings
* Fix Effect constructor being supplied in wrong order
1 year ago
When a user changes servers, in addition to data being saved to MySQL, it is also cached via the Redis server with a temporary expiry key. When changing servers, the receiving server detects the key and sets the user data from Redis. When a player rejoins the network, the system fetches the last-saved data snapshot from the MySQL Database.
This approach is able to dramatically improve both synchronization performance and reliability. A few other techniques are used to optimize this process, such as compressing the serialized user data json using Snappy.
< / details >
< details >
< summary > < b > Why doesn't HuskSync sync player economy balances / support Vault?< / b > < / summary >
This is a very common request, but there's a good reason why HuskSync does not support this.
The Vault API is designed to be a central "Vault" for storing user data. It's the role of economy plugins that *implement* vault to handle the data storage -- and, by extension, synchronization cross-server. Plugins that *hook into* Vault then expect to be able to use the Vault API to get the player's latest economy balance and data.
Plugins such as MySQLPlayerDataBridge that support synchronizing Vault *hook into* Vault and as a result can violate this expectation— plugins that expect Vault to return the latest user data no longer can. As a result, plugins like MySQLPlayerDataBridge have to provide lots of manual hooks and tweaks for individual plugins to ensure compatibility.
This causes all sorts of compatibility issues with unsupported plugins and increases plugin size and update workload.
As a result, I recommend using an economy plugin (that directly *implements* the Vault API), that works cross-server. XConomy is a popular choice for this, which I have personally had a good experience with in the past.
< / details >
< details >
< summary > < b > Is this better than MySQLPlayerDataBridge?< / b > < / summary >
I can't provide a fair answer to this question! What I can say is that your mileage may vary. The performance improvements offered by HuskSync's synchronization method will depend on your network environment and the economies of scale that come with your player count.
With that said, servers running plugins or mods that make use of custom items (such as MMOItems, SlimeFun) are not supported by HuskSync and so MySQLPlayerDataBridge may be a better choice for you.
A migrator from MPDB is built-in to HuskSync.
< / details >