#tesla-httpkit
This library provides a component, that adds an embedded httpkit server to tesla-microservice.
The config :server-port
will be used as port. Default is 8080
.
The config :server-binding
will be used as binding. Default is "0.0.0.0"
.
For a full list, see server-config
in "serving-with-httpkit.clj"
When the server starts up, some metrics (gauges) are initialized using metrics-clojure-jvm
.
If you don't want these metrics, just set :httpkit-metrics?
to false
.
Metrics-overview:
Because tesla-microservice is a provided dependency, you must always specify two dependencies in your project clj:
:dependencies [[de.otto/tesla-microservice "0.1.32"]
[de.otto/tesla-httpkit "0.2.0"]]
Add the server to the base-system before starting it. Pass in additional dependencies of the server (e.g. :my-page
):
(system/start (serving-with-httpkit/add-server (system/base-system {}) :my-page))
Versions 0.1.0
and above of tesla-httpkit are compatible with versions 0.1.15
and above of tesla-microservice.
Apache License
Can you improve this documentation?Edit on GitHub
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close