Skip to content

Commit df5a639

Browse files
authored
add json annotation for IDC (#354)
1 parent f30c249 commit df5a639

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

src/main/java/com/alipay/oceanbase/rpc/location/model/OcpResponseData.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@ public void setRsList(List<OcpResponseDataRs> rsList) {
7575
/*
7676
* Get IDC list.
7777
*/
78+
@JsonProperty("IDCList")
7879
public List<OcpResponseDataIDC> getIDCList() {
7980
return IDCList;
8081
}

src/main/java/com/alipay/oceanbase/rpc/location/model/OcpResponseDataIDC.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,16 @@
2222
*
2323
*/
2424

25+
import com.fasterxml.jackson.annotation.JsonProperty;
26+
2527
public class OcpResponseDataIDC {
2628
private String idc;
2729
private String region;
2830

2931
/*
3032
* Get idc.
3133
*/
34+
@JsonProperty("idc")
3235
public String getIdc() {
3336
return idc;
3437
}
@@ -43,6 +46,7 @@ public void setIdc(String idc) {
4346
/*
4447
* Get region.
4548
*/
49+
@JsonProperty("region")
4650
public String getRegion() {
4751
return region;
4852
}

0 commit comments

Comments
 (0)