Commit a5f892212f0a877b0242122d921e0eaab18dddbd
1 parent
51816693
Exists in
master
日志
Showing
17 changed files
with
23 additions
and
264 deletions
Show diff stats
cloud/lapi/pom.xml
... | ... | @@ -128,7 +128,7 @@ |
128 | 128 | <configuration> |
129 | 129 | <archive> |
130 | 130 | <manifest> |
131 | - <mainClass>com.sincere.lapi.LapiDemoApplication</mainClass> | |
131 | + <mainClass>com.sincere.lapi.LapiApplication</mainClass> | |
132 | 132 | <addClasspath>true</addClasspath> |
133 | 133 | <classpathPrefix>lib/</classpathPrefix> |
134 | 134 | </manifest> | ... | ... |
cloud/lapi/src/main/java/com/sincere/lapi/LapiApplication.java
0 → 100644
... | ... | @@ -0,0 +1,18 @@ |
1 | +package com.sincere.lapi; | |
2 | + | |
3 | +import com.sincere.lapi.server.ServerRun; | |
4 | +import org.springframework.boot.SpringApplication; | |
5 | +import org.springframework.boot.autoconfigure.SpringBootApplication; | |
6 | +import org.springframework.cloud.openfeign.EnableFeignClients; | |
7 | + | |
8 | +@EnableFeignClients(basePackages = "com.sincere.lapi.feign") | |
9 | +@SpringBootApplication | |
10 | +public class LapiApplication { | |
11 | + | |
12 | + public static void main(String[] args) { | |
13 | + SpringApplication.run(LapiApplication.class, args); | |
14 | + ServerRun serverRun = new ServerRun(); | |
15 | + serverRun.start(5300); | |
16 | + } | |
17 | + | |
18 | +} | ... | ... |
cloud/lapi/src/main/java/com/sincere/lapi/LapiDemoApplication.java
... | ... | @@ -1,18 +0,0 @@ |
1 | -package com.sincere.lapi; | |
2 | - | |
3 | -import com.sincere.lapi.server.ServerRun; | |
4 | -import org.springframework.boot.SpringApplication; | |
5 | -import org.springframework.boot.autoconfigure.SpringBootApplication; | |
6 | -import org.springframework.cloud.openfeign.EnableFeignClients; | |
7 | - | |
8 | -@EnableFeignClients(basePackages = "com.sincere.lapi.feign") | |
9 | -@SpringBootApplication | |
10 | -public class LapiDemoApplication { | |
11 | - | |
12 | - public static void main(String[] args) { | |
13 | - SpringApplication.run(LapiDemoApplication.class, args); | |
14 | - ServerRun serverRun = new ServerRun(); | |
15 | - serverRun.start(5300); | |
16 | - } | |
17 | - | |
18 | -} |
cloud/lapi/src/main/java/com/sincere/lapi/controller/LapiController.java
1 | -/* | |
2 | - * Copyright (c) 2018, ZheJiang Uniview Technologies Co., Ltd. All rights reserved. | |
3 | - * <http://www.uniview.com/> | |
4 | - *------------------------------------------------------------------------------ | |
5 | - * Product : 速通门 | |
6 | - * Module Name : com.unv.fastgate.server.service | |
7 | - * Date Created: 2019/5/7 | |
8 | - * Creator : dW5565 dongchenghao | |
9 | - * Description : | |
10 | - * | |
11 | - *------------------------------------------------------------------------------ | |
12 | - * Modification History | |
13 | - * DATE NAME DESCRIPTION | |
14 | - *------------------------------------------------------------------------------ | |
15 | - *------------------------------------------------------------------------------ | |
16 | - */ | |
17 | 1 | package com.sincere.lapi.controller; |
18 | 2 | |
19 | 3 | import com.alibaba.fastjson.JSONArray; |
... | ... | @@ -39,9 +23,9 @@ import sun.misc.BASE64Encoder; |
39 | 23 | import java.util.*; |
40 | 24 | |
41 | 25 | /** |
42 | - * description | |
43 | - * | |
44 | - * @author dW5565 | |
26 | + * @author chen | |
27 | + * @version 1.0 | |
28 | + * @date 2019/11/28 0028 9:17 | |
45 | 29 | */ |
46 | 30 | @RestController |
47 | 31 | public class LapiController { | ... | ... |
cloud/lapi/src/main/java/com/sincere/lapi/pojo/IdentificationInfo.java
1 | -/* | |
2 | - * Copyright (c) 2018, ZheJiang Uniview Technologies Co., Ltd. All rights reserved. | |
3 | - * <http://www.uniview.com/> | |
4 | - *------------------------------------------------------------------------------ | |
5 | - * Product : 速通门 | |
6 | - * Module Name : com.unv.fastgate.server.service | |
7 | - * Date Created: 2019/5/13 | |
8 | - * Creator : dW5565 dongchenghao | |
9 | - * Description : | |
10 | - * | |
11 | - *------------------------------------------------------------------------------ | |
12 | - * Modification History | |
13 | - * DATE NAME DESCRIPTION | |
14 | - *------------------------------------------------------------------------------ | |
15 | - *------------------------------------------------------------------------------ | |
16 | - */ | |
17 | 1 | package com.sincere.lapi.pojo; |
18 | 2 | |
19 | 3 | import com.alibaba.fastjson.annotation.JSONField; |
20 | 4 | |
21 | -/** | |
22 | - * description | |
23 | - * | |
24 | - * @author dW5565 | |
25 | - */ | |
26 | 5 | public class IdentificationInfo { |
27 | 6 | |
28 | 7 | @JSONField(name = "Type", ordinal = 1) | ... | ... |
cloud/lapi/src/main/java/com/sincere/lapi/pojo/LAPIResponse.java
cloud/lapi/src/main/java/com/sincere/lapi/pojo/PersonImageInfo.java
1 | -/* | |
2 | - * Copyright (c) 2018, ZheJiang Uniview Technologies Co., Ltd. All rights reserved. | |
3 | - * <http://www.uniview.com/> | |
4 | - *------------------------------------------------------------------------------ | |
5 | - * Product : 速通门 | |
6 | - * Module Name : com.unv.fastgate.server.service | |
7 | - * Date Created: 2019/5/13 | |
8 | - * Creator : dW5565 dongchenghao | |
9 | - * Description : | |
10 | - * | |
11 | - *------------------------------------------------------------------------------ | |
12 | - * Modification History | |
13 | - * DATE NAME DESCRIPTION | |
14 | - *------------------------------------------------------------------------------ | |
15 | - *------------------------------------------------------------------------------ | |
16 | - */ | |
17 | 1 | package com.sincere.lapi.pojo; |
18 | 2 | |
19 | 3 | import com.alibaba.fastjson.annotation.JSONField; |
20 | 4 | |
21 | -/** | |
22 | - * description | |
23 | - * | |
24 | - * @author dW5565 | |
25 | - */ | |
26 | 5 | public class PersonImageInfo { |
27 | 6 | @JSONField(name = "FaceID", ordinal = 1) |
28 | 7 | private Long faceID; | ... | ... |
cloud/lapi/src/main/java/com/sincere/lapi/pojo/PersonInfo.java
1 | -/* | |
2 | - * Copyright (c) 2018, ZheJiang Uniview Technologies Co., Ltd. All rights reserved. | |
3 | - * <http://www.uniview.com/> | |
4 | - *------------------------------------------------------------------------------ | |
5 | - * Product : 速通门 | |
6 | - * Module Name : com.unv.fastgate.server.service | |
7 | - * Date Created: 2019/5/13 | |
8 | - * Creator : dW5565 dongchenghao | |
9 | - * Description : | |
10 | - * | |
11 | - *------------------------------------------------------------------------------ | |
12 | - * Modification History | |
13 | - * DATE NAME DESCRIPTION | |
14 | - *------------------------------------------------------------------------------ | |
15 | - *------------------------------------------------------------------------------ | |
16 | - */ | |
17 | 1 | package com.sincere.lapi.pojo; |
18 | 2 | |
19 | 3 | import com.alibaba.fastjson.annotation.JSONField; |
20 | 4 | |
21 | 5 | import java.util.List; |
22 | 6 | |
23 | -/** | |
24 | - * description | |
25 | - * | |
26 | - * @author dW5565 | |
27 | - */ | |
28 | 7 | public class PersonInfo { |
29 | 8 | |
30 | 9 | @JSONField(name = "PersonID", ordinal = 1) | ... | ... |
cloud/lapi/src/main/java/com/sincere/lapi/pojo/PersonInfoList.java
1 | -/* | |
2 | - * Copyright (c) 2018, ZheJiang Uniview Technologies Co., Ltd. All rights reserved. | |
3 | - * <http://www.uniview.com/> | |
4 | - *------------------------------------------------------------------------------ | |
5 | - * Product : 速通门 | |
6 | - * Module Name : com.unv.fastgate.server.service | |
7 | - * Date Created: 2019/5/13 | |
8 | - * Creator : dW5565 dongchenghao | |
9 | - * Description : | |
10 | - * | |
11 | - *------------------------------------------------------------------------------ | |
12 | - * Modification History | |
13 | - * DATE NAME DESCRIPTION | |
14 | - *------------------------------------------------------------------------------ | |
15 | - *------------------------------------------------------------------------------ | |
16 | - */ | |
17 | 1 | package com.sincere.lapi.pojo; |
18 | 2 | |
19 | 3 | import com.alibaba.fastjson.annotation.JSONField; |
20 | 4 | |
21 | 5 | import java.util.List; |
22 | 6 | |
23 | -/** | |
24 | - * description | |
25 | - * | |
26 | - * @author dW5565 | |
27 | - */ | |
28 | 7 | public class PersonInfoList { |
29 | 8 | |
30 | 9 | @JSONField(name = "Num", ordinal = 1) | ... | ... |
cloud/lapi/src/main/java/com/sincere/lapi/pojo/PersonTimeTemplateInfo.java
1 | -/* | |
2 | - * Copyright (c) 2018, ZheJiang Uniview Technologies Co., Ltd. All rights reserved. | |
3 | - * <http://www.uniview.com/> | |
4 | - *------------------------------------------------------------------------------ | |
5 | - * Product : 速通门 | |
6 | - * Module Name : com.unv.fastgate.server.service | |
7 | - * Date Created: 2019/5/13 | |
8 | - * Creator : dW5565 dongchenghao | |
9 | - * Description : | |
10 | - * | |
11 | - *------------------------------------------------------------------------------ | |
12 | - * Modification History | |
13 | - * DATE NAME DESCRIPTION | |
14 | - *------------------------------------------------------------------------------ | |
15 | - *------------------------------------------------------------------------------ | |
16 | - */ | |
17 | 1 | package com.sincere.lapi.pojo; |
18 | 2 | |
19 | 3 | import com.alibaba.fastjson.annotation.JSONField; |
20 | 4 | |
21 | -/** | |
22 | - * description | |
23 | - * | |
24 | - * @author dW5565 | |
25 | - */ | |
26 | 5 | public class PersonTimeTemplateInfo { |
27 | 6 | |
28 | 7 | ... | ... |
cloud/lapi/src/main/java/com/sincere/lapi/server/ServerRun.java
1 | -/* | |
2 | - * Copyright (c) 2018, ZheJiang Uniview Technologies Co., Ltd. All rights reserved. | |
3 | - * <http://www.uniview.com/> | |
4 | - *------------------------------------------------------------------------------ | |
5 | - * Product : 速通门 | |
6 | - * Module Name : com.unv.fastgate.server.service | |
7 | - * Date Created: 2019/5/7 | |
8 | - * Creator : dW5565 dongchenghao | |
9 | - * Description : | |
10 | - * | |
11 | - *------------------------------------------------------------------------------ | |
12 | - * Modification History | |
13 | - * DATE NAME DESCRIPTION | |
14 | - *------------------------------------------------------------------------------ | |
15 | - *------------------------------------------------------------------------------ | |
16 | - */ | |
17 | 1 | package com.sincere.lapi.server; |
18 | 2 | |
19 | 3 | import com.sincere.lapi.server.thread.ServerThread; |
20 | 4 | |
21 | -/** | |
22 | - * description | |
23 | - * | |
24 | - * @author dW5565 | |
25 | - */ | |
5 | + | |
26 | 6 | public class ServerRun { |
27 | 7 | public void start(int port){ |
28 | 8 | try { | ... | ... |
cloud/lapi/src/main/java/com/sincere/lapi/server/handler/HttpClientHandler.java
... | ... | @@ -25,11 +25,6 @@ import java.util.Date; |
25 | 25 | |
26 | 26 | import static io.netty.buffer.Unpooled.copiedBuffer; |
27 | 27 | |
28 | -/** | |
29 | - * description | |
30 | - * | |
31 | - * @author dW5565 | |
32 | - */ | |
33 | 28 | public class HttpClientHandler extends ChannelInboundHandlerAdapter { |
34 | 29 | |
35 | 30 | Logger logger = LoggerFactory.getLogger(HttpClientHandler.class); | ... | ... |
cloud/lapi/src/main/java/com/sincere/lapi/server/init/LapiServerInitializer.java
1 | -/* | |
2 | - * Copyright (c) 2018, ZheJiang Uniview Technologies Co., Ltd. All rights reserved. | |
3 | - * <http://www.uniview.com/> | |
4 | - *------------------------------------------------------------------------------ | |
5 | - * Product : 速通门 | |
6 | - * Module Name : com.unv.fastgate.server.service | |
7 | - * Date Created: 2019/5/8 | |
8 | - * Creator : dW5565 dongchenghao | |
9 | - * Description : | |
10 | - * | |
11 | - *------------------------------------------------------------------------------ | |
12 | - * Modification History | |
13 | - * DATE NAME DESCRIPTION | |
14 | - *------------------------------------------------------------------------------ | |
15 | - *------------------------------------------------------------------------------ | |
16 | - */ | |
17 | 1 | package com.sincere.lapi.server.init; |
18 | 2 | |
19 | 3 | import com.sincere.lapi.server.handler.HttpClientHandler; |
... | ... | @@ -25,12 +9,6 @@ import io.netty.handler.codec.string.StringDecoder; |
25 | 9 | import io.netty.handler.timeout.ReadTimeoutHandler; |
26 | 10 | |
27 | 11 | |
28 | - | |
29 | -/** | |
30 | - * description | |
31 | - * | |
32 | - * @author dW5565 | |
33 | - */ | |
34 | 12 | public class LapiServerInitializer extends ChannelInitializer<SocketChannel> { |
35 | 13 | |
36 | 14 | @Override | ... | ... |
cloud/lapi/src/main/java/com/sincere/lapi/server/init/NettyFactory.java
1 | -/* | |
2 | - * Copyright (c) 2018, ZheJiang Uniview Technologies Co., Ltd. All rights reserved. | |
3 | - * <http://www.uniview.com/> | |
4 | - *------------------------------------------------------------------------------ | |
5 | - * Product : 速通门 | |
6 | - * Module Name : com.unv.fastgate.server.service | |
7 | - * Date Created: 2019/5/8 | |
8 | - * Creator : dW5565 dongchenghao | |
9 | - * Description : | |
10 | - * | |
11 | - *------------------------------------------------------------------------------ | |
12 | - * Modification History | |
13 | - * DATE NAME DESCRIPTION | |
14 | - *------------------------------------------------------------------------------ | |
15 | - *------------------------------------------------------------------------------ | |
16 | - */ | |
17 | 1 | package com.sincere.lapi.server.init; |
18 | 2 | |
19 | 3 | import io.netty.bootstrap.ServerBootstrap; |
... | ... | @@ -23,11 +7,6 @@ import io.netty.channel.EventLoopGroup; |
23 | 7 | import io.netty.channel.nio.NioEventLoopGroup; |
24 | 8 | import io.netty.channel.socket.nio.NioServerSocketChannel; |
25 | 9 | |
26 | -/** | |
27 | - * description | |
28 | - * | |
29 | - * @author dW5565 | |
30 | - */ | |
31 | 10 | public class NettyFactory { |
32 | 11 | |
33 | 12 | public void createNetty(int port) { | ... | ... |
cloud/lapi/src/main/java/com/sincere/lapi/server/pojo/HeartBack.java
1 | -/* | |
2 | - * Copyright (c) 2018, ZheJiang Uniview Technologies Co., Ltd. All rights reserved. | |
3 | - * <http://www.uniview.com/> | |
4 | - *------------------------------------------------------------------------------ | |
5 | - * Product : 速通门 | |
6 | - * Module Name : com.unv.fastgate.server.service | |
7 | - * Date Created: 2019/5/9 | |
8 | - * Creator : dW5565 dongchenghao | |
9 | - * Description : | |
10 | - * | |
11 | - *------------------------------------------------------------------------------ | |
12 | - * Modification History | |
13 | - * DATE NAME DESCRIPTION | |
14 | - *------------------------------------------------------------------------------ | |
15 | - *------------------------------------------------------------------------------ | |
16 | - */ | |
17 | 1 | package com.sincere.lapi.server.pojo; |
18 | 2 | |
19 | 3 | import com.alibaba.fastjson.annotation.JSONField; |
20 | 4 | |
21 | -/** | |
22 | - * 本用例未做心跳回包,请自行回包 | |
23 | - * | |
24 | - * @author dW5565 | |
25 | - */ | |
26 | 5 | public class HeartBack { |
27 | 6 | |
28 | 7 | @JSONField(name = "ResponseURL", ordinal = 1) | ... | ... |
cloud/lapi/src/main/java/com/sincere/lapi/server/thread/ServerThread.java
1 | -/* | |
2 | - * Copyright (c) 2018, ZheJiang Uniview Technologies Co., Ltd. All rights reserved. | |
3 | - * <http://www.uniview.com/> | |
4 | - *------------------------------------------------------------------------------ | |
5 | - * Product : 速通门 | |
6 | - * Module Name : com.unv.fastgate.server.service | |
7 | - * Date Created: 2019/5/7 | |
8 | - * Creator : dW5565 dongchenghao | |
9 | - * Description : | |
10 | - * | |
11 | - *------------------------------------------------------------------------------ | |
12 | - * Modification History | |
13 | - * DATE NAME DESCRIPTION | |
14 | - *------------------------------------------------------------------------------ | |
15 | - *------------------------------------------------------------------------------ | |
16 | - */ | |
17 | 1 | package com.sincere.lapi.server.thread; |
18 | 2 | |
19 | 3 | import com.sincere.lapi.server.init.NettyFactory; |
20 | 4 | |
21 | - | |
22 | -/** | |
23 | - * description | |
24 | - * | |
25 | - * @author dW5565 | |
26 | - */ | |
27 | 5 | public class ServerThread implements Runnable { |
28 | 6 | private int port; |
29 | 7 | ... | ... |
cloud/lapi/src/main/java/com/sincere/lapi/service/request/TerminalHttpCall.java