Browse Source

Merge branch 'dev_grid_platform' of http://git.elinkit.com.cn:7070/r/epmet-cloud into develop

dev_shibei_match
jianjun 4 years ago
parent
commit
fbcbd89c88
  1. 46
      epmet-module/data-statistical/data-statistical-server/src/test/java/com/epmet/service/user/impl/UserServiceImplTest.java
  2. 11
      epmet-module/open-data-worker/open-data-worker-server/Dockerfile
  3. 18
      epmet-module/open-data-worker/open-data-worker-server/deploy/docker-compose-dev.yml
  4. 18
      epmet-module/open-data-worker/open-data-worker-server/deploy/docker-compose-prod.yml
  5. 18
      epmet-module/open-data-worker/open-data-worker-server/deploy/docker-compose-test.yml
  6. 2
      epmet-module/open-data-worker/open-data-worker-server/src/main/resources/bootstrap.yml

46
epmet-module/data-statistical/data-statistical-server/src/test/java/com/epmet/service/user/impl/UserServiceImplTest.java

@ -1,46 +0,0 @@
package com.epmet.service.user.impl;
import com.alibaba.fastjson.JSON;
import com.epmet.dto.user.param.MidPatrolFormDTO;
import com.epmet.dto.user.result.MidPatrolRecordResult;
import com.epmet.service.user.UserService;
import org.jboss.arquillian.container.test.api.Deployment;
import org.jboss.arquillian.junit.Arquillian;
import org.jboss.shrinkwrap.api.ShrinkWrap;
import org.jboss.shrinkwrap.api.asset.EmptyAsset;
import org.jboss.shrinkwrap.api.spec.JavaArchive;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
import java.util.List;
import static org.junit.Assert.*;
@RunWith(Arquillian.class)
public class UserServiceImplTest {
@Deployment
public static JavaArchive createDeployment() {
return ShrinkWrap.create(JavaArchive.class)
.addClass(UserServiceImpl.class)
.addAsManifestResource(EmptyAsset.INSTANCE, "beans.xml");
}
@Autowired
private UserService userService;
@Test
public void getPatrolRecordList() {
MidPatrolFormDTO midPatrolFormDTO = new MidPatrolFormDTO();
midPatrolFormDTO.setCustomerId("45687aa479955f9d06204d415238f7cc");
midPatrolFormDTO.setPatrolId("");
midPatrolFormDTO.setPageNo(1);
midPatrolFormDTO.setPageSize(110);
List<MidPatrolRecordResult> patrolRecordList = userService.getPatrolRecordList(midPatrolFormDTO);
System.out.println(JSON.toJSONString(patrolRecordList));
}
@Test
public void getPatrolDetailList() {
}
}

11
epmet-module/open-data-worker/open-data-worker-server/Dockerfile

@ -0,0 +1,11 @@
FROM java:8
RUN export LANG="zh_CN.UTF-8"
RUN ln -sf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime
RUN echo 'Asia/Shanghai' > /etc/timezone
COPY ./target/*.jar ./open-data-worker.jar
EXPOSE 8107
ENTRYPOINT ["sh", "-c", "exec $RUN_INSTRUCT"]

18
epmet-module/open-data-worker/open-data-worker-server/deploy/docker-compose-dev.yml

@ -0,0 +1,18 @@
version: "3.7"
services:
gov-voice-server:
container_name: open-data-worker-server-dev
image: 192.168.1.140:5000/epmet-cloud-dev/open-data-worker-server:version_placeholder
ports:
- "8107:8107"
network_mode: host # 使用现有网络
volumes:
- "/opt/epmet-cloud-logs/dev:/logs"
environment:
RUN_INSTRUCT: "java -Xms32m -Xmx200m -jar ./open-data-worker.jar"
restart: "unless-stopped"
deploy:
resources:
limits:
cpus: '0.1'
memory: 250M

18
epmet-module/open-data-worker/open-data-worker-server/deploy/docker-compose-prod.yml

@ -0,0 +1,18 @@
version: "3.7"
services:
gov-voice-server:
container_name: open-data-worker-server-prod
image: registry-vpc.cn-qingdao.aliyuncs.com/epmet-cloud-master/open-data-worker-server:0.3.69
ports:
- "8107:8107"
network_mode: host # 使用现有网络
volumes:
- "/opt/epmet-cloud-logs/prod:/logs"
environment:
RUN_INSTRUCT: "java -Xms256m -Xmx512m -jar ./open-data-worker.jar"
restart: "unless-stopped"
deploy:
resources:
limits:
cpus: '0.1'
memory: 600M

18
epmet-module/open-data-worker/open-data-worker-server/deploy/docker-compose-test.yml

@ -0,0 +1,18 @@
version: "3.7"
services:
gov-voice-server:
container_name: open-data-worker-server-test
image: registry-vpc.cn-qingdao.aliyuncs.com/epmet-cloud-release/open-data-worker-server:version_placeholder
ports:
- "8107:8107"
network_mode: host # 使用现有网络
volumes:
- "/opt/epmet-cloud-logs/test:/logs"
environment:
RUN_INSTRUCT: "java -Xms32m -Xmx300m -jar ./open-data-worker.jar"
restart: "unless-stopped"
deploy:
resources:
limits:
cpus: '0.1'
memory: 350M

2
epmet-module/open-data-worker/open-data-worker-server/src/main/resources/bootstrap.yml

@ -8,7 +8,7 @@ spring:
main:
allow-bean-definition-overriding: true
application:
name: open-data-server
name: open-data-worker-server
#环境 dev|test|prod
profiles:
active: @spring.profiles.active@

Loading…
Cancel
Save