cache {
ttl = 1024
}
I have an application.conf which belongs on the classpath and contains location specific configuration: cache {
redis_server = "123.456.789.012:6379"
}
In my code, I do this: server = getRedisServer(config.getString("cache.redis_server"))
server.put(key, value, ttl=config.getInt("cache.ttl")
https://github.com/typesafehub/configJava does have fugly enterprisey frameworks. But it's silly to claim that this is some property of Java.
Incidentally, Python also does "code as data as config" also - see django's settings.py, for example.