c# - Entity Framework stops loading related entities after a while -



c# - Entity Framework stops loading related entities after a while -

it seems after 5-40 hours of using same entity framework context, entities stop loading related objects. (ex: character.items null). entities loaded prior issue fine, , load correctly - occurs on entities loaded database instead of cache.

i using entity framework in game server project context has remain active whole duration (otherwise context loses track of objects). server run in single thread, , database related functions (such loading character data, items, relations, etc) done in separate db thread ( ex: game.dbexecute(() => { ... }) ). time entity relations loaded, related info loaded in same db thread, , cached either in list or dictionary later utilize game thread. on average start out 5,000 entities, , 50,000 non-tracked entities (mostly info such skill info, monster info, item info, etc). during runtime, it's exclusively possible add/use 50,000 - 100,000 or more entities until maintenance.

the time db thread not used when accessing entities when entity value set straight - ex: character.name = "...";

could source of problem, or issue lay somewhere else? has else experienced issue?

c# entity-framework orm

Comments

Popular posts from this blog

php - Android app custom user registration and login with cookie using facebook sdk -

django - Access session in user model .save() -

php - .htaccess Multiple Rewrite Rules / Prioritizing -