     ;; Note that when upgrading umm version we should also cache the previous version of UMM.
     {:format :umm-json
      :version umm-version/current-version}})
+
+(defn cached-formats
+  "This is a set of formats that are cached."
+  []
+  (set/difference all-formats (non-cached-collection-metadata-formats)))
 
 ;; Defines the record that represents the cache and implements the cache protocol. This is a very
 ;; simple implementation that just wraps an atom with the map of cached concept ids to revision

        concepts (doall (metadata-db/get-concepts mdb-context concept-tuples true))
        concepts (concepts-without-xml-processing-inst concepts)
        rfms (u/fast-map #(rfm/compress
                           (rfm/concept->revision-format-map context % cached-formats))
                         concepts)]
    (reduce #(assoc %1 (:concept-id %2) %2) {} rfms)))


  "Identifies the key used when the cache is stored in the system."
  :metadata-cache)

(defconfig non-cached-collection-metadata-formats
  "Defines a set of collection metadata formats that will not be cached in memory"
  {:default #{}
   :type :edn})

(def all-formats
  "All the possible collection metadata formats that could be cached."
  #{:echo10
    :iso19115
    :dif
