better OWB integration + doc about jib mojo to ensure it is linked to the way the native binary is built
diff --git a/arthur-maven-plugin/src/main/java/org/apache/geronimo/arthur/maven/mojo/JibMojo.java b/arthur-maven-plugin/src/main/java/org/apache/geronimo/arthur/maven/mojo/JibMojo.java
index b91741a..4f48286 100644
--- a/arthur-maven-plugin/src/main/java/org/apache/geronimo/arthur/maven/mojo/JibMojo.java
+++ b/arthur-maven-plugin/src/main/java/org/apache/geronimo/arthur/maven/mojo/JibMojo.java
@@ -63,6 +63,7 @@
public abstract class JibMojo extends ArthurMojo {
/**
* Base image to use. Scratch will ensure it starts from an empty image.
+ * For a partially linked use busybox:glibc.
*/
@Parameter(property = "arthur.from", defaultValue = "scratch")
private String from;
diff --git a/documentation/src/content/maven.adoc b/documentation/src/content/maven.adoc
index 0e38eed..2f0c793 100644
--- a/documentation/src/content/maven.adoc
+++ b/documentation/src/content/maven.adoc
@@ -264,6 +264,9 @@
TIP: this goal does *not* need a docker daemon on the machine, it just uses HTTP(S) communication with a registry.
+IMPORTANT: if you use `static` build you can use `scratch` as base image (empty) but if you use `-H:+StaticExecutableWithDynamicLibC` which statically link everything but glic you should switch to `busybox:glic` for example.
+Also note that some applications will require more libraries like libdl so ensure to adjust your base image on your usage.
+
==== Configuration
include::{generated_dir}/generated_image_mojo.adoc[]
diff --git a/knights/openwebbeans-knight/src/main/java/org/apache/geronimo/arthur/knight/openwebbeans/OpenWebBeansExtension.java b/knights/openwebbeans-knight/src/main/java/org/apache/geronimo/arthur/knight/openwebbeans/OpenWebBeansExtension.java
index 297c1e8..fc2b09f 100644
--- a/knights/openwebbeans-knight/src/main/java/org/apache/geronimo/arthur/knight/openwebbeans/OpenWebBeansExtension.java
+++ b/knights/openwebbeans-knight/src/main/java/org/apache/geronimo/arthur/knight/openwebbeans/OpenWebBeansExtension.java
@@ -123,7 +123,7 @@
// 2. register all classes which will require reflection + proxies
final String beanClassesList = registerBeansForReflection(context, beans, classFilter);
- getProxies(webBeansContext).keySet().stream().sorted().forEach(name -> {
+ getProxies(webBeansContext).keySet().stream().filter(classFilter).sorted().forEach(name -> {
final ClassReflectionModel model = new ClassReflectionModel();
model.setName(name);
model.setAllDeclaredConstructors(true);
diff --git a/knights/openwebbeans-knight/src/main/java/org/apache/geronimo/arthur/knight/openwebbeans/replacement/OWBInitializer.java b/knights/openwebbeans-knight/src/main/java/org/apache/geronimo/arthur/knight/openwebbeans/replacement/OWBInitializer.java
index 84f302f..616056c 100644
--- a/knights/openwebbeans-knight/src/main/java/org/apache/geronimo/arthur/knight/openwebbeans/replacement/OWBInitializer.java
+++ b/knights/openwebbeans-knight/src/main/java/org/apache/geronimo/arthur/knight/openwebbeans/replacement/OWBInitializer.java
@@ -18,15 +18,13 @@
import com.oracle.svm.core.annotate.Substitute;
import com.oracle.svm.core.annotate.TargetClass;
+import org.apache.openwebbeans.se.CDISeScannerService;
import org.apache.openwebbeans.se.PreScannedCDISeScannerService;
-import org.apache.webbeans.spi.ScannerService;
-
-import java.util.Map;
@TargetClass(org.apache.openwebbeans.se.OWBInitializer.class)
public final class OWBInitializer {
@Substitute
- protected void addCustomServices(final Map<String, Object> services) {
- services.put(ScannerService.class.getName(), new PreScannedCDISeScannerService());
+ protected CDISeScannerService createDefaultScannerService() {
+ return new PreScannedCDISeScannerService();
}
}