JaneWardSandy / eclipse-pde-partial-idea

Part of the functions belonging to Eclipse PDE are reimplemented in IDEA
Apache License 2.0
36 stars 6 forks source link

feature(common): BundleManifestIndex #89

Closed JaneWardSandy closed 2 years ago

JaneWardSandy commented 2 years ago

File-Based index for MANIFEST.MF

JaneWardSandy commented 2 years ago

I did a very lax test.

Get the Bundle with BSN=org.eclipse.ui and version 3.201.0.v20220124-1108, and then judge whether this Bundle has a visible org.eclipse.osgi dependency, and get the final return time. The route to get is almost: org.eclipse.ui -> org.eclipse.core.runtime -> org.eclipse.osgi

Inaccurate test results reaction

Through this imprecise test, it can be roughly seen that the impact on performance is not particularly large, but in turn, it is easier to be compatible with dependency management such as Gradle and Maven in the future. I think I can try to imitate XmlIndex first and index keywords such as Bundle-SymbolicName and Require-Bundle separately.

JaneWardSandy commented 2 years ago

It seems that this index does not need to be adjusted too much. It is only necessary to add an index that uses BSN and Version as the key, and obtain the VirtualFile containing them, and then obtain the complete BundleManifest through the current index. If there are more optimization possibilities, it may be a better choice to adjust in the future.