@Sources("classpath:app.yaml")
public interface AppConfig extends Config {
ServerConfig server();
}
server:
host: localhost
port: 8080
They flatten to the same keys nesting reads, so a format is a way of writing the file and nothing more.
a documented subset, refused by name
The YAML parser is ~450 lines rather than 5000: anchors, aliases, merge keys, tags and a second document are refused, naming the line, instead of half-supported.
The Norway problem never arises — the literal scalar is kept and the interface declares the type.
A repeated key is a list, because that is already what a repeated XML element is here.