Skip to content
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

Supported URI-Schemes in Catalog-Files #1477

Open
blasss opened this issue Feb 9, 2023 · 5 comments
Open

Supported URI-Schemes in Catalog-Files #1477

blasss opened this issue Feb 9, 2023 · 5 comments
Assignees
Labels
enhancement New feature or request

Comments

@blasss
Copy link

blasss commented Feb 9, 2023

I'm currently considering to contribute a PR for [https://github.com/eclipse-wildwebdeveloper/wildwebdeveloper/issues/1078] and therefore would like to check what kind of URI-schemes ('protocols') are supported for schemas in XML catalog files.
Basically I would assume this will be handled by Xerces and therefore should be able to cope with any scheme that is supported by standard Java.

Is there any additional processing in LemMinX that would restrict the list of supported schemes?

Practically jar:-URIs will be involved and are working in my environment from what I can tell. But I would like to check to avoid pure coincidence...

@fbricon fbricon added the enhancement New feature or request label Feb 9, 2023
@angelozerr
Copy link
Contributor

Today we support file, http, https scheme but Im not sure that xerces support jar scheme.

Could you attach a simple jar which could contains an xsd and an xml file which is linked to the xsd coing from the jar. Thanks

@blasss
Copy link
Author

blasss commented Feb 10, 2023

I attached lemminx_1477.zip with the following content:

  • acme.jar - jar with a xsd located in com/acme/order/order.xsd
  • order.xml - example xml-file that uses the schema
  • system-catalog.xml - catalog-file that references the order.xsd with a jar:-URI. Unfortunately it requires to put the archive in the correct place (C:/temp/acme.jar)...

The xml-file was created using the xsd and should therefore be perfectly valid. The catalog-file lacks testing so far.

@angelozerr
Copy link
Contributor

Thanks @blasss for your sample. Let' sme investigate how LemMinx can support that.

@angelozerr
Copy link
Contributor

@blasss have you tested your sample in WWD? Have you some validation error, completion based on XSD?

I have tested quickly with vscode-xml and I have some error validation, and completion based on XSD.

The jar:file protocol seems working.

@blasss
Copy link
Author

blasss commented Feb 22, 2023

Sorry for being a little late to the party.
I tested with WWD and a catalog-file with a jar-file entry.

On a rough first look the support seems to be working.
I want to make sure I didn't miss something and there is some official support for this.

As the aforementioned PR will be based on this functionally, it's crucial this is not simply working by coincidence and will vanish some time in the future as nobody recognizes this to be used in dependent projects....

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants