Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Always check XML Set elements with property attribute #6375

Closed
gregw opened this issue Jun 9, 2021 · 1 comment · Fixed by #6398
Closed

Always check XML Set elements with property attribute #6375

gregw opened this issue Jun 9, 2021 · 1 comment · Fixed by #6398

Comments

@gregw
Copy link
Contributor

gregw commented Jun 9, 2021

Target Jetty version(s)

= 10.0.x

Enhancement Description

Since jetty-10, the XML Set element could have a property attribute that only does the set if the property is set. The problem with this is that the code may change and we do not detect that the XML is now wrong unless somebody attempts to set that property. The XmlConfiguration class should be change to always check that at least one setter exists for a Set element with a property attribute.

@janbartel
Copy link
Contributor

@gregw also, the documentation needs updating for the Set element, because it doesn't mention the property attribute at all. See https://www.eclipse.org/jetty/documentation/jetty-10/operations-guide/index.html#og-xml-syntax-set

gregw added a commit that referenced this issue Jun 11, 2021
Fix #6375 by making XmlConfiguration Set handling always check for a matching setter, even if the property attribute is given but not set.

Signed-off-by: Greg Wilkins <gregw@webtide.com>
@gregw gregw added this to To do in Jetty 10.0.6/11.0.6 FROZEN via automation Jun 11, 2021
gregw added a commit that referenced this issue Jun 14, 2021
Also check for public fields

Signed-off-by: Greg Wilkins <gregw@webtide.com>
Jetty 10.0.6/11.0.6 FROZEN automation moved this from To do to Done Jun 15, 2021
gregw added a commit that referenced this issue Jun 15, 2021
* Fixed #6375 XmlConfiguration to always checks  for a matching setter, even if the property attribute is given but not set.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Development

Successfully merging a pull request may close this issue.

2 participants