5.2. Available ValueSource annotations

ValueSource annotations may be used in conjunction:

public class AppConfig {
    @ExternalValue("datasource.username") String username;

    public TestBean testBean() {
        return new TestBean(username);

In this example, datasource.username will be looked for in db.properties, in the set of environment variables present at runtime and in the system properties.

Explicit ordering of ValueSource annotations is not yet supported but will be soon. See SJC-170 and SJC-171 for details.