config.edn 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. {:duct.core/project-ns hello
  2. :duct.core/environment :production
  3. :duct.core/include ["hello/db" "hello/server"]
  4. :duct.module/logging
  5. {}
  6. :duct.module.web/api
  7. {}
  8. ; for benchmarking performance, disable logging
  9. :duct.logger/timbre
  10. {:enabled? false
  11. :appenders {}
  12. :level :error}
  13. :duct.module/ataraxy
  14. {[:get "/json"] [:json]
  15. [:get "/plaintext"] [:plaintext]
  16. [:get "/db"] [:single-query]
  17. [:get "/db-mongo"] [:single-query-mongodb]
  18. [:get "/queries" #{?queries}] [:queries]
  19. [:get "/queries-mongo" #{?queries}] [:queries-mongodb]
  20. [:get "/fortunes"] [:fortunes]
  21. [:get "/fortunes-mongo"] [:fortunes-mongodb]}
  22. [:duct.handler.static/ok :hello.handler/json]
  23. {:body {:message "Hello, World!"}}
  24. [:duct.handler.static/okplain :hello.handler/plaintext]
  25. {:body "Hello, World!"}
  26. :hello.handler/single-query
  27. {:db #ig/ref :duct.database/sql}
  28. :hello.handler/single-query-mongodb
  29. {:db #ig/ref :duct.database.mongodb/monger}
  30. :hello.handler/queries
  31. {:db #ig/ref :duct.database/sql}
  32. :hello.handler/queries-mongodb
  33. {:db #ig/ref :duct.database.mongodb/monger}
  34. :hello.handler/fortunes
  35. {:db #ig/ref :duct.database/sql}
  36. :hello.handler/fortunes-mongodb
  37. {:db #ig/ref :duct.database.mongodb/monger}}