Closed junkdog closed 5 years ago
Noticed phases aren't emitted, I'll take a look.
public class LifecycleListenerManager extends BaseSystem implements ArtemisPhaseListener {
private LifecycleListenerMultiplexer listeners = new LifecycleListenerMultiplexer();
@Override
public void onPhase(World w, Phase phase) {
if (phase == Phase.PRE_INITIALIZE) {
// world on system isn't available at this point in the lifecycle.
registerEntityLifecycleListeners(w.getSystems());
}
}
Hmm, were was PhaSe.PRE_INITIALIZE
sent? I can't find it in either https://github.com/junkdog/artemis-odb/pull/575 or on develop.
tests
DebugPlugin tests run with graftt agent; maven downloads it and puts the agent under
target/
- tests will only work from within the idea ifmvn test
(or later) has run once, as intellij doesn't care much about maven plugins and their behavior - but it does pick up the agent args from maven.running as a user
As a user, the crux here is that the JVM must start with
-javaagent:<graft-agent.jar>
. Maybe we should provide a script or something to automatically download the most recent agent?In the tests, it's solved by relying on maven plugins. I guess something similar could be done for gradle.
other stuff
new module for the transplants:
contrib-plugin-lifecycle-transplants
. pretty similar-looking to the previous ones. some things are done slightly differently, but I don't think I've changed any behavior.