Usually I'm all for records because of pattern matching and compile-time checking. IMHO, broken upgrades are reason enough not to use them directly for storage. I have yet to design a system where the data structures never changed after the initial release. I hate to say it but, for me, the answer may be to have functions which map between records and orddicts/proplists. I guess this really isn't a riak-specific issue, but its interesting to hear with other people think about it.
Dave On Mon, Apr 26, 2010 at 10:18 AM, Eric Cestari <[email protected]> wrote: > > Le 26 avr. 2010 à 15:10, Sean Cribbs a écrit : > >> Yes, the primary weakness of records would be upgrading them. You could do >> it with a map-reduce job, but it would be better in general to use a more >> fluid data structure. >> > In the defense of records : > Records can be pattern matched whereas dicts and proplists can't. > Using a record with dict attributes and single attributes for pattern > matching ("state" attribute, or "type" ...) could be interesting. > > Eric > > http://twitter.com/cstar > > _______________________________________________ riak-users mailing list [email protected] http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
