You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would like the v.Nu servlet to make the v.Nu RELAX NG compact syntax schema files available via HTTP.
I would like the path component of these HTTP URLs to be /schema, followed by the paths specified by the http://s.validator.nu URLs listed in nu/validator/localentities/files/entitymap.
For example, if I start the servlet with the following command:
I will freely admit that this issue is related to issue #251. However, here, I'm not asking for any changes to schemas; just to make available via HTTP the schemas as they are already distributed, with no changes.
Perhaps this is already possible, but I've overlooked it? (I've looked at the source: the direct get requests to the servlet appear to be restricted to a small number of files.)
Just a thought (I'm a Java newbie, so, with apologies, this might be utter nonsense)... you could add to the doGet method in src/nu/validator/servlet/VerifierServlet.java a check for request paths that begin with /schema, then use LocalCacheEntityResolver.resolveEntity to check for the existence of a corresponding URI in entitymap; if it exists, return the corresponding .rnc file as content type application/relax-ng-compact-syntax (as per LocalCacheEntityResolver.getType).
The text was updated successfully, but these errors were encountered:
I will freely admit that this issue is related to issue #251. However, here, I'm not asking for any changes to schemas; just to make available via HTTP the schemas as they are already distributed, with no changes.
That’s a non-trivial just.
Perhaps this is already possible, but I've overlooked it?
The service does not in any way right now expose the schemas in the way you describe. It would certainly be do-able to make it expose them that way, but it’s not something that it seems like there’s a wide need for and for me at least is nowhere near registering as important enough to just me spending time on implementing it.
I would be happy to review a patch that provided it but even then I’m not certain we would want to go ahead and just land it even if we had it. But anyway the first step would be having a concrete patch.
You can probably see where I'm going with this: if a user already has the servlet running, then they could point their other tools, such as validating XML editors, at the HTTP URLs I'm proposing for the schemas, so that their editors would be using exactly the same RELAX NG schemas as their instance of v.Nu, without having to use a script to extract the schemas from the files directory in the .jar, and rename'n'copy them into a structure corresponding to the URLs in the entitymap.
I would like the v.Nu servlet to make the v.Nu RELAX NG compact syntax schema files available via HTTP.
I would like the path component of these HTTP URLs to be
/schema
, followed by the paths specified by thehttp://s.validator.nu
URLs listed innu/validator/localentities/files/entitymap
.For example, if I start the servlet with the following command:
then I would like to use the following URL:
to get the file referred to in
entitymap
as:Similarly (note the
html5
subdirectory in the path):to get:
I will freely admit that this issue is related to issue #251. However, here, I'm not asking for any changes to schemas; just to make available via HTTP the schemas as they are already distributed, with no changes.
Perhaps this is already possible, but I've overlooked it? (I've looked at the source: the direct get requests to the servlet appear to be restricted to a small number of files.)
Just a thought (I'm a Java newbie, so, with apologies, this might be utter nonsense)... you could add to the
doGet
method insrc/nu/validator/servlet/VerifierServlet.java
a check for request paths that begin with/schema
, then useLocalCacheEntityResolver.resolveEntity
to check for the existence of a corresponding URI inentitymap
; if it exists, return the corresponding.rnc
file as content typeapplication/relax-ng-compact-syntax
(as perLocalCacheEntityResolver.getType
).The text was updated successfully, but these errors were encountered: