IVOA LSST talk and JSON format for TAP
Thomas Boch
thomas.boch at astro.unistra.fr
Fri May 13 10:37:39 CEST 2016
> Hi Brian and DAL.
>
> Our approach matches your minimal version, and we have a client that runs a TAP request in JS, so I see a good case for JSON as an alternative option to VOTable.
> If we were to standardize, I would be cautious of over complicating it and having it lose the simplicity,which is the main reason why we are using it in the first place.
I agree. For outputs which consists in a single table, I'd stick to a
simple minimal approach. I can see the benefit of a 1 to 1 canonical
mapping from VOTable to JSON, but as you say the rather complex object
resulting from this transformation kind of defeats the initial purpose
(simplicity of JSON output).
I have Javascript code which queries Simbad TAP service and retrieve a
JSON output. It would be great if a JSON schema could be suggested so
that every TAP service implementor does not have to reinvent his own
JSON serialization.
Cheers,
--
Thomas
> There probably are cases that I have not thought about however, so I'd be interested to see other implementations as well.
>
> So +1 from me for adding a note for this.
>
> Cheers,
> Stelios Voutsinas
>
> ________________________________________
> From: dal-bounces at ivoa.net [dal-bounces at ivoa.net] on behalf of Van Klaveren, Brian N. [bvan at slac.stanford.edu]
> Sent: Thursday, May 12, 2016 4:17 PM
> To: dal at ivoa.net
> Subject: IVOA LSST talk and JSON format for TAP
>
> Apologies if this goes through multiple times... this internet is quite flaky.
>
>
>
> Hi all,
>
>
> If you are interested in my presentation about LSST and TAP/ADQL, i've uploaded the PDF to dropbox right now (until I can get it on the wiki):
>
> https://www.dropbox.com/s/l89mpih9dmk2q3a/LSST_DAX_IVOA_Interop_May-2016.pdf?dl=0
>
>
>
> Also, not sure if I'm going to make it to the meeting later, I need to take care of a few things for work as people in the US wake up and need a decent connection.
>
>
> That said, if you end up talking about JSON, I was just going to post my example JSON response format for TAP and mention a few things about it:
>
>
> https://gist.github.com/brianv0/07cf0acd83bde6f450a9
>
>
> From my perspective, there's two use cases of a JSON response for TAP.
>
>
> 1. A 1:1 (or near to it) alternative to VOTable.
>
> 2. A simplified/minimal version intended to be very easy to use from Javascript.
>
>
> For the first case, the output of something like that might look like the link above.
>
>
> For the second case, a minimal representation might look like this:
>
>
> {
>
> "columns": [
>
> {"name":"foo", "datatype":"int"},
>
> {"name":"bar", "datatype":"long"}
>
> {"name":"baz", "datatype":"double"}
>
> ],
>
> "data" : [
>
> [ 1, "1.12", 2.123]
>
> [ 2, "1.34", 2.345]
>
> [ 3, "1.56", 2.678]
>
> ]
>
> }
>
>
> This is extremely easy to deal with via javascript.
>
>
> i.e:
>
>
> var table = $(/* call TAP here via jquery */);
>
> table.columns.forEach(function(i){ console.log(i.name)}); // log names
>
> table.rows.forEach( doSomethingWIthRow );
>
>
>
> So, if you end up talking about a JSON format, please consider these two potential use cases.
>
>
> Thanks,
>
> Brian
>
--
Thomas Boch
Ingénieur de Recherche
CDS/Observatoire Astronomique Phone : 33 (0)3 68 85 24 42
11, rue de l'Universite Fax : 33 (0)3 68 85 24 17
F-67000 Strasbourg Email : thomas.boch at astro.unistra.fr
France http://cdsweb.u-strasbg.fr/~boch
More information about the dal
mailing list