This is an automated email from the ASF dual-hosted git repository. remm pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/tomcat.git
The following commit(s) were added to refs/heads/main by this push: new 7be7b01b8d Fix missing attributes 7be7b01b8d is described below commit 7be7b01b8dec50c36852cb0d5e519fbe786212bb Author: remm <r...@apache.org> AuthorDate: Thu Sep 22 22:56:19 2022 +0200 Fix missing attributes The code is very confusing, but the main attribute map can contain either the get or set method as the value, so it must not be used. This should probably be refactored some more ... --- .../util/modeler/modules/MbeansDescriptorsIntrospectionSource.java | 2 +- webapps/docs/changelog.xml | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/java/org/apache/tomcat/util/modeler/modules/MbeansDescriptorsIntrospectionSource.java b/java/org/apache/tomcat/util/modeler/modules/MbeansDescriptorsIntrospectionSource.java index 05f393d023..ffb0937066 100644 --- a/java/org/apache/tomcat/util/modeler/modules/MbeansDescriptorsIntrospectionSource.java +++ b/java/org/apache/tomcat/util/modeler/modules/MbeansDescriptorsIntrospectionSource.java @@ -311,7 +311,7 @@ public class MbeansDescriptorsIntrospectionSource extends ModelerSource String name = attEntry.getKey(); AttributeInfo ai = new AttributeInfo(); ai.setName(name); - Method gm = attEntry.getValue(); + Method gm = getAttMap.get(name); if (gm != null) { ai.setGetMethod(gm.getName()); Class<?> t = gm.getReturnType(); diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml index 7205c26e86..dcdd316f1d 100644 --- a/webapps/docs/changelog.xml +++ b/webapps/docs/changelog.xml @@ -110,6 +110,10 @@ <update> Update Panama OpenSSL code for the extensive Java 20 changes. (remm) </update> + <fix> + Fix a regression in refactoring for Hashtables which caused mbeans to + lose many of their attributes. (remm) + </fix> </changelog> </subsection> <subsection name="Jasper"> --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org