<?xml version='1.0' encoding='utf-8'?>
<!DOCTYPE rfc [
  <!ENTITY nbsp    "&#160;">
  <!ENTITY zwsp   "&#8203;">
  <!ENTITY nbhy   "&#8209;">
  <!ENTITY wj     "&#8288;">
]>
<?xml-stylesheet type="text/xsl" href="rfc2629.xslt" ?>
<!-- generated by https://github.com/cabo/kramdown-rfc version 1.6.33 (Ruby 3.2.1) -->
<rfc xmlns:xi="http://www.w3.org/2001/XInclude" ipr="trust200902" docName="draft-bormann-asdf-sdftype-link-01" category="std" consensus="true" submissionType="IETF" tocInclude="true" sortRefs="true" symRefs="true" version="3">
  <!-- xml2rfc v2v3 conversion 3.17.1 -->
  <front>
    <title abbrev="sdfType for Links">An sdfType for Links</title>
    <seriesInfo name="Internet-Draft" value="draft-bormann-asdf-sdftype-link-01"/>
    <author initials="C." surname="Bormann" fullname="Carsten Bormann">
      <organization>Universität Bremen TZI</organization>
      <address>
        <postal>
          <street>Postfach 330440</street>
          <city>Bremen</city>
          <code>D-28359</code>
          <country>Germany</country>
        </postal>
        <phone>+49-421-218-63921</phone>
        <email>cabo@tzi.org</email>
      </address>
    </author>
    <date year="2023" month="June" day="03"/>
    <area>Applications and Real-Time</area>
    <workgroup>ASDF WG</workgroup>
    <keyword>IoT</keyword>
    <keyword>Link</keyword>
    <keyword>Web Linking</keyword>
    <abstract>
      <?line 44?>

<t>This document defines and registers an sdfType "link" for the
Semantic Definition Format (SDF) for Data and Interactions of Things
(draft-ietf-asdf-sdf).</t>
    </abstract>
    <note removeInRFC="true">
      <name>About This Document</name>
      <t>
        Status information for this document may be found at <eref target="https://datatracker.ietf.org/doc/draft-bormann-asdf-sdftype-link/"/>.
      </t>
      <t>
        Discussion of this document takes place on the
        A Semantic Definition Format for Data and Interactions of Things Working Group mailing list (<eref target="mailto:asdf@ietf.org"/>),
        which is archived at <eref target="https://mailarchive.ietf.org/arch/browse/asdf/"/>.
        Subscribe at <eref target="https://www.ietf.org/mailman/listinfo/asdf/"/>.
      </t>
      <t>Source for this draft and an issue tracker can be found at
        <eref target="https://github.com/cabo/sdftype-link"/>.</t>
    </note>
  </front>
  <middle>
    <?line 50?>

<section anchor="introduction">
      <name>Introduction</name>
      <t>The Semantic Definition Format for Data and Interactions of Things
(SDF, <xref target="I-D.ietf-asdf-sdf"/>) is a format for domain experts to use in the creation
and maintenance of data and interaction models in the Internet of
Things.</t>
      <t>A common data type that occurs in the modeling of IoT devices is the
<em>link</em>.
<xref target="RFC8288"/> defines the concept of Web Linking, which complements the
target URI that any link will contain, with additional parameters, such
as the "link relation type" that explains the relationship expressed
by the link, as well as "target attributes" that provide additional
information about the target of the link (without a need to
"dereference", i.e., follow, the link).</t>
      <t>This document defines and registers an sdfType "link" for the Semantic
Definition Format.
This type models an abstract "serialization" <xref target="RFC8288"/> of a link, in a
way that is compatible with the way SDF maps information models to its
data modeling language.</t>
      <section anchor="conventions-and-definitions">
        <name>Conventions and Definitions</name>
        <!--
{: :boilerplate bcp14-tagged}
 -->

<t>The definitions of <xref target="RFC6690"/>, <xref target="RFC8288"/>, and <xref target="I-D.ietf-asdf-sdf"/> apply.</t>
      </section>
    </section>
    <section anchor="the-sdftype-link">
      <name>The sdfType "link"</name>
      <t>The sdfType "link" is intended to be used with the SDF "type" of "object".
The members of that object are strings that are named the same as the
link parameter (attribute) names.
The special parameter name "href" is used to express the link target.
(Parameter names specific to the Constrained RESTful Environment (CoRE) are also discussed in <xref target="I-D.ietf-core-target-attr"/>.)</t>
      <t>An example for the instance of a link is provided in <xref section="5" sectionFormat="of" target="RFC6690"/>:</t>
      <sourcecode type="link-format"><![CDATA[
   </sensors/temp>;rt="temperature-c";if="sensor",
]]></sourcecode>
      <t>An sdfProperty that is used to describe an SDF affordance that is intended to
hold a link like this (without getting specific on the actual link to
the link target) could look like:</t>
      <sourcecode type="sdf"><![CDATA[
{
 "sdfProperty": {
  "temp-c-link": {
   "type": "object",
   "sdfType": "link",
   "properties": {
     "href": { "type": "string"},
     "rt": { "type": "string", "const": "temperature-c"},
     "if": { "type": "string", "const": "sensor"}
   }
  }
 }
}
]]></sourcecode>
    </section>
    <section anchor="discussion">
      <name>Discussion</name>
      <t>Links play an important role in SDF modeling both during definition
time (for adding information to a model, as e.g., in <tt>sdfRef</tt>) and
during run time (for making links to instances into a subject of data
and interaction modeling).
The present document is an early attempt at addressing the run-time
usage of links, in particular links that fit the Web Linking <xref target="RFC8288"/>
abstractions.
A related draft <xref target="I-D.laari-asdf-relations"/> addresses definition-time links, but does
seem to touch modeling run-time use of links as well (e.g., by
discussing "writable" link relations).</t>
      <t>Not all links used in ecosystems are based on URIs.
E.g., OMA has "object links", which are pairs of numbers (object/instance).
These ecosystem links may have some structure that should be modeled
in the SDF model (e.g., where the object id part of a link always has
to have a specific value).
This structure can be mapped into URI strings using some convention,
e.g., an OMA object link could be <tt>oma-object:3303:0</tt> (where
<tt>oma-object</tt> is placeholder for a URI scheme to be defined).
However, burying structural components of the ecosystem-specific link
in a string syntax makes it hard to access and control those
components from the model.</t>
      <t>TODO: Examples are needed to show how the OCF collection pattern is
addressed by the current specification.</t>
    </section>
    <section anchor="security-considerations">
      <name>Security Considerations</name>
      <t>The security considerations of <xref target="RFC8288"/> apply in a general way,
although modeling a link as a datatype does not incur all of the
security considerations that will apply to actually interchanging
these links.</t>
      <t>(TODO)</t>
    </section>
    <section anchor="iana-considerations">
      <name>IANA Considerations</name>
      <t>// RFC Ed.: please replace RFC XXXX with this RFC number and remove this note.</t>
      <t>IANA is requested to register the sdfType "link" in the "sdfType Values" sub-registry in
the "SDF Parameters" registry, with the following completion for the
registration template:</t>
      <table anchor="sdftype-r">
        <name>Registration for sdfType "link"</name>
        <thead>
          <tr>
            <th align="left">Name</th>
            <th align="left">Description</th>
            <th align="left">type</th>
            <th align="left">JSON Representation</th>
            <th align="left">Reference</th>
          </tr>
        </thead>
        <tbody>
          <tr>
            <td align="left">link</td>
            <td align="left">A Web Link <xref target="RFC8288"/></td>
            <td align="left">object</td>
            <td align="left">object members for link attributes</td>
            <td align="left">RFCXXXX</td>
          </tr>
        </tbody>
      </table>
    </section>
  </middle>
  <back>
    <references>
      <name>References</name>
      <references>
        <name>Normative References</name>
        <reference anchor="I-D.ietf-asdf-sdf">
          <front>
            <title>Semantic Definition Format (SDF) for Data and Interactions of Things</title>
            <author fullname="Michael Koster" initials="M." surname="Koster">
              <organization>PassiveLogic</organization>
            </author>
            <author fullname="Carsten Bormann" initials="C." surname="Bormann">
              <organization>Universität Bremen TZI</organization>
            </author>
            <date day="12" month="January" year="2023"/>
            <abstract>
              <t>   The Semantic Definition Format (SDF) is a format for domain experts
   to use in the creation and maintenance of data and interaction models
   in the Internet of Things.  An SDF specification describes
   definitions of SDF Objects and their associated interactions (Events,
   Actions, Properties), as well as the Data types for the information
   exchanged in those interactions.  Tools convert this format to
   database formats and other serializations as needed.


   // A JSON format representation of SDF 1.0 was defined in version
   // (-00) of this document; version (-05) was designated as an
   // _implementation draft_, labeled SDF 1.1, at the IETF110 meeting of
   // the ASDF WG (2021-03-11).  The present version (-13) collects
   // smaller changes up to 2023-01-12.

              </t>
            </abstract>
          </front>
          <seriesInfo name="Internet-Draft" value="draft-ietf-asdf-sdf-13"/>
        </reference>
        <reference anchor="RFC8288">
          <front>
            <title>Web Linking</title>
            <author fullname="M. Nottingham" initials="M." surname="Nottingham">
              <organization/>
            </author>
            <date month="October" year="2017"/>
            <abstract>
              <t>This specification defines a model for the relationships between resources on the Web ("links") and the type of those relationships ("link relation types").</t>
              <t>It also defines the serialisation of such links in HTTP headers with the Link header field.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="8288"/>
          <seriesInfo name="DOI" value="10.17487/RFC8288"/>
        </reference>
      </references>
      <references>
        <name>Informative References</name>
        <reference anchor="RFC6690">
          <front>
            <title>Constrained RESTful Environments (CoRE) Link Format</title>
            <author fullname="Z. Shelby" initials="Z." surname="Shelby">
              <organization/>
            </author>
            <date month="August" year="2012"/>
            <abstract>
              <t>This specification defines Web Linking using a link format for use by constrained web servers to describe hosted resources, their attributes, and other relationships between links.  Based on the HTTP Link Header field defined in RFC 5988, the Constrained RESTful Environments (CoRE) Link Format is carried as a payload and is assigned an Internet media type.  "RESTful" refers to the Representational State Transfer (REST) architecture.  A well-known URI is defined as a default entry point for requesting the links hosted by a server.  [STANDARDS-TRACK]</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="6690"/>
          <seriesInfo name="DOI" value="10.17487/RFC6690"/>
        </reference>
        <reference anchor="I-D.laari-asdf-relations">
          <front>
            <title>Extended relation information for Semantic Definition Format (SDF)</title>
            <author fullname="Petri Laari" initials="P." surname="Laari">
              <organization>Ericsson</organization>
            </author>
            <date day="12" month="December" year="2022"/>
            <abstract>
              <t>   The Semantic Definition Format (SDF) base specification defines set
   of basic information elements that can be used for describing a large
   share of the existing data models from different ecosystems.  While
   these data models are typically very simple, such as basic sensors
   definitions, more complex models, and in particular bigger systems,
   benefit from ability to describe additional information on how
   different definitions relate to each other.  This document specifies
   an extension to SDF for describing complex relationships and
   additional information about them.

              </t>
            </abstract>
          </front>
          <seriesInfo name="Internet-Draft" value="draft-laari-asdf-relations-01"/>
        </reference>
        <reference anchor="I-D.ietf-core-target-attr">
          <front>
            <title>CoRE Target Attributes Registry</title>
            <author fullname="Carsten Bormann" initials="C." surname="Bormann">
              <organization>Universität Bremen TZI</organization>
            </author>
            <date day="5" month="March" year="2023"/>
            <abstract>
              <t>   The Constrained RESTful Environments (CoRE) specifications apply Web
   technologies to constrained environments.  One important such
   technology is Web Linking (RFC 8288), which CoRE uses as the basis
   for a number of discovery protocols, such as the Link Format (RFC
   6690) in CoAP's Resource Discovery Protocol (Section 7.2 of RFC7252)
   and the Resource Directory (RFC 9176).

   Web Links can have target attributes, the names of which are not
   generally coordinated by the Web Linking specification (Section 2.2
   of RFC 8288).  This document introduces an IANA registry for
   coordinating names of target attributes when used in Constrained
   RESTful Environments.  It updates the RD Parameters Registry of RFC
   9176 to coordinate with this registry.

              </t>
            </abstract>
          </front>
          <seriesInfo name="Internet-Draft" value="draft-ietf-core-target-attr-04"/>
        </reference>
      </references>
    </references>
    <?line 167?>

<section numbered="false" anchor="acknowledgments">
      <name>Acknowledgments</name>
      <t>Discussions in the OneDM liaison organization shaped this proposal.</t>
    </section>
  </back>
  <!-- ##markdown-source:
H4sIAAAAAAAAA6VY7XIbtxX9j6dA13+kmEvZluOxN3Emij5SdRorIytNp5Mf
BndBEtXuYgtgxTAW/TR9k75Yz73A7lK2m+lMOEOJXAD389x7D5jnuQgm1LqQ
J6301fJm22m5tE7+1bS3XqjFwum74jMrpQp6Zd0Wa6ESPjitmkJent9ciNK2
Xre+94UMrtdCVLZsVQMdlVPLkC+sa1Tb5gpSc7wDJOc1pOY1hPog2r5ZaFeI
Cl8LAfXHQkF+IbOTrqsNVBuokKqt5LVWdX5jGp2JjXW3K2f7Dr68PbuQP38v
bvUWT6tCyFxe2hv6R9bT/5/1gj+bdiXudNtDkZTpeHYi32qYGEwpz/TStIYU
yguyO3AMzlRQrP+yDdqpMhpkl/JmDYE+g6xGmRqiyMlvjQ7LuXUrer4yYd0v
sFKqhT3adz8TQqg+rC1cz7EzxuxUOR90K7+LUcNzCCrkT625086b8J9/B/md
0w223PzjEsuUCx0K+aP1YanKtTw+fvL8+ROslCYgX3EzfbUV5J/lz14ef/mK
v/dtoIx+r0nVFo+6tW2x5/HzV/nzZ0/zZ09f5i+OXz17iiUdHSQvvg2/GXJP
iJZDBMsompf52Zw8HxPNOMLC9cXpy2cvXxaSvBbCtMv9Y1h98eLVk7iax6Uk
rVbKmSjO6TrCgIXi277C0jqdB+VWOuQqBFdI+itEnudSLRAgZEwI5MpLYLNH
OIKsKNE6osrplUHQHX0bsZ9xjjj9Ya3F7yDkAPA7/H9wIg5iRTyI0uE8GtqY
qqpRPY/osLNVz6fJbP0H4SnIwJl8/57U7XaHEnFQcjmdryyS20r9a6dd8DJY
2Xst8QSOyxKlyJaQAtoHdKq21CS/GhSbSbFsgLPaD8fZpFYHbBfRHPh7AvA1
DfayAKoI7IUxtix7Nx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