mirror of
https://github.com/penpot/penpot.git
synced 2025-01-24 23:49:45 -05:00
💄 Minor cosmetic changes.
This commit is contained in:
parent
5a03c13731
commit
4b31a147a9
3 changed files with 12 additions and 12 deletions
|
@ -152,7 +152,9 @@
|
|||
|
||||
(defn disconnect!
|
||||
[conn]
|
||||
(.. conn (getSession) (disconnect)))
|
||||
(let [session (.getSession conn)]
|
||||
(when session
|
||||
(.disconnect session))))
|
||||
|
||||
(defn- on-subscribed
|
||||
[{:keys [conn] :as ws}]
|
||||
|
|
|
@ -23,14 +23,6 @@
|
|||
[uxbox.tasks.impl :as impl]
|
||||
[uxbox.util.time :as dt]))
|
||||
|
||||
;; --- Public API
|
||||
|
||||
(defn schedule!
|
||||
([opts] (schedule! db/pool opts))
|
||||
([conn opts]
|
||||
(s/assert ::impl/task-options opts)
|
||||
(impl/schedule! conn opts)))
|
||||
|
||||
;; --- State initialization
|
||||
|
||||
;; TODO: missing self maintanance task; when the queue table is full
|
||||
|
@ -48,6 +40,14 @@
|
|||
:start (impl/start-worker! {:tasks tasks})
|
||||
:stop (impl/stop! worker))
|
||||
|
||||
;; --- Public API
|
||||
|
||||
(defn schedule!
|
||||
([opts] (schedule! db/pool opts))
|
||||
([conn opts]
|
||||
(s/assert ::impl/task-options opts)
|
||||
(impl/schedule! conn opts)))
|
||||
|
||||
;; (defstate scheduler
|
||||
;; :start (impl/start-scheduler! tasks)
|
||||
;; :stop (impl/stop! tasks-worker))
|
||||
|
|
|
@ -153,9 +153,7 @@
|
|||
(defn start-worker!
|
||||
[options]
|
||||
(let [stop (a/chan)]
|
||||
(a/go
|
||||
(a/<! (start-worker-eventloop! (assoc options ::stop stop)))
|
||||
(log/info "STOPING"))
|
||||
(start-worker-eventloop! (assoc options ::stop stop))
|
||||
(->Worker stop)))
|
||||
|
||||
(defn stop!
|
||||
|
|
Loading…
Add table
Reference in a new issue