Skip to content

Commit 7ebb32d

Browse files
authored
Guard bootstrap plugins loading from detecting plugins cache (#109116)
This commit guards iteration over plugin infos from mistakenly trying to inspect the plugins cache file as a plugin. closes #97702
1 parent e4ef0ff commit 7ebb32d

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

distribution/tools/launchers/src/main/java/org/elasticsearch/tools/launchers/BootstrapJvmOptions.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,10 @@ private static List<PluginInfo> getPluginInfo(Path plugins) throws IOException {
4545
for (Path pluginDir : pluginDirs) {
4646
final List<String> jarFiles = new ArrayList<>();
4747
final Properties props = new Properties();
48+
if (pluginDir.getFileName().toString().equals(".elasticsearch-plugins.yml.cache") == false) {
49+
// skip plugins cache, see SyncPluginsAction
50+
continue;
51+
}
4852

4953
final List<Path> pluginFiles = Files.list(pluginDir).collect(Collectors.toList());
5054
for (Path pluginFile : pluginFiles) {

docs/changelog/109116.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
pr: 109116
2+
summary: Guard bootstrap plugins loading from detecting plugins cache
3+
area: Infra/Plugins
4+
type: bug
5+
issues:
6+
- 97702

0 commit comments

Comments
 (0)