[MUD-Dev2] Persisting a MUD state with plain binary serialization

Mike Oxford szii at sziisoft.com
Tue Feb 10 14:21:52 CET 2009


Jeffrey Kesselman wrote:
> On Thu, Feb 5, 2009 at 11:01 AM, Tiago <tiago.matias at gmail.com> wrote:
>   
>>> Tiago wrote:
>>>
>>> Not sure what you mean by "binary serialization."  Just copying out of
>>> memory won't work as I'm sure you're aware.
>>>
>>>       
>> Well, by binary serialization, I was in fact refering to a facility
>> whithin.NET apps that simplify dumping an entire object graph do disk.
>> My biggestinterest in this was just the simplicity it offers. Just
>> callSerialize(World, filestream) and it's done.
>>
>> Problem is, like you might imagine, it's all or nothing. Anything
>> besidesthat very easily becomes a pain to implement. Another problem is
>> theversioning and upgrades (like you said). It effectively renders
>> datamigrations almost impossible.
>>
>> I'm considering manually serializing to XML some big game blocks like,
>> themap, the players, the mob's and the positions of these things in the
>> world.Then it would just be a matter of fixing the references as these
>> things aredeserialized back from the disk into memory
>>
>> The generated XML would obviously be human readable and writable and
>> wouldmake upgrading possible.
>>
>> Disadvantes: A lot more to code when what I would really want to be
>> doingwas programming MOB behaviour...
>>     
>
>
> If you dont want to use a pre-built solution, have considered using a
> real RDBMS like mysql?
>
> Not that hard to use really (at least from Java thanks to JDBC) and very
> very flexible.
>
>   
Along the same lines, it may be worth it to look at OODBMS as well.  
Again, though, you have to
deal with the upgrade path yourself. 

-mox




More information about the mud-dev2-archive mailing list