Use Lazy Loading.
Don’t load other player’s stash into the client unless the player initiates the “Trade” action. i.e. delay loading of Player B’s stash until Player A initiates trade with Player B. All other player’s stashes remain unloaded.
The destination for the stash (in memory) can remain the same, meaning you don’t need to rearchitect where the stash loads, just when, and how many.
I’m sure they’ve thought of that and are trying to minimize the number of calls to the database because WOW devs have said before that is where the main bottleneck is.
1 big query is probably preferred to 100 small ones.
They are already making calls to load every player’s stash. This reduces the # of calls. Also, never assume they already thought of something. I manage 2 teams of really skilled and talented developers, and they don’t always think of the right solution. That’s what collaboration/paired-programming techniques are all about.
1 big call is probably better though. So you have all players near you in memory. So if you try and trade you have everything known already so you don’t have to query the database unless it’s something new they didn’t have previously that gets put in the trade window.
I’m sure they are just dumping the inventory to memory and then when people trade it just does a local lookup client side and if the item is in memory it doesn’t try and go out to the database.
This is what I’m saying.
I’m not saying it’s good. I’m just betting this is what is happening.
The problem with that model is that the ratio of trading to non-trading is so low, you lose all the performance gains of the single query to the sheer number of unneeded queries.
You shouldn’t do a technical post about something you don’t know, technically. We don’t know anything except “it load in memory”. It’s still a high level game technically, and Blizzard team are not beginners. It’s quite insulting for them.
I am completely ignorant on the subject, but why would the game need to load the stash for trading in the first place? Shouldn’t it just be loading the character’s inventory?