SCM-Manager tries now to figure out which is the best strategy for the restart.
It chooses from one of the following strategies:
* PosixRestartStrategy which uses native LibC
* ExitRestartStrategy uses System.exit and relies on external mechanism to start again
* InjectionContextRestartStrategy destroys and re initializes the injection context
The old algorithm failed, because the tree below lead to the issue, that
the scm-branchwp-plugin was loaded before the scm-review-plugin was
ready.
This commit changes the order in the way, that leafs are loaded last.
+- scm-editor-plugin d
+- scm-branchwp-plugin a
+- scm-mail-plugin c
+- scm-review-plugin b
+- scm-branchwp-plugin a
+- scm-branchwp-plugin a
The posted restart event will trigger legman to request the current
subject so that it can be passed over. This will lead to an exception
if no subject is registered. The subject itself is of no importance
here.
Reported here:
https://groups.google.com/d/msg/scmmanager/m4CfDE2n4h8/Yn6fddaYBgAJ
Plugin authors could now define optional dependencies to other plugins in their pom.
Extensions which are using classes from optional dependencies must specify this
with the "requires" attribute of the extension annotation.
Extensions with "requires" attribute are not installed if one of the specified plugins,
is not installed.
When this is enabled, we get timeouts on some machines (seems to depend
on the number of cores) when the server is stopped which leads to an
error when the integration tests are run (the server cannot be stopped
fast enough when the integration tests are finished in webapp and shall
be started for scm-it).