Re: [apps-discuss] JSON Schema considered harmful

Francis Galiegue <fgaliegue@gmail.com> Thu, 20 September 2012 20:54 UTC

Return-Path: <fgaliegue@gmail.com>
X-Original-To: apps-discuss@ietfa.amsl.com
Delivered-To: apps-discuss@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 0A6D721E803A for <apps-discuss@ietfa.amsl.com>; Thu, 20 Sep 2012 13:54:46 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -3.63
X-Spam-Level:
X-Spam-Status: No, score=-3.63 tagged_above=-999 required=5 tests=[AWL=-0.031, BAYES_00=-2.599, RCVD_IN_DNSWL_LOW=-1]
Received: from mail.ietf.org ([64.170.98.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id b4o2I85zFWxF for <apps-discuss@ietfa.amsl.com>; Thu, 20 Sep 2012 13:54:45 -0700 (PDT)
Received: from mail-vc0-f172.google.com (mail-vc0-f172.google.com [209.85.220.172]) by ietfa.amsl.com (Postfix) with ESMTP id 3497E21E805F for <apps-discuss@ietf.org>; Thu, 20 Sep 2012 13:54:45 -0700 (PDT)
Received: by vcbfo14 with SMTP id fo14so3355670vcb.31 for <apps-discuss@ietf.org>; Thu, 20 Sep 2012 13:54:44 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; bh=Mlgfm6SMsQPym+L2IQcx6CZGb1aR2xP3PTO1XgGmG7w=; b=gi9TKNxa/AseCezoWCG6l+5HneMxasPu4rgysm+kPW9zpxd3n72Hh1z6Nx0t1YAZYX iC0Wb+6RG1MIdPZCfkd57iMtnWtmD1A/x2BPEMJASluh5I2fU2GsxJlhJbFj08lCiw9J xAnq4bQvCmrnHHVS3SwKs1Ird+kyXCQxBvmGgknVRlgarHJgq9bChuaNK6a8uB6jtmmC QlHDSrxzJJPOt87uLbBD1Fh3qhciGN01XoWSvyTCqWBSwYx1B2z/flzNvbcsDMz4dySA szsusxzWmZNA7podB5u5gMMDuoz2lHvhFE8UUJKcCsAoICIn/c7zGYW/9Kpxm/hHMC0I chfA==
MIME-Version: 1.0
Received: by 10.52.64.209 with SMTP id q17mr1444328vds.32.1348174484734; Thu, 20 Sep 2012 13:54:44 -0700 (PDT)
Received: by 10.52.72.137 with HTTP; Thu, 20 Sep 2012 13:54:44 -0700 (PDT)
In-Reply-To: <505B7B96.2010808@bbiw.net>
References: <CAMm+LwjYj0gd3Cxjj8WFcLy-zgBwfVDCPaRGcNSgOHD9m_07yw@mail.gmail.com> <999913AB42CC9341B05A99BBF358718D01DF0684@FIESEXC035.nsn-intra.net> <CAK3OfOgU-Kepre2Z2dg_S8DAVCU413SRvuWMvJcC3BmE0BjNbQ@mail.gmail.com> <505B43B3.7050503@berkeley.edu> <CAHBU6iupyZEhENRVYJ2sMNk79RSZbOVAawr6vP42uzNyO0z+Nw@mail.gmail.com> <77AFECFB-F63A-457F-9C7F-F715315C0651@mnot.net> <505B78B4.80309@dcrocker.net> <CAHBU6istjQ+vxtgBXE4aQ011tcOgudkxK9tq8e6enG8u+k_M-g@mail.gmail.com> <505B7B96.2010808@bbiw.net>
Date: Thu, 20 Sep 2012 22:54:44 +0200
Message-ID: <CALcybBBykpyYXNZOuG=hwOx1KRXRwK6CHk+ozB0gv5Du=-SyxA@mail.gmail.com>
From: Francis Galiegue <fgaliegue@gmail.com>
To: Dave Crocker <dcrocker@bbiw.net>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
Cc: Mark Nottingham <mnot@mnot.net>, apps-discuss@ietf.org
Subject: Re: [apps-discuss] JSON Schema considered harmful
X-BeenThere: apps-discuss@ietf.org
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: General discussion of application-layer protocols <apps-discuss.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/apps-discuss>, <mailto:apps-discuss-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/apps-discuss>
List-Post: <mailto:apps-discuss@ietf.org>
List-Help: <mailto:apps-discuss-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/apps-discuss>, <mailto:apps-discuss-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 20 Sep 2012 20:54:46 -0000

On Thu, Sep 20, 2012 at 10:24 PM, Dave Crocker <dcrocker@bbiw.net> wrote:
[...]
>
> I was suggesting a small-but-useful subset, which I thought was nicely
> exemplified by the terse list of practical direction of the precipitating
> note about choosing a notation language.
>
> Very narrow topic.  Very important.  Often very religious and very confused.
>
> Just the stuff of a BCP, IMO...
>

I-D 3 of JSON Schema has it: a "small-but-useful subset", which can be
used to describe _any_ JSON value. It has sufficient intrinsic value
that it is being used, for instance, by the Google discovery API.

However, there was room for improvement. In particular, the fact that
the core schema keywords were not fully defined, and also section 5.27
which has been a constant source of misinterpretation. And the fact
that some "untold", but important stuff, was lurking behind. And this
is precisely the goal that this ad-hoc organization "of no value" is
pursuing, and why it takes time. But XSD is at best a goal NOT to
pursue.

And yes, all keywords are meant to define the _structure_ of JSON data
anyway. Semantic validation keywords exist, but the goal is to make
them optional.

In any case, I-Ds will be submitted via the official mechanism. Some
refining is needed before that.

-- 
Francis Galiegue, fgaliegue@gmail.com
JSON Schema: https://github.com/json-schema
"It seems obvious [...] that at least some 'business intelligence'
tools invest so much intelligence on the business side that they have
nothing left for generating SQL queries" (Stéphane Faroult, in "The
Art of SQL", ISBN 0-596-00894-5)