Closed JaneWardSandy closed 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
PT0.001107256S
index
, by getting BSN
and version
, then get the visible dependencies, and then get the index again from the visible dependencies, until the required BSN
is found, the average time is PT0.002686706S
index
of SingleEntryFileBasedIndexExtension
, it is not easy to get it directly through BSN
, so it is not testedThrough 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.
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.
File-Based index for
MANIFEST.MF