Fork me on GitHub
#immutant
<
2015-08-31
>
tcrawley12:08:26

do you explicitly have org.immutant/wildfly in your dependencies? that should only be loaded when you are in-container, and is added to the war automatically by lein immutant war. It expects classes from the container to be available, so will throw if loaded outside the container

tcrawley12:08:49

in-cluster? tries to load immutant.wildfly if it is available so it can call immutant.wildfly/in-cluster?, but will return false if that ns isn't available

rauh12:08:11

Yes I do. I'll remove it then.

tcrawley12:08:12

Maybe we should wrap the ns in a guard that prevents it from even trying to load outside of the container

tcrawley12:08:16

I'll see what that would take

rauh12:08:47

How do I use the namespace immutant.wildfly then?

rauh12:08:54

I can't require it if I remove the dep

rauh12:08:49

Would I manually have to (when (util/in-cluster?) (require 'immutant.wildfly))?

tcrawley12:08:57

are you using functions from immutant.wildfly?

rauh12:08:30

Not right now, I'm just evaluating and playing around

rauh12:08:06

I have no expierence with Wildfly/jBoss

rauh12:08:30

I just wonder how I'd start multiple deployments and how I can have them configured differently (same app).

tcrawley12:08:42

you shouldn't ever need to call fns from immutant.wildfly directly - the useful ones have versions in immutant.util that wrap them with checks to make sure the ns is available, so you can pretty much safely ignore immutant.wildfly

tcrawley12:08:08

it might be tricky to have the exact same war file deployed multiple times with different configs, since there would be no good way for each deployment to know who it is

tcrawley12:08:57

actually, you may be able to have the deployment figure out the context path it is on (those have to be unique), and it could use that information to load a config file off a known location on disk

tcrawley12:08:22

let me see if we expose that

rauh12:08:25

Yeah that's what I'm starting to realize. I started up Wildfly management console and there is no way to set any parameters of any kind for a deployment. I though i could set a few config files on the web interface and say "this one is development" and "this one is production" and they listen on different ports