Browse Source

add api配置类信息

GITZYY 7 tháng trước cách đây
mục cha
commit
4453bbd715

+ 19 - 0
egress-gateway-service-client/src/main/java/com/hrsk/cloud/eg/vo/response/DataVo.java

@@ -0,0 +1,19 @@
+package com.hrsk.cloud.eg.vo.response;
+
+import java.io.Serializable;
+
+/**
+ * @author zhangyy
+ * @version 1.0
+ * @description: DataVo
+ * @date 2024/8/28 11:49
+ */
+public class DataVo implements Serializable {
+
+    /**
+     * 状态 1 成功 0 失败 参考true 和false
+     * */
+    private Integer status;
+
+    private String msg;
+}

+ 1 - 1
egress-gateway-service-infrastructure/src/main/java/com/hrsk/cloud/eg/infrastructure/repository/database/entity/EgApiEndpointDo.java

@@ -24,5 +24,5 @@ public class EgApiEndpointDo extends BaseDo {
     /**
      * 通道配置
      */
-    private String apiConfig;
+    private byte[] apiConfig;
 }

+ 7 - 3
egress-gateway-service-infrastructure/src/test/java/com/hrsk/cloud/op/eg/repository/CustomerMapperTest.java

@@ -1,14 +1,15 @@
 package com.hrsk.cloud.op.eg.repository;
 
 
+import com.hrsk.cloud.eg.infrastructure.clinent.config.RetryRestTemplate;
 import org.junit.Test;
 import org.junit.runner.RunWith;
 import org.springframework.boot.test.context.SpringBootTest;
 import org.springframework.test.context.junit4.SpringRunner;
+import org.springframework.web.client.RestTemplate;
 
 
-
-/** 
+/**
  * @description: 测试类
  * @param:  
  * @return:  
@@ -22,6 +23,9 @@ public class CustomerMapperTest {
 
     @Test
     public void test() {
-
+        RestTemplate restTemplate = new RetryRestTemplate().restTemplate();
+        for (int i = 0; i < 100; i++) {
+            restTemplate.postForEntity("https://www.baidu.com", null, String.class);
+        }
     }
 }