Hi Eirik,
The lack of `Boolean.getBoolean(String propName, boolean default)`
encourages
developers to roll their own. If it were easier get the desired default
from the built-in
boolean property API it would fit more use cases.
It might be a small step to take advantage of your analysis and b
On Wed, Dec 4, 2024 at 3:47 PM Eirik Bjørsnøs wrote:
> The OpenJDK includes many boolean flags in the form of system properties.
> These toggle different behavior such as debug logging, verification,
> caching, compatibility and conditional features.
>
To learn more about how the JDK uses boole
>
> There are at least three issues at play here:
>
> a: Some flags use inconsistent, confusing, controversial or
> less-than-perfect interpretations
> b: Some flags use identical interpretations, yet their evaluation happens
> in copy-pasted code spread across the code base
> c: Some flags use ide
>
> Practically, if we wanted to change such long standing behaviors
> in order to align on a new consistent handling for all the boolean
> properties.
>
There are at least three issues at play here:
a: Some flags use inconsistent, confusing, controversial or
less-than-perfect interpretations
b:
Hi Eirik,
Yes, the situation we're in is far from perfect. I've never been a big
fan of considering that an empty value means "true": if you're going
to pass a System property, you can go the extra mile and supply
its value too, which should make the intent uncontroversial. Note that
not passing
Hi Eirik,
Yes, its a long standing and inconsistent area of deferred maintenance.
Most of the individual cases are not used enough to warrant making the
(in many cases) incompatible change and breaking some
application/library somewhere.
Interesting, you did not mention Boolean.getBoolean(Str
Hi,
The OpenJDK includes many boolean flags in the form of system properties.
These toggle different behavior such as debug logging, verification,
caching, compatibility and conditional features.
A common interpretation is to evaluate a property as true if it is set and
either blank or equal to "