class NodeFlavors {

    public Optional<Flavor> getFlavor(String name) {
        if (configuredFlavors.containsKey(name))
            return Optional.of(configuredFlavors.get(name));

        NodeResources nodeResources = NodeResources.fromLegacyName(name);
        return Optional.of(new Flavor(nodeResources));
    }

    @Inject public  NodeFlavors(FlavorsConfig config);

}