-
Notifications
You must be signed in to change notification settings - Fork 68
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Replace status page API calls with SecHub Java API calls #2513 and im…
…plement #469 - return JSON instead of text for the server version #469 - adjust the REST Doc tests für #469 - replace the status page API calls with SecHub Java API calls #2513 - improve return value of server status API call #2513 closes: #2513 closes: #469
- Loading branch information
Showing
14 changed files
with
217 additions
and
120 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
17 changes: 3 additions & 14 deletions
17
sechub-api-java/src/main/java/com/mercedesbenz/sechub/api/SecHubStatus.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,10 @@ | ||
// SPDX-License-Identifier: MIT | ||
package com.mercedesbenz.sechub.api; | ||
|
||
import java.util.Collections; | ||
import java.util.Map; | ||
import java.util.TreeMap; | ||
public record SecHubStatus(Scheduler scheduler, Jobs jobs) { | ||
|
||
public class SecHubStatus { | ||
|
||
Map<String, String> statusInformation = new TreeMap<>(); | ||
|
||
public Map<String, String> getStatusInformationMap() { | ||
return Collections.unmodifiableMap(statusInformation); | ||
public record Scheduler(boolean isEnabled) { | ||
} | ||
|
||
@Override | ||
public String toString() { | ||
return "SecHubStatus [" + (statusInformation != null ? "statusInformation=" + statusInformation : "") + "]"; | ||
public record Jobs(long all, long cancelRequested, long canceled, long ended, long initializating, long readyToStart, long started) { | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.