integrant

Martin 2020-04-11T20:06:29.006200Z

Why does (ig/load-namespaces config) start the services?

kwrooijen 2020-04-12T10:24:29.007700Z

My assumption is that you have a namespace which runs code at the top level (outside of a def or defn). If you look at the code for load-namespaces , then you can see that your expectation is correct. All it does it require namespaces (thus loading multimethods into scope) https://github.com/weavejester/integrant/blob/59b692dc7727d7606fa29ed98c0418ba1beb650d/src/integrant/core.cljc#L190-L209

Martin 2020-04-11T20:06:57.006800Z

My expectation would be that it just loads the multimethod into scope

Martin 2020-04-11T20:07:40.007600Z

i.e. to start the service I’d still have to call (ig/init config)