Commit graph

10 commits

Author SHA1 Message Date
OptimShi
7d78202ddc
Reworked Gear Plating Name functionality to fix some gaps and omissions. (#4276)
* Reworked Gear Plating Name functionality to fix some gaps and omissions, as well as added a `fix-gear-plating` dev command.

* Update DeveloperDatabaseCommands.cs

---------

Co-authored-by: OptimShi <26606778+OptimShi@users.noreply.github.com>
Co-authored-by: Ty Conner <tyconner@itcproductions.com>
2025-03-09 05:22:17 -04:00
Mag-nus
43c9300b10
.NET Entity Framework Core 3.1 support (attempt #2) (#3356)
* packages updated, fix compiler errors/warnings

* scaffold

* fix ShardDatabaseOfflineTools

* WorldDatabase fix performance

* ShardDatabase fix GetCharacters

* move comment

stuff

* extend UseMySQL statements

* fix character creation linq parsing

* fix exception

* fix references
2020-12-07 20:59:40 -06:00
Ty Conner
4a24710f4e
Fix spell bar position save issue (#2918)
* Fix spell bar position save issue

* Update 2020-04-11-00-Update-Character-SpellBars.sql

* Switch CharacterPropertiesSpellBar to composite key

* Fix incorrect indexes in SpellBars

* Update ShardDatabaseOfflineTools.cs

* Update PropertyManager.cs

* Update DatabaseManager.cs

* Update 2020-04-11-00-Update-Character-SpellBars.sql

* Update 2020-04-11-00-Update-Character-SpellBars.sql

* Update ShardDatabaseOfflineTools.cs

* Update 2020-04-11-00-Update-Character-SpellBars.sql

* Update ShardDatabaseOfflineTools.cs

* Update DeveloperDatabaseCommands.cs

* Update Program.cs

* Update 2020-04-11-00-Update-Character-SpellBars.sql

* Update 2020-04-11-00-Update-Character-SpellBars.sql

* Update ShardDatabaseOfflineTools.cs

* Update ShardDbContext.cs

* .

* Update DeveloperDatabaseCommands.cs

* Update DeveloperDatabaseCommands.cs

optimizations by @gmriggs

Co-Authored-By: gmriggs <gmriggs@gmail.com>

Co-authored-by: gmriggs <gmriggs@gmail.com>
2020-04-12 17:01:22 -04:00
Mag-nus
75fc1ce23c
Step 3. Convert ShardDatabase/WorldObjects biota from the ACE.Database model to the new ACE.Entity model (#2731)
* Step 1. Add new adapter classes and models

All classes and objects added are in new namespaces.

This add has 0 interraction on existing ACE code.

This sets the groundwork for Step 2. Moving World DB caching to the new models

* first part of the world entity usage

* almost there

* final part

* update WeenieExtensions

* fix

* merge fixes and improvements

* ACE.Database new code

* it compiles

* InitializePropertyDictionaries

* WOrldDatabaseWithEntityCache cleanup

* ShardDatabaseWithCaching

* ShardDatabase Cleanup

* todo

* cache counts reported in serverstatus

* House InitializePropertyDictionaries

* improve ServerStatus

* BiotaModel change HousePermissions to Dictionary<uint, bool>

* PropertiesAllegiance to dictionary

* BiotaUpdater improvements

* Shard Database Cache Reporting

* More code ported from Step 3

* Remove stub CharacterCache

* Update WorldDatabaseWithEntityCache.cs

* build fixes

* code audit

* Remove non-callback functions from SerializedShardDatabase

* BiotaUpdater progress.. only emote left

* Emotes done... now need to test

* fix

* Burden/Value fix for containers

* fat fingered EncumbranceVal

* add some safety

* Don't cache player biotas for initial PlayerManager load

* fix null spellbook

* Add another null check

This is redundant as the check is also upstream.

This is to prevent an exception in the future if this function is called from another source.
2020-04-02 22:40:27 -05:00
gmriggs
115e180cc5
starting to clean up /acecommands a bit (#2271)
* starting to clean up /acecommands a bit

* adding ability to search /acecommands by keyword

* small adjustment
2019-08-25 01:05:49 -04:00
Mag-nus
70611dab87
add /allstats, make /delete safer (#1942) 2019-06-02 20:02:30 -05:00
Ty Conner
90c98c76a6
Shortcut Fix Stage 1 (#1759)
* Update DeveloperDatabaseCommands.cs

Co-Authored-By: gmriggs <gmriggs@gmail.com>

* Update fix-shortcut-bar command

* Add support for closing (and opening) a world to players

* Update AdminShardCommands.cs

* Update AuthenticationHandler.cs

* Change bool to world_closed

* Update changelog
2019-04-19 01:58:03 -05:00
Mag-nus
3232074f90
CommandHandlerHelper (Yum!) Added (#1027)
There were a ton of commands that worked both on the console, and from a player session.

These commands had conditions like the following to determine if the output should be sent to the console or to the sesion:
if (session != null)
 sendToSession()
else
 SendToConsole()

CommandHandlerHelper cleans up this.

In addition, there were places in the code that were doing Console.WriteLine that should have been using the logger instead.
2018-09-24 07:04:58 -05:00
Mag-nus
12c9eea68a
Shard Biota Save & Threading Model Rework (#960)
* SaveBiota major changes

SaveBiota now only updates values in the database that have changed instead of updating every single value.

In addition. SaveBiota detects added and removed linked entities.

* Replace AddBiota(s) with SaveBiota(s)

* This improves the way a few places referenced the biota

* SaveBiota switched to a diff method. Still some work to do

* More notes + fixes

* SaveBiota move GetBiota to before EnterWriteLock

* Added a note about the lock performance

* More summary improvements for BiotaDatabaseLock

* Thread safety added to the SaveBiotas and AddBiotas functions

SavePlayer also switched to use the SaveBiotas bulk action instead of saving each biota individually.

* Biota.Clone() added

* BiotaExtensions cosmetic only

* DbUpdateException fixed

If there were multiple new records in a collection, the first one was attached but with the last new records values.

This would end up resulting in property records with duplicate types id's.

* ReoveBiota check if biota actually exists in db before removal.

* /databasequeueinfo added

* New From-Weenie Containers should not be searching the shard for inventory

* DeveloperDatabaseCommands removed RequiresWorld flag

* Improved DatabasePerfTest results.
2018-08-20 18:30:38 -05:00
Mag-nus
9622ab3f61
DatabasePerfTest developer command added (#957)
My test results:

Starting Database Performance Tests.
Biotas per test: 1000
This may take several minutes to complete...
1000 individual add   . Duration:  29.9 seconds. Successes: 1000, Failures:    0. Average:  30 ms
1000 individual save  . Duration:  23.9 seconds. Successes: 1000, Failures:    0. Average:  24 ms
1000 individual remove. Duration:  23.7 seconds. Successes: 1000, Failures:    0. Average:  24 ms
1000 bulk add         . Duration:   8.5 seconds. Successes:    1, Failures:    0. Average:   9 ms
1000 bulk save        . Duration:   6.2 seconds. Successes:    1, Failures:    0. Average:   6 ms
1000 bulk remove      . Duration:   7.0 seconds. Successes:    1, Failures:    0. Average:   7 ms
Database Performance Tests Completed

Next step is to modify the save to detect added/removed entities and only update changed records (not all).
2018-08-18 09:35:26 -05:00