[Opensim-dev] what to use for serializing structures? LLSD? XmlSerializer? JSON?

Sean Dague sean at dague.net
Wed May 14 13:57:40 UTC 2008


On Wed, May 14, 2008 at 01:55:58PM +0100, Justin Clark-Casey wrote:
> Dr Scofield wrote:
> > Stefan Andersson wrote:
> >> Ok, next time, I'll half the dose of that cough syrup.
> >>  
> >> Aaanyway : I still think it's a REALLY bad idea to put forward as a 
> >> 'standard region API' something that is more 
> >> application-and-environment specific (JSON) when there is something 
> >> that is less application-and-environment specific (XML)
> > oops...this is not a standard region API, this is supposed to be a 
> > control API to allow us to control region specific information of an 
> > OpenSim instance.
> >> Is there a concrete win with Json over Xml that I'm missing?
> > i'd say, easy to parse from AJAX side, less verbose, doesn't require 
> > knowledge of the class definition to make sense of it (well, at least to 
> > some extent).
> 
>  From what I've read of JSON, I don't believe it's tied to any specific 
> language - to some extent it just happens to be directly evaluatable in 
> Javascript since that was from where it originated.
> 
> However, I do personally prefer XML - there are just more tools and 
> libraries out there for it and it's more familiar.  I'm not sure the 
> possible advantages of JSON (e.g. less verbosity, though I'm not sure 
> that's an issue here) outweigh that.

While I personally prefer the readability of JSON, I think for the
OpenSim project XML makes more sense.  Our cannonical serialization
models will end up in XML, and that will be our standard interchange
format.  All languages do pretty well with XML at this point. :)  (it is
the X in AJAX).

That being said, by definition, REST base approaches are supposed to
support the Content-Type header.  As long as that serialization
seperation is handled correctly, we could build JSON/Text/Image whatever
formats down the road.

> Oh, and regarding LLSD - yes, let's confine that to linden interop and 
> not use it as our core REST format.

LLSD is super extra verbose for a wire protocol, so +1.

     -Sean

-- 
__________________________________________________________________

Sean Dague                                       Mid-Hudson Valley
sean at dague dot net                            Linux Users Group
http://dague.net                                 http://mhvlug.org

There is no silver bullet.  Plus, werewolves make better neighbors
than zombies, and they tend to keep the vampire population down.
__________________________________________________________________
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://opensimulator.org/pipermail/opensim-dev/attachments/20080514/100722a6/attachment-0001.pgp>


More information about the Opensim-dev mailing list