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

Clarification on plugin startup and class loading #1498

Open
kal-el11 opened this issue Mar 20, 2024 · 2 comments
Open

Clarification on plugin startup and class loading #1498

kal-el11 opened this issue Mar 20, 2024 · 2 comments

Comments

@kal-el11
Copy link

I have written a plugin A which extends lemminx extension point "org.eclipse.wildwebdeveloper.xml.lemminxExtension". I hope xml language server is activated when an xml file is opened in editor.

<jar path="mydummy.jar" />

The language server loads the classes from the jar I have mentioned in the extension point. The language server runs as a separate process.

  1. Is it possible to activate the xml language server before opening a xml file?
  2. Can the plugin A access the classes from the jars mentioned in lemminx extension point?
    Please clarify.
@mickaelistria
Copy link
Contributor

Is it possible to activate the xml language server before opening a xml file?

You will most likely need your plugin to setup an org.eclipse.ui.startup extension that would cause the LS to startup (by calling it from registry).

Can the plugin A access the classes from the jars mentioned in lemminx extension point?

Yes, it can probably work as all jars will be loaded in the same classloader.

@angelozerr
Copy link
Contributor

@kal-el11 why do you want to start the xml lemminx ls when eclipse ide has started ?

Perhaps it is to support workspace symbols because with this feature you dont need to open any file.

IMHO I think lsp4e should provide an extension point to start ls when ide has started.

Lsp4e could loup for each ls server définition and use this extension point to know if ls must be started.

Vscode has this kind of feature which is very Nice. This feature is not linked to lsp support but to the start of the vscode extension

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

No branches or pull requests

3 participants