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

Plugin dependency graph #22

Open
janhoy opened this issue Apr 19, 2017 · 5 comments
Open

Plugin dependency graph #22

janhoy opened this issue Apr 19, 2017 · 5 comments

Comments

@janhoy
Copy link
Member

janhoy commented Apr 19, 2017

Spinoff from pf4j/pf4j#51

There is currently no provision for building a dependency graph before starting an install/download with pf4j-update.

If a dependency stated in plugins.json is neither installed (PluginManager) or available in any of the UpdateRepositories, then the install process should simply fail before starting to download the requested plugin.

Perhaps the framework could provide an API to resolve dependencies from PluginInfo into a graph by consulting both PluginManager and UpdateManager. If a remote plugin depends on some plugin which is not downloaded, the API could look for the dependency id in all repositories, and if it is found, look for further dependencies etc until graph is complete. The API would make it easy for UIs to check whether a given plugin is installable or updateable before actually starting the install.

@decebals
Copy link
Member

Make sense. Maybe class DirectedGraph from PF4J helps.

@decebals
Copy link
Member

I can take a look at this, in my spare time.

@decebals
Copy link
Member

We can use DependencyResolver that was improved by pf4j/pf4j#150. Just create a list with plugins descriptors and call method resolve. The result (Result) contains a lot of information related to dependencies (cyclic dependencies, not found dependencies, dependencies with wrong versions).

@PatrickHaas
Copy link

Anything new? I just got the exact problem trying to resolve a graph dependant plugins by looking at a PluginInfo

@decebals
Copy link
Member

decebals commented Jun 3, 2021

Anything new? I just got the exact problem trying to resolve a graph dependant plugins by looking at a PluginInfo

We can try a PR based on #22 (comment). Unfortunate for me it's not a top priority. Maybe someone can start the PR to have a base for concrete comments.

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