This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defmethod ig/init-key :http/graphql [_ {:keys [schema]}] | |
(do | |
(log/info "initializing schema") | |
(graphql/init-schema schema))) | |
(defmethod ig/init-key :http/server [_ {:keys [handler port]}] | |
(let [server (http/run-server handler {:port port})] | |
(log/info "Starting HTTP server on port" port) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns logger) | |
(defmacro log [& msgs] | |
(let [m (meta &form) | |
_ns (ns-name *ns*) ;; can also be used for logging | |
file *file*] | |
`(binding [*out* *err*] ;; or bind to (io/writer log-file) | |
(println (str ~file ":" | |
~(:line m) ":" | |
~(:column m)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns app.application | |
(:require | |
[com.fulcrologic.fulcro.application :as app] | |
[edn-query-language.core :as eql] | |
[com.fulcrologic.fulcro.algorithms.tx-processing :as txn] | |
[promesa.core :as p] | |
[com.wsscode.pathom3.interface.eql :as p.eql] | |
[com.wsscode.pathom3.connect.operation :as pco] | |
[com.wsscode.pathom3.connect.indexes :as pci])) |