Howdy Alex, That shouldn't be happening. I've created an issue and I'll check into it as soon as I get a chance. You can track the issue here https://github.com/DistributedNonsense/CorrugatedIron/issues/171
--- Jeremiah Peschka - Founder, Brent Ozar Unlimited MCITP: SQL Server 2008, MVP Cloudera Certified Developer for Apache Hadoop On Wed, Sep 11, 2013 at 11:53 AM, Alex Rice <a...@mindlube.com> wrote: > Is there a way to trick corrugatediron into serializing a protobuf > class for me? I know I can serialize it to byte[] myself and Put that. > But I thought setting the ContentType might do the trick, but it looks > like it's getting saved as JSON instead. This might be a convenient > feature to add. > > // create a proto-contract class > (https://code.google.com/p/protobuf-net/wiki/GettingStarted) > var testObj = new Person() { > Id = 42, > Name = "alex", > Address = new Address() { > Line1 = "16 dusty road", > Line2 = "santa fe, nm 87508" > }}; > var riakObj = new RiakObject("test", "key", testObj); > riakObj.ContentType = RiakConstants.ContentTypes.ProtocolBuffers; > db.Put( riakObj ); > > _______________________________________________ > riak-users mailing list > riak-users@lists.basho.com > http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com >
_______________________________________________ riak-users mailing list riak-users@lists.basho.com http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com