Skip to content

Commit

Permalink
Merge branch 'hotfix/2024.1.1' into 'master'
Browse files Browse the repository at this point in the history
OEQ-2254 - merge: branch hotfix/2024.1.1

See merge request edalex-group/development/oeq/openequella!452
  • Loading branch information
PenghaiZhang committed Sep 30, 2024
2 parents 8349472 + 114adb1 commit dc764a6
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -75,11 +75,12 @@ public void destroy() {
* Method to be called when the OEQ is started as a Windows service. According to the Procrun
* documentation, this method should not return until the stop method has been called in JVM mode.
*/
public static void start(String[] args) {
public static void start(String[] args) throws InterruptedException {
System.out.println("Starting EQUELLA Server...");
main(new String[0]);
while (!stopped) {
// DO not return until `stop` is called.
Thread.sleep(1000);
}
}

Expand Down
13 changes: 11 additions & 2 deletions Source/Tools/UpgradeManager/src/com/tle/upgrademanager/Main.java
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,8 @@
*/
public class Main {
private static final Log LOGGER = LogFactory.getLog(Main.class);
// Flag to stop the manager.
private static volatile boolean stop;

public static final String EQUELLA_INSTALL_DIRECTORY_KEY =
"equella.install.directory"; //$NON-NLS-1$
Expand All @@ -65,13 +67,20 @@ public class Main {

private static HttpServer server;

/**
* Method to be called when the Manager is started. According to the Procrun documentation, this
* method should not return until the stop method has been called in JVM mode.
*/
public static void main(String[] args) throws Exception {
if (Check.isEmpty(args) || Check.isEmpty(args[0]) || args[0].equals("start")) // $NON-NLS-1$
{
Main m = new Main();
m.startServer();
} else if (args[0].equals("stop")) // $NON-NLS-1$
{
while (!stop) {
Thread.sleep(1000);
}
} else if (args[0].equals("stop")) {
stop = true;
if (server != null) {
server.stop(4);
}
Expand Down
2 changes: 1 addition & 1 deletion build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ name := "Equella"

(ThisBuild / equellaMajor) := 2024
(ThisBuild / equellaMinor) := 1
(ThisBuild / equellaPatch) := 0
(ThisBuild / equellaPatch) := 1
(ThisBuild / equellaStream) := "Stable"
(ThisBuild / equellaBuild) := buildConfig.value.getString("build.buildname")
(ThisBuild / buildTimestamp) := Instant.now().getEpochSecond
Expand Down
2 changes: 1 addition & 1 deletion checkstyle.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
## Run Checkstyle for all the Java files in the project.
## If the number of errors is either greater or smaller than the threshold, output an error message and exit with status 1.

thresholdNumber=449
thresholdNumber=448

result=$(checkstyle -c checkstyle-config.xml -o checkstyle-report.txt . 2>&1)
echo $result
Expand Down

0 comments on commit dc764a6

Please sign in to comment.