What is the best approach to storing and managing high-performance mutable objects in Erlang? Suppose I want to write a really simple online game server with real-time gameplay. Somehow I need to imagine the state of the player in Erlang's memory. For example, it could just be a simple tuple, for example
{name, "Bob", health, 100, ammo, 50, score, 0}
These objects must be stored for a long time (at least as long as the user session is alive), they must be mutable (since players can interact with each other, for example, shoot at each other, kill, heal, etc.), and also high-performance (because the game is in real time, but not step by step). Therefore, I do not want to store this data in SQL or Mnesia. Which data structures are best suited?
source
share