8000 [JENKINS-38935] Should add aliases on base plugin methods as 'start' · srbala/github-plugin@b916940 · GitHub
[go: up one dir, main page]

Skip to content

Commit b916940

Browse files
committed
[JENKINS-38935] Should add aliases on base plugin methods as 'start'
1 parent e967f0a commit b916940

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

src/main/java/org/jenkinsci/plugins/github/GitHubPlugin.java

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,6 @@ public class GitHubPlugin extends Plugin {
2323
/**
2424
* Launched before plugin starts
2525
* Adds alias for {@link GitHubPlugin} to simplify resulting xml.
26-
* Expected milestone: @Initializer(before = PLUGINS_STARTED)
27-
* * @see #initializers()
2826
*/
2927
public static void addXStreamAliases() {
3028
Migrator.enableCompatibilityAliases();
@@ -35,19 +33,23 @@ public static void addXStreamAliases() {
3533
* Launches migration after plugin already initialized.
3634
* Expected milestone: @Initializer(after = PLUGINS_PREPARED)
3735
*
38-
* @see #initializers()
36+
* @see #migrator()
3937
*/
4038
public static void runMigrator() throws Exception {
4139
new Migrator().migrate();
4240
}
4341

42+
@Override
43+
public void start() throws Exception {
44+
addXStreamAliases();
45+
}
46+
4447
/**
4548
* We need ensure that migrator will run after xstream aliases will be added.
4649
* Unclear how reactor will sort single methods, so bundle in one step.
4750
*/
4851
@Initializer(after = PLUGINS_PREPARED, before = PLUGINS_STARTED)
49-
public static void initializers() throws Exception {
50-
addXStreamAliases();
52+
public static void migrator() throws Exception {
5153
runMigrator();
5254
}
5355

0 commit comments

Comments
 (0)
0