2014년 12월 29일 월요일

Help me understand if mongoDB could be a good fit?

I've done my research on documentDB's, i still dont fully understand them but i want some help understand wether it could be worth my time to delve deeper into this. 

i run a game, and i'm looking at a reboot with some restructuring. 

The game uses a MySQL backend on the server side to store data

a shoretened schema is below

User
UserID
Username
DateCreate

Tank
TankID
UserID REF User.UserID
Rank
Awards

Map
MapID
MapName
MapFile

MapData
TankID REF Tank.TankID
MapID REF MAP.MapID
Color 
HoursPlayed
Equipment


I do a ton of single record writing..specifically to the MapData portion of the table. My understanding is that with DOcumentDB, single writes/reads are much faster than a mysql i/o. Very little BULK reading/writing, but there is some of that (5% maybe). 

Can someone help me understand if A) This is a good choice and b) how the layout in the document DB would look so that i can wrap my head around proper documentDB structures?



It's more important to understand how you are using the data to know if MongoDB is a good fit, than what the data is.
So, how are you querying this data?   Are you only inserting new data or also updating and deleting?



I'm inserting, updating and occasionally deleting. The server reads this data when the person joins into the game, and any changes such as rank, awards, kills, deaths all update the data in the MapData role.

My Website queries this data for logging in, and for generating top 25 players in the map/color/world.



Sounds like you can do all that pretty simply in MongoDB - the best
way to figure out what your documents should look like it to look at
your source code - you have some objects/entities - those are likely
to map directly to documents in the DB.


댓글 없음:

댓글 쓰기