-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #4972 from bigscoop/coinex-fixes
[coinex] Add exchange health
- Loading branch information
Showing
8 changed files
with
121 additions
and
2 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
20 changes: 20 additions & 0 deletions
20
xchange-coinex/src/main/java/org/knowm/xchange/coinex/config/Config.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 |
---|---|---|
@@ -0,0 +1,20 @@ | ||
package org.knowm.xchange.coinex.config; | ||
|
||
import java.time.Clock; | ||
import lombok.Data; | ||
|
||
@Data | ||
public final class Config { | ||
|
||
private Clock clock; | ||
|
||
private static Config instance = new Config(); | ||
|
||
private Config() { | ||
clock = Clock.systemDefaultZone(); | ||
} | ||
|
||
public static Config getInstance() { | ||
return instance; | ||
} | ||
} |
37 changes: 37 additions & 0 deletions
37
xchange-coinex/src/main/java/org/knowm/xchange/coinex/dto/marketdata/CoinexMaintainInfo.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 |
---|---|---|
@@ -0,0 +1,37 @@ | ||
package org.knowm.xchange.coinex.dto.marketdata; | ||
|
||
import com.fasterxml.jackson.annotation.JsonProperty; | ||
import java.net.URI; | ||
import java.time.Instant; | ||
import java.util.List; | ||
import lombok.Builder; | ||
import lombok.Data; | ||
import lombok.extern.jackson.Jacksonized; | ||
|
||
@Data | ||
@Builder | ||
@Jacksonized | ||
public class CoinexMaintainInfo { | ||
|
||
@JsonProperty("started_at") | ||
private Instant startTime; | ||
|
||
@JsonProperty("ended_at") | ||
private Instant endTime; | ||
|
||
@JsonProperty("scope") | ||
private List<String> scope; | ||
|
||
@JsonProperty("announce_enabled") | ||
private Boolean announceEnabled; | ||
|
||
@JsonProperty("announce_url") | ||
private URI announceUrl; | ||
|
||
@JsonProperty("protect_duration_start") | ||
private Instant protectStart; | ||
|
||
@JsonProperty("protect_duration_end") | ||
private Instant protectEnd; | ||
|
||
} |
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
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
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 |
---|---|---|
@@ -0,0 +1,4 @@ | ||
### Get Maintenance Information | ||
GET {{api_host}}/v2/maintain/info | ||
|
||
|