Skip to content
Permalink
Browse files
[GERONIMO-6833] ensure proxies parents are registered
  • Loading branch information
rmannibucau committed May 24, 2022
1 parent 50a67ab commit 048734886ba579c1ab3a9cdbf41e87fae192b783
Showing 1 changed file with 19 additions and 8 deletions.
@@ -130,14 +130,25 @@ public void execute(final Context context) {

// 2. register all classes which will require reflection + proxies
final String beanClassesList = registerBeansForReflection(context, beans, classFilter, interceptors);
getProxies(webBeansContext).keySet().stream().filter(classFilter).sorted().forEach(name -> {
final ClassReflectionModel model = new ClassReflectionModel();
model.setName(name);
model.setAllDeclaredConstructors(true);
model.setAllDeclaredFields(true);
model.setAllDeclaredMethods(true);
context.register(model);
});
getProxies(webBeansContext).keySet().stream()
.filter(classFilter)
.flatMap(it -> {
try {
return hierarchy(context.loadClass(it))
.map(Class::getName);
} catch (final RuntimeException re) {
return Stream.of(it);
}
})
.sorted()
.forEach(name -> {
final ClassReflectionModel model = new ClassReflectionModel();
model.setName(name);
model.setAllDeclaredConstructors(true);
model.setAllDeclaredFields(true);
model.setAllDeclaredMethods(true);
context.register(model);
});

// 3. dump owb properties for runtime
final Properties properties = initProperties(context, webBeansContext.getOpenWebBeansConfiguration(), beanClassesList);

0 comments on commit 0487348

Please sign in to comment.