I would like to store multiple configuration entries (which can be flexibly extended) in a data structure, something like this:
(def config [{:host "test", :port 1},{:host "testtest", :port 2}])
Later on I would like to iterate over and process each hash in that array.
Could somebody point out how to do that in Clojure?
You could use
for(ordoseqif you only want side-effects) to loop over each map stored in the vector. You can even use destructuring to bind the individual keys of the map if you know them in advance: