-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Question about URN notation #1
Comments
Makita-san, I had not been aware of the NID aspect of URNs (or if I ever was aware of it, I had forgotten it). "pubid" is my private convention and is not a registered URI namespace. I didn't realize that I was violating URN rules (I had though that whatever followed "urn:" was pretty much unconstrained). However, in investigating this I did learn that "publicid" IS a registered namespace: http://tools.ietf.org/html/rfc3151 I will start using "publicid" going forward. If you read the RFC for "publicid" you will see that it defines rules for transcribing SGML-style public IDs into URN syntax. However, I can't find any requirement in the XML specification that requires public IDs to use the SGML syntax. So I think that means I'm safe in using "publicid" as the URN namespace and then using any string (that otherwise conforms to the URN syntax rules) for the name. Thank you for bringing this to my attention--it is difficult to keep up with all the various Internet standards and this detail had clearly escaped me. Cheers, Eliot |
It looks like I was wrong, at least in terms of how Norm Walsh interprets "publicid" handling: the Xerces resolver code treats URNs with NID's of "publicid" specially, translating the name back into public ID syntax before doing catalog resolution. That means that "publicid" cannot be used for normal URN-syntax strings (e.g., "foo:bar:baz"). I will have to consider what this means. I may pursue registering "public" or "pubid" for use as an alternative to "publicid" where the only rule would be that the first colon-delimited token be the owner identifier, e.g., "example.org". |
Perhaps registering a more general term, such as "doc", would be better On Sun, Nov 23, 2014 at 8:08 AM, Eliot Kimber notifications@github.com
Bob Thomas |
I'm not sure "doc" would be right since the public IDs generally don't identify documents (in the general sense) but non-document things (DTD components, grammar components, etc.). For now I'm using "X-pubid" since that is allowed by the RFCs. |
It's even more interesting than I realized because the "X-" convention has been formally deprecated: http://tools.ietf.org/html/rfc6648 So I think I'm back to just using "pubid" as I was, but I'll attempt to use it consistently and consider registering it sooner rather than later. |
Mr. Kimber, Thank you for your detailed analysis.
Yes, I confirmed that following two document type declaration are the same when validating a topic against the DTD bundled with DITA-OT 1.8.5.
I didn't know that there is such RFC. In the past when I tried to make specialization with XML Schema, I used the following URN notation.
I’m not still sure what is the best way to make own URN for XSD or RNG DITA specialization. Regards, |
RFC6648 refers “X-“ prefix as “Application Protocols”. But RFC3406 defines X-<NID> as “Experimental Namespaces”. Are they surely intended the same purpose? |
I saw the reference to RFC 6648 specifically in the context of URNs and I think it does apply--the justification is primarily about avoiding the need to migrate from using "X-" to just "", which leads to interoperation issues and confusion. The purpose of the NID field of URNs seems a little ambiguous to me: it could be seen as a general protocol indicator (as "publicid" is), governing names regardless of ownership, or it could be seen as an "owner identifier", which is how the the "oasis" NID is used: it confers ownership of all such names to OASIS. My personal analysis is that the NID is more appropriately used for protocol distinction, not ownership, so I think using something like "pubid" and then having the next field be the owner identifier is the best approach, e.g.: urn:pubid:example.org:{whatever you want for a specific resource} And that's the convention I've been using. Thus I would recommend something like: urn:pubid:antennahouse.com:dita:xsd:topic.xsd I think the intent of the URN is made clear by the "pubid" NID, ownership is made clear by "antennahouse.com", and the rest follows the OASIS convention (which otherwise has no particular magic, it's just a unique string value). It seems highly unlikely that anyone that is not Antenna House would accidentally use "pubid:antennahouse.com" in any URN, so I think uniqueness is effectively guaranteed. |
pubid will work; although including "id" in the string is somewhat On Mon, Nov 24, 2014 at 7:48 AM, Eliot Kimber notifications@github.com
Bob Thomas |
The reason I prefer "pubid" over "public" is that "public" is very generic. I would have used "publicid" myself if it wasn't already taken. Could also use "xmlpublic" or "xmlpubid" I guess to make it clear that the use domain is XML stuff. That might be a better name. |
I have a slight preference for "xmlpublic". However, I am so used to On Mon, Nov 24, 2014 at 9:30 AM, Eliot Kimber notifications@github.com
Bob Thomas |
After the DITA-OT Day held on Nov 20, 2014 I have been searching the DITA specialization example written in RELAX NG and finally I reached this repository.
Seeing specialization in topic.rng is very useful. But I have one question in URN notation of this specialization of the following file.
org.dita-community.doctypes / doctypes / topic / rng / catalog.xml
In this catalog file there are following URN notation.
The feature of this notation is using “pubid” as NID. Generally URN is defined as following BNF notaion.
http://tools.ietf.org/html/rfc2141
But as far as I know using “pubid” as NID is not found in Uniform Resource Names (URN) Namespaces.
http://www.iana.org/assignments/urn-namespaces/urn-namespaces.xhtml
Is using “pubid” officially recognized as NID?
As I’m new to RELAX NG specialization and URN, please comment me if my understanding has any mistakes.
Regards,
The text was updated successfully, but these errors were encountered: