I am building a utility that is designed to act as a streaming json aggregator. Basically analyzing the data structure and building general watch events for conditions and aggregating interesting totals quickly, max, min, sum, count, empty count.
Anyway the general pattern I am using is an atom map that keys on fields and stores a map of the values, then a lot of functions that are a doseq that then calls several swap update-in or assoc-in to the atom.
My question is this a practical or idiomatic structure. In short is there a way that can do it more lazily and with less usage of atoms to store a state. Performance wise can single threaded handle 5000 records a second. Which is just fine but as I am getting deeper in clojure and perhaps creating examples for others on my team, am I really doing things the right clojure way for this. Not that there is a right, I am just trying to make sure I am thinking in the most sensible way as I approach problem domains and not let my background in more imperative languages taint my design choices.