I ran into a couple of issues with document namespaces.

SPDX 2.0, we define a document namespace as “unique absolute Uniform Resource 
Identifier (URI) as specified in RFC 2396”.  First, RFC 2396 has been obsoleted 
by RFC-3986<https://tools.ietf.org/html/rfc3986> (2396 was a draft, 3986 is the 
final version). I would suggest that we update this in the 2.1 spec.

Second, SPDX Tools currently require hierarchical URIs, specifically of the 
form schema://somethingelse. This is actually a Jena limitation, not something 
we impose.
But in the specs, this is not required for URIs, even “absolute” ones. The 
structure of the URI after the schema is defined by schema. So unless we 
proscribe a specific schema, we can’t mandate a specific hierarchical syntax 
without deviating from the RFCs (see RFC 2396 section 
3<http://tools.ietf.org/html/rfc2396#section-3> or the newer RFC3986 section 
4.3<https://tools.ietf.org/html/rfc3986#section-4.3>). This is further 
specified in RFC-7320 (which amends 3986) section 
2.3<https://tools.ietf.org/html/rfc7320#section-2.3>:


   Scheme definitions define the presence, format, and semantics of a
   path component in URIs; all other specifications MUST NOT constrain,
   or define the structure or the semantics for any path component.

   The only exception to this requirement is registered "well-known"
   URIs, as specified by [RFC5785<https://tools.ietf.org/html/rfc5785>].  See 
that document for a description
   of the applicability of that mechanism.

   For example, an application ought not specify a fixed URI path
   "/myapp", since this usurps the host's control of that space.


So my point here is, if we want to maintain the document namespace format as 
schema://somethingelse, then, I submit, we need to indicate this as a deviation 
from the URI spec, just as we do with the prohibition of “#”. And if the 
schema:somethingelse format is acceptable, then we should fix SPDX tools or 
update (or tweak) the prohibitive code in Jena.

Sorry for the convoluted email.


[cid:7EA68D51-363B-4FAD-A939-D9CD926D70AB]
Yev Bronshteyn
Senior Software Engineer
Black Duck Software<http://www.blackducksoftware.com/>
_______________________________________________
Spdx-tech mailing list
[email protected]
https://lists.spdx.org/mailman/listinfo/spdx-tech

Reply via email to