Advertisement
Guest User

publication problem

a guest
Oct 26th, 2015
135
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.  
  2. ;; in publication.clj
  3. (defrecord PublicationComponent []
  4.   component/Lifecycle
  5.   (start [component]
  6.     (assoc component :publication publication))
  7.   (stop [component]
  8.     (unsub-all publication)
  9.     (dissoc component :publication)))
  10.  
  11. (defn publication-component []
  12.   (->PublicationComponent))
  13.  
  14. ;; in system.clj
  15. (defn new-system [config]
  16.  
  17.   (let [config (meta-merge base-config config)]
  18.     (-> (component/system-map
  19.          :publication   (publication-component))
  20.         (component/system-using
  21.          {:publication   []}))))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement