From 325a99ff79cbaf1c2d2496f5df2832b2f412f347 Mon Sep 17 00:00:00 2001 From: Martin Kouba Date: Fri, 23 Apr 2021 08:05:44 +0200 Subject: [PATCH] Bootstrap - include reloadable artifacts to deployment classloader - resolves #16681 - also remove these artifacts from augment classloader --- .../java/io/quarkus/bootstrap/app/CuratedApplication.java | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/independent-projects/bootstrap/core/src/main/java/io/quarkus/bootstrap/app/CuratedApplication.java b/independent-projects/bootstrap/core/src/main/java/io/quarkus/bootstrap/app/CuratedApplication.java index cafcef4297a14..e069d09f147dd 100644 --- a/independent-projects/bootstrap/core/src/main/java/io/quarkus/bootstrap/app/CuratedApplication.java +++ b/independent-projects/bootstrap/core/src/main/java/io/quarkus/bootstrap/app/CuratedApplication.java @@ -178,6 +178,9 @@ public synchronized QuarkusClassLoader getAugmentClassLoader() { //any of the runtime artifacts, or user classes //this will load any deployment artifacts from the parent CL if they are present for (AppDependency i : appModel.getFullDeploymentDeps()) { + if (configuredClassLoading.reloadableArtifacts.contains(i.getArtifact().getKey())) { + continue; + } processCpElement(i.getArtifact(), element -> addCpElement(builder, i.getArtifact(), element)); } @@ -271,6 +274,11 @@ public QuarkusClassLoader createDeploymentClassLoader() { builder.addElement(ClassPathElement.fromPath(root)); } } + for (AppDependency dependency : appModel.getUserDependencies()) { + if (configuredClassLoading.reloadableArtifacts.contains(dependency.getArtifact().getKey())) { + processCpElement(dependency.getArtifact(), element -> addCpElement(builder, dependency.getArtifact(), element)); + } + } return builder.build(); }