* /serverperformancemonitor command
Optional parameters are:
start
stop
reset
If no parameters are present, the current performance metrics are spit out.
When disabled, overhead is the cost of some simple function calls and a bool check. When enabled, the additional cost is stopwatch events. In comparisson to the work that ACE does for normal processing, the work done when serverperformance is enabled is nearly 0.
Default is disabled.
Enable it to start up automatically in the config.js. This is recommend for most servers. Enable it at runtime using /serverperformance start
* Fix Reset
This will (should) catch any unhandled exception from any thread.
It will log it as an error, and the application will exit (unsafely).
The user will see the same exception twice on their console, but only one will be logged to the logger. This is expected behavior.
This was tested with the gem exception and works.
If you're wondering, there is no safe way to handle exceptions from UpdateWorld and keep going, nor is there any safe thing we can do if we're in that state to save players. We have no idea what state a player might be in when this is thrown. The could be between two very critical modifications. Furthermore, if we did try to save all players on exceptions, it could be used as an exploit to try to save players/items in a "bugged" state.
The safest thing to do is quit and trust that the last player saves are good.
Due to the way ACE handles biotas and items, dupes aren't an issue for us.
* PlayerManager initial checkin
* OfflinePlayer initial checkin
* More progress
* Comment out Console.WriteLine debug messages
* Add property dictionaries to OfflinePlayer
* IPlayer initial checkin
* Add allegiance vars to IPlayer
* Couple comments
* More progress
* Add more to IPlayer
* line endings fix
* More progress. Compiles. Friends list works again.
* Friend status updates now work (again)
* PlayerManager save OfflinePlayers every 1hr
* Bye bye legacy AllPlayers
* using cleanup
* Allegience switch to PlayerManager progress
* More Allegiance progress
* More progress
* More allegiance progress
* IPlayer adds
* Migrate inversefriends to PlayerManager
* Switch WorldManager GetPlayerByGuid over to PlayerManager
* WorldManager Find(ObjectGuid characterGuid) removed. Use PlayerManager instead
* WorldManager FindByPlayerName(string name) removed. Use PlayerManager instead
* PlayerManager thread safety switched to ReaderWriterLockSlim
* More progress
* ServerStatus added TotalAccountsCreated, TotalCharactersCreated
* No more Player access/management stuff in WorldManager. It's all in PlayerManager now
* Player.IsOnline is no more.
* Friends AppearOnline fix
* Handle dead session better to switch player from online to offline
* Remove adding the + to names in ChatChannels. Name property should be changed to not include +
* serverstatus total accounts and characters on same line
* Allegience initial fix, still more bugs though
* PlayerManager minor cleanup
uint should be faster key than ObjectGuid
Changed the dictionaries to private. We don't want anyone outside of this class referencing them.
* Thread safety added to LScape.get_landcell
* Fixes for Anniversary Event emotes
* Add Pre+Permaload of Global Event Landblock
* Making requested changes
* Add correct check for GlobalEventLandblockPreloading
* Further requested changes. New config setup for Preloaded and Permaloaded Landblocks
* Minor cleanup
* Add a hardcoded fallback incase config file not updated
* Update example to fix syntax error
* Minor tweak to example and console output
* Landblock EnqueueBroadcast cleanup
Avoid double cast by using OfType
Change excludeList from IEnumerable to ICollection because it was being enumerated more than once.
* SerializedShard handle OperationCancledException
* SerializedShard break on the exceptions
* Landblock save progress
* Landblock merge fix
* Decayable -> Dynamic
* Improved ShutdownServer to include landblock unload and db queue wait
* Sleep during shutdown instead of using up all the CPU
* Shard GetDynamic was comparing against the wrong id... woops
* Fix shard biota caching
* Improve shutdown logging and actions
* cosmetic code order
* Fix crash when trying to add a bad wo to a landblock
* This fixes reloading dynamic objects
* Don't save item on pickup
* Don't save item on pickup from chest
* Don't save items on drop
* Set Home Position only for creatures (Used for navigation)
* Improve the landblock SaveDB code
* Don't save player corpse on death. Landblock will do that for us in bulk.
* Add the housing objects to statics that persist to the shard
* WorldObjectFactory dont overwrite location if object came from database
* Improved IsStaticThatShouldPersistToShard
* This should fix player dropped missiles
* Move PositionType into ACE.Entity.Enum.Properties
* Ephemeral support for Positions
* Decay code/saving works much better
* Filter out contained and wielded items from shard GetDynamicsByLandblock
* TimeToRot provision for -1 (No rot)
* Corpse decay is now controlled by landblock and uses the same decay code
* ShardDatabase: Fix add/remove biota bug
* WorldObject.Destroy now destroys contained and equipped items as well
* TryRemoveFromInventoryWithNetworking no longer removes the object from the db
* Player corpse items now remain when the corpse decays
* Cleaned up SetPropertiesForWorld
* Fixing stance shuffling / refactoring moveto chains a bit
* Fixing vendor rotate
* Removing debug message
* Fixing stance change for player activating switches
* Adding methods to QuestManager
* Adding TimeSpanExtensions
* Adjusting walk/run threshold
* Adding quest restrictions for portals, and portal spawning triggered by monster deaths
* Updating function names
* Adding HasQuestCompletes
* Adding support for character titles to emotes
* Added emote hooks for portal use and creature death
* Adding KillTaunt and NewEnemy, updating questName@comment format
* Updating broadcast emotes
* Updating InqQuestSolves
* Adding fixes for Aerfalle
* Fixed rolling balls of death
* Landblock Preloader cleanup
* WorldDatabase spelling fixes
* Added CacheAllWeeniesInParallel
* Add WeeniePrecaching
* Improved WorldDatabase Caching
Null entries are now cached as well to prevent excessive queries to the database to pull records that do not exist.
The callers should raise warnings when a record doesn't exist.
* WorldDatabasePrecaching (~400MB)
* Remove duplicate Timer from Physics.Common
* Clean up ACE.Common.Time and its usages
* WorldObject: Fix CreationTimestamp
* Remove PhysicsTimer which was just a class wrapping a double
* WorldManager.UpdateWorld Stopwatch Usage change
Before we were calculating the elapsed seconds manually with this:
(double)worldTickTimer.ElapsedTicks / Stopwatch.Frequency
The stopwatch can already do this for us via this:
worldTickTimer.Elapsed.TotalSeconds
* WorldManager UpdateWorld Summary improvement
* DateTime based tick removed from Tick() arguments
* No need to pass DateTime.UtcNow.Ticks to Session.Tick
* LastMovementBroadcastTicks was obsolete
Probably souldn't be referencing WorldManager.PortalYearTicks as well.
If we need this in the future, it's probably better to reference DateTime.UtcNow or Time.GetUnixTime()
* Fix WorldObject.Tick() overhead
* Revert "WorldObject: Fix CreationTimestamp"
This reverts commit 457bebc48e.
* PhysicsTimer stuff
Move the Timer back to the Physics namespace and rename it PhysicsTimer
Change some references from PhysicsTimer to DateTime.UtcNow
* timeBeginPeriod and timeEndPeriod added for Windows to improve timer resolution
* ServerManager Shutdown was using 100% cpu
* Fix the usage of CreationTimestamp
* CharacterHandler should not be setting default values. Player ctor should.
* EmoteManager switched from PhysicsTimer to DateTime.UtcNow
* Use PropertyInt and not PropertyFloat for LoginTimestamp
* Fix Session GetAll() to also include sessions that are at the character selections creen
* UpdateWorld sleep/tickCalc should be last thing loop does
* Don't show decimal places for debug logs that show time elapsed
* PropertyManager less debug output
Also, Propertymanager should be init after the database is init, and before the rest of the server comes up.
Other items in the server might reference properties from the PropertyManager.
* Added the configuration database base script.
This should initialize the config database to hold different values that can be changed during the server operation.
* Added database models and connection.
This should begin to add in the new configuration database and its models so that it can be accessed from the server.
* Added boolean statistic access methods.
Modified the database file so that it was properly casting to a boolean and added the methods into the server configuration database API.
* Added the ability to access/modify integers in the config database.
* Added the ability to access/modify floating point variables in the configuration database
* Added the ability to access/modify string values in the configuration database
* Added the ServerConfigurationDatabase to the DatabaseManager.
* Added in the initial caching layer for configuration
* Added the ability to modify cached items.
* Changed from regular dictionaries to concurrent dictionaries.
* Added in the ability for the ConfigurationManager to self-update from the database.
* Added fallback parameters instead of forcing a default
* Added customizable vitae statistics.
This is the first big stat that can be modified. It is a float, so more floats should now work when they have support added.
* Updated the configuration manager to separate methods and ensure semantics are correct.
* Added command to fetch float value from server
* Add property for XP/Lum multipler.
* Welcome message/MOTD is now configurable from the database.
* Added string modification commands
* Database is no longer required for server configuration.
* Added in all modification/fetch commands and a resync command
* Renamed ConfigurationManager -> PropertyManager as this removes ambiguity
* Changed logging string to be more consistent
* Pass w/ StyleCop
* Added comments to the property manager
* Added the ability to disable caching fallback values.
This can be used for default settings or if a fetch with the default fallback should not cache (ie fetching xp_multipler before xp_multiplier has been fetched from the DB/the default value has been given, and therefore xp_multiplier is fetched as 0 and cached as 0). This functionality should be used for server commands.
* The admin commands now properly obey cacheFallback restrictions
* Added initial default property handling.
* Moved to using constant values as defaults.
* Switched to using a Dictionary for resolution of default properties
* Added warning when the server configuration database is not loaded.
* Corrected MOTD default string
* Renamed some of the database connection objects and changed float -> double and int -> long
* Fixed admin commands not being named correctly
* Fixed spelling error
* Config tables now lie in the shard database
* Added descriptions to properties across the board that can be analyzed through admin commands
* Removed property from PlayerXP file
* Removed vitae properties from EnchantmentManager
* Added null checks to make output nicer
* Added command to modify property descriptions
* Fixed string not being stored properly in the DB and crashing the server
* Wrapped the old ServerPropertyDatabase into SerializedShardDatabase
* Fixed ShardDbContext having a modified OnConfiguring method
* AuthenticationDatabase switched to Entity Framework Core, DB First
* Adds AsNoTracking() for performance and implements CreateAccount() instead of AddAccount()
* woops
* Auth db no longer needs to be init, or inherit from Database
* test fix hopefully
* Database objects in ACE.Entity would no longer be required
* Major WIP
* more progress
* AuthenticationDatabase switched to Entity Framework Core, DB First
* Adds AsNoTracking() for performance and implements CreateAccount() instead of AddAccount()
* woops
* Auth db no longer needs to be init, or inherit from Database
* test fix hopefully
* Database objects in ACE.Entity would no longer be required
* Major WIP
* more progress
* include missing CharacterCreateInfo
* GetCharacters changes to show how we can use the propertybag for these values
* Lot of progress with the WorldObject code
* comment add
* add biota to CreateWorldObject for loading inv from db