Repository navigation
Ageris 0.7.0 makes files stricter where a mistake went unnoticed, and smooths a few edges.
Get it
<dependency>
<groupId>io.github.lichtsinn</groupId>
<artifactId>ageris-core</artifactId>
<version>0.7.0</version>
</dependency>implementation 'io.github.lichtsinn:ageris-core:0.7.0'Requires Java 17 or later. The Helidon module requires Java 27.
Changed
- A name or a key that appears twice is refused. An entry's name in its section, a context's name in
contexts, and each key in an entry and inmodifiers. Until now only a rule was checked, and elsewhere the last one counted without a word. A file that holds a section twice is refused as a whole. What an entry'svalueholds belongs to the application and is not checked. - A
commentis allowed inmodifiers, as it already was in an entry, a named context and a rule. - A record that asks for a binding gets a message that fits. It is told to become a class; the old message advised removing an annotation a record does not have.
ConfigurationLoader.awaitFirstAttemptwaits until every manager has loaded or has failed once, whereawaitFirstLoadwaits for success only. The Spring Boot starter and the Helidon module already behaved this way and now use it.- The OpenFeature provider gives up at once when its first attempt to load fails. It used to wait out its whole timeout before reporting the reason.
- A file name without a leading slash works with the file system fetcher:
featureflags.jsonis read like/featureflags.json. It used to be glued to the name of the application and end in "no such file". - A
first-load-timeoutthat cannot be right is refused by the Spring Boot starter and the Helidon module, with a message that names it: a negative one always, and zero whilefail-on-first-load-failureis true. Zero together withfail-on-first-load-failure=falsemeans not to wait.
Also new
- Example applications for Helidon SE and Spring Boot, in
examples. Both show a feature flag with targeting, a config, and a change to a file while the application runs. - The README says in which order a file and the code that reads it are released, under Releasing a change: for adding and removing a feature flag, a config and a policy.
- A logo, in
logo.
Upgrading from 0.6.0
- Check your files for a name or a key that appears twice. Such an entry loaded before, with the last one counting, and is refused now. As with any entry that cannot be loaded, the application keeps what it had until the file is fixed.
- If
first-load-timeoutis zero or negative, set it to a time longer than zero, or setfail-on-first-load-failureto false if the start should not wait. - A
commentinmodifiersneeds 0.7.0 in every application that reads the file. An older version cannot load an entry that has one.
Dependencies
Unchanged from 0.6.0: Jackson 2.22, slf4j 2.0 and commons-io 2.22. ageris-core is also tested with Jackson 2.15.4, slf4j 1.7.36 and commons-io 2.11.0; ageris-openfeature with the OpenFeature SDK from 1.16.0 to 1.23.0; ageris-spring-boot-starter with Spring Boot 4.0.0 to 4.1.1; and ageris-helidon with Helidon 27.0.0.