(defstruct account :id :balance) (def accounts (ref #{}) ) (dosync ; force transaction (alter accounts conj (struct account 1 139.78) ) )