Re: [core] Questions on draft-ietf-core-resource-directory-12

Christian Amsüss <christian@amsuess.com> Tue, 17 April 2018 13:18 UTC

Return-Path: <christian@amsuess.com>
X-Original-To: core@ietfa.amsl.com
Delivered-To: core@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 7F6F312EB3F; Tue, 17 Apr 2018 06:18:16 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.899
X-Spam-Level:
X-Spam-Status: No, score=-1.899 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id OA0md0m2UQkI; Tue, 17 Apr 2018 06:18:13 -0700 (PDT)
Received: from prometheus.amsuess.com (alt.prometheus.amsuess.com [IPv6:2a01:4f8:190:3064::3]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 53ECD12EB35; Tue, 17 Apr 2018 06:18:13 -0700 (PDT)
Received: from poseidon-mailhub.amsuess.com (095129206250.cust.akis.net [95.129.206.250]) by prometheus.amsuess.com (Postfix) with ESMTPS id 9587C497AD; Tue, 17 Apr 2018 15:18:10 +0200 (CEST)
Received: from poseidon-mailbox.amsuess.com (unknown [IPv6:2a02:b18:c13b:8010:a800:ff:fede:b1bf]) by poseidon-mailhub.amsuess.com (Postfix) with ESMTP id B669E1B2; Tue, 17 Apr 2018 15:18:06 +0200 (CEST)
Received: from hephaistos.amsuess.com (hephaistos.amsuess.com [IPv6:2a02:b18:c13b:8010::db8]) by poseidon-mailbox.amsuess.com (Postfix) with ESMTPSA id 1AD5D35F; Tue, 17 Apr 2018 15:18:06 +0200 (CEST)
Received: (nullmailer pid 15925 invoked by uid 1000); Tue, 17 Apr 2018 13:18:04 -0000
Date: Tue, 17 Apr 2018 15:18:04 +0200
From: Christian Amsüss <christian@amsuess.com>
To: Jim Schaad <ietf@augustcellars.com>
Cc: consultancy@vanderstok.org, draft-ietf-core-resource-directory@ietf.org, 'core' <core@ietf.org>
Message-ID: <20180417131803.GA3716@hephaistos.amsuess.com>
References: <053601d3c9e8$84da96f0$8e8fc4d0$@augustcellars.com> <7be5aeccaf53c373bcc999136dfec5cb@xs4all.nl> <06f101d3cc2d$8d3287d0$a7979770$@augustcellars.com> <0ef32a74d6b492e4e8e8fd4c917467c5@xs4all.nl> <20180413182947.GE18031@hephaistos.amsuess.com> <011f01d3d4fb$46f2bf70$d4d83e50$@augustcellars.com>
MIME-Version: 1.0
Content-Type: multipart/signed; micalg="pgp-sha256"; protocol="application/pgp-signature"; boundary="NzB8fVQJ5HfG6fxh"
Content-Disposition: inline
In-Reply-To: <011f01d3d4fb$46f2bf70$d4d83e50$@augustcellars.com>
User-Agent: Mutt/1.9.4 (2018-02-28)
Archived-At: <https://mailarchive.ietf.org/arch/msg/core/cYon7y48ctE4zH50eF9WuCXu__M>
Subject: Re: [core] Questions on draft-ietf-core-resource-directory-12
X-BeenThere: core@ietf.org
X-Mailman-Version: 2.1.22
Precedence: list
List-Id: "Constrained RESTful Environments \(CoRE\) Working Group list" <core.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/core>, <mailto:core-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/core/>
List-Post: <mailto:core@ietf.org>
List-Help: <mailto:core-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/core>, <mailto:core-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 17 Apr 2018 13:18:16 -0000

Hello Jim, hello RD authors,

On Sun, Apr 15, 2018 at 01:49:38PM -0700, Jim Schaad wrote:
> I am less worried about the observation jitter problems than I am about the
> turnover on groups.  Given that groups are defined in terms of the href
> returned from an endpoint registration this means that groups are going to
> be updated every time.  I really think that the location needs to not change
> for the lifetime of the registration not just the EXCHANGE_LIFETIME.  I am
> not sure that idempotent means anything useful when looking at doing
> registrations because I don't really know what it would mean to say
> something is idempotent here.   Does it mean that if nothing changes then
> nothing happens or just that if you register the same thing then the same
> set of events should happen w/ the same outcomes.

But the location does not change over the lifetime of the registration
(see also my parallel response to Peter at [1]) unless I got something
very wrong.

Only if an endpoint re-registers (ie. sends the same POST to /rd),
long-term idempotency does become the matter. But I'd argue that this is
close enough to situations of "the EP did not update its registration in
time and already got kicked out" than to regular updates.

Not that we'd already have an answer to how group management interacts
with temporarily timed-out clients; maybe we should solve that first and
then come back to the topic of idempotency.

[1]: https://mailarchive.ietf.org/arch/msg/core/IYkEs59MMdPWPH5nOjiYyO6juFY

> > > > 3.  How are href comparisons done.
> [...]
> 
> I am not sure what you are saying.  I do comparison followed by
> serialization at the moment.  I do the resolution during serialization and
> not during comparison.  This is the reason that I was asking the question.

I'd say "compare the resolved absolute references", in other words
"resolve, then compare, then serialize". That's more work for the RD
(and for you as an implementor), but matches more closely the
expectations of the client, and should be better suited for later steps
with protocol-negotiation.

> > We are not actually describing a distributed RD here, this is only
> > to keep the door open for such extensions.
> > 
> > Would it help if we changed the example to say
> > 
> > GET coap://rd.example.com/ep?gp=lights1
> > Res: 2.05 Content
> > <coap+tcp://rd.example.com/rd/abcd>;con="coap://[2001:db8:3::123]:61616";
> > ep="node1";et="oic.d.sensor";ct="40";lt="600",
> > </rd/efgh>;con="coap://[2001:db8:3::124]:61616";
> > ep="node2";et="oic.d.sensor";ct="40";lt="600"
> > 
> > ? It would just indicate that the registration resource is hosted by
> > the same RD but on another protocol (presumably because the endpoint
> > registered using coap+tcp, and that Location can't just jump
> > protocols).
> 
> Yeah, that whole question jumps back to the question - if it is on a
> different schema is it the same resource or a different resource.   I think
> that the example with the explanation would be better.

Unless something explicitly says that it is the same, it is not.

Text proposal at [2] for review by the other authors.

[2]: https://github.com/core-wg/resource-directory/pull/129

> > What use cases do we have for exposing a lifetime in the endpoint
> > lookup at all?
> > 
> > (If we have none, an RD might just as well not display a lifetime).
> 
> All of the cases that I can think of can be done with observe.  I think that
> this probably does not need to be discussed except to say that max-age
> should not be set to this value.

There is always a Max-Age, it has a default value of 60 (seconds).

> > I think that the more important question behind is of whether the RD
> > should (or may) wait with a response until it has fetched the .w-k/c
> > of the endpoint.  The example shows "respond first, then ask
> > details", which we might consider prescribing given that highly
> > constrained clients might not manage to multi-task the request and
> > the response. (Dealing 5.03 Sorry I'm Busy until their pending
> > request is answered or expired).
> 
> I would have done an ACK (to stop resends) followed by a response when the
> resources had been queried rather than returning two different responses
> that are different and would need to have a pending.  If the client cannot
> wait for the response, it knows that the message is being processed.
> However it would know not to shutdown until it has gotten a final answer.  I
> don't see any need to return some type of busy.  The constrained client
> should be able to respond to questions while it is in the middle of asking
> one.

I was not so much thinking about returning "busy" than about returning
"Success" in the sense of "I've got your request; whatever happens
further is out of your control".

Given that two RDs are behaving observably different here, I'm opening
this as an issue (basically "should we manadate your behavior or is
either fine, and if the latter do we need to warn simple client
implementors?") at [3].

[3]: https://github.com/core-wg/resource-directory/issues/130

Thanks for your input
Christian

-- 
To use raw power is to make yourself infinitely vulnerable to greater powers.
  -- Bene Gesserit axiom