Commit 53e55eaa41e6d76425670a8b086b3ded9d13eddf

Authored by 陶汉栋
2 parents 27ae8e11 2382f6c5
Exists in master and in 1 other branch cloud_copy

Merge branch 'master' of http://git.shunzhi.net/taohd/mycloud

# Conflicts:
#	cloud/common/pom.xml
#	cloud/pom.xml
#	cloud/weigeng/pom.xml
#	cloud/weigeng/src/main/java/com/sincere/weigeng/WeigengApplication.java
cloud/common/pom.xml
@@ -9,8 +9,10 @@ @@ -9,8 +9,10 @@
9 </parent> 9 </parent>
10 <groupId>com.sincere</groupId> 10 <groupId>com.sincere</groupId>
11 <artifactId>common</artifactId> 11 <artifactId>common</artifactId>
12 - <version>0.0.1-SNAPSHOT</version> 12 + <version>1.0.0</version>
13 <name>common</name> 13 <name>common</name>
  14 +
  15 + <packaging>jar</packaging>
14 <description>Demo project for Spring Boot</description> 16 <description>Demo project for Spring Boot</description>
15 17
16 <properties> 18 <properties>
@@ -86,10 +88,13 @@ @@ -86,10 +88,13 @@
86 88
87 <build> 89 <build>
88 <plugins> 90 <plugins>
89 - <!--<plugin>-->  
90 - <!--<groupId>org.springframework.boot</groupId>-->  
91 - <!--<artifactId>spring-boot-maven-plugin</artifactId>-->  
92 - <!--</plugin>--> 91 + <plugin>
  92 + <groupId>org.springframework.boot</groupId>
  93 + <artifactId>spring-boot-maven-plugin</artifactId>
  94 + <configuration>
  95 + <classifier>exec</classifier>
  96 + </configuration>
  97 + </plugin>
93 </plugins> 98 </plugins>
94 </build> 99 </build>
95 100
cloud/common/src/main/java/com/sincere/common/util/RedisUtils.java
@@ -86,9 +86,6 @@ public class RedisUtils { @@ -86,9 +86,6 @@ public class RedisUtils {
86 } 86 }
87 } 87 }
88 88
89 - public static void main(String[] args) {  
90 - RedisUtils.setString("test","test");  
91 - }  
92 /** 89 /**
93 * 释放jedis资源 90 * 释放jedis资源
94 * @param jedis 91 * @param jedis
cloud/common/src/test/java/com/sincere/common/CommonApplicationTests.java
@@ -1,16 +0,0 @@ @@ -1,16 +0,0 @@
1 -package com.sincere.common;  
2 -  
3 -import org.junit.Test;  
4 -import org.junit.runner.RunWith;  
5 -import org.springframework.boot.test.context.SpringBootTest;  
6 -import org.springframework.test.context.junit4.SpringRunner;  
7 -  
8 -@RunWith(SpringRunner.class)  
9 -@SpringBootTest  
10 -public class CommonApplicationTests {  
11 -  
12 - @Test  
13 - public void contextLoads() {  
14 - }  
15 -  
16 -}  
cloud/independence/pom.xml
@@ -15,7 +15,7 @@ @@ -15,7 +15,7 @@
15 <dependency> 15 <dependency>
16 <groupId>com.sincere</groupId> 16 <groupId>com.sincere</groupId>
17 <artifactId>common</artifactId> 17 <artifactId>common</artifactId>
18 - <version>0.0.1-SNAPSHOT</version> 18 + <version>1.0.0</version>
19 </dependency> 19 </dependency>
20 <dependency> 20 <dependency>
21 <groupId>com.googlecode.rapid-framework</groupId> 21 <groupId>com.googlecode.rapid-framework</groupId>
@@ -17,18 +17,20 @@ @@ -17,18 +17,20 @@
17 <modules> 17 <modules>
18 <module>server1</module> 18 <module>server1</module>
19 <module>server2</module> 19 <module>server2</module>
20 - <!--<module>autho</module>--> 20 +<!-- <module>autho</module>-->
21 <module>common</module> 21 <module>common</module>
22 - <module>geteway</module>  
23 - <module>haikang</module>  
24 - <module>dahua</module>  
25 - <module>consumer</module>  
26 - <module>haikangface</module> 22 +<!-- <module>geteway</module>-->
  23 +<!-- <module>haikang</module>-->
  24 +<!-- <module>dahua</module>-->
  25 +<!-- <module>consumer</module>-->
  26 +<!-- <module>haikangface</module>-->
27 <module>search_independence</module> 27 <module>search_independence</module>
28 <module>search_smartCampus</module> 28 <module>search_smartCampus</module>
29 <module>search_xiaoan</module> 29 <module>search_xiaoan</module>
30 - <module>mypulsar</module> 30 +<!-- <module>mypulsar</module>-->
  31 + <module>weigeng</module>
31 <module>independence</module> 32 <module>independence</module>
  33 +<!-- <module>test</module>-->
32 </modules> 34 </modules>
33 35
34 <properties> 36 <properties>
@@ -78,4 +80,21 @@ @@ -78,4 +80,21 @@
78 </dependency> 80 </dependency>
79 </dependencies> 81 </dependencies>
80 </dependencyManagement> 82 </dependencyManagement>
  83 +
  84 + <build>
  85 + <plugins>
  86 + <plugin>
  87 + <groupId>org.springframework.boot</groupId>
  88 + <artifactId>spring-boot-maven-plugin</artifactId>
  89 + <executions>
  90 + <execution>
  91 + <goals>
  92 + <goal>repackage</goal>
  93 + </goals>
  94 + </execution>
  95 + </executions>
  96 + </plugin>
  97 + </plugins>
  98 + </build>
  99 +
81 </project> 100 </project>
cloud/search_independence/pom.xml
@@ -15,7 +15,7 @@ @@ -15,7 +15,7 @@
15 <dependency> 15 <dependency>
16 <groupId>com.sincere</groupId> 16 <groupId>com.sincere</groupId>
17 <artifactId>common</artifactId> 17 <artifactId>common</artifactId>
18 - <version>0.0.1-SNAPSHOT</version> 18 + <version>1.0.0</version>
19 </dependency> 19 </dependency>
20 <dependency> 20 <dependency>
21 <groupId>org.apache.httpcomponents</groupId> 21 <groupId>org.apache.httpcomponents</groupId>
cloud/search_independence/src/main/java/com/sincere/independence/controller/LearnController.java
1 package com.sincere.independence.controller; 1 package com.sincere.independence.controller;
2 2
3 import com.sincere.common.dto.independence.*; 3 import com.sincere.common.dto.independence.*;
4 -import com.sincere.common.util.RedisUtils;  
5 import com.sincere.common.vo.BaseVo; 4 import com.sincere.common.vo.BaseVo;
6 import com.sincere.independence.model.*; 5 import com.sincere.independence.model.*;
7 import com.sincere.independence.service.*; 6 import com.sincere.independence.service.*;
cloud/search_smartCampus/pom.xml
@@ -15,7 +15,7 @@ @@ -15,7 +15,7 @@
15 <dependency> 15 <dependency>
16 <groupId>com.sincere</groupId> 16 <groupId>com.sincere</groupId>
17 <artifactId>common</artifactId> 17 <artifactId>common</artifactId>
18 - <version>0.0.1-SNAPSHOT</version> 18 + <version>1.0.0</version>
19 </dependency> 19 </dependency>
20 <dependency> 20 <dependency>
21 <groupId>io.netty</groupId> 21 <groupId>io.netty</groupId>
cloud/search_xiaoan/pom.xml
@@ -14,7 +14,7 @@ @@ -14,7 +14,7 @@
14 <dependency> 14 <dependency>
15 <groupId>com.sincere</groupId> 15 <groupId>com.sincere</groupId>
16 <artifactId>common</artifactId> 16 <artifactId>common</artifactId>
17 - <version>0.0.1-SNAPSHOT</version> 17 + <version>1.0.0</version>
18 </dependency> 18 </dependency>
19 <!-- https://mvnrepository.com/artifact/io.netty/netty-all --> 19 <!-- https://mvnrepository.com/artifact/io.netty/netty-all -->
20 <dependency> 20 <dependency>
cloud/weigeng/pom.xml 0 → 100644
@@ -0,0 +1,168 @@ @@ -0,0 +1,168 @@
  1 +<?xml version="1.0" encoding="UTF-8"?>
  2 +<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  3 + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
  4 + <modelVersion>4.0.0</modelVersion>
  5 + <parent>
  6 + <artifactId>cloud</artifactId>
  7 + <groupId>com.sincere</groupId>
  8 + <version>1.0.0</version>
  9 + </parent>
  10 + <groupId>com.sincere</groupId>
  11 + <artifactId>weigeng</artifactId>
  12 + <version>0.0.1</version>
  13 + <name>weigeng</name>
  14 + <description>Demo project for Spring Boot</description>
  15 +
  16 +<!-- <properties>-->
  17 +<!-- <java.version>1.8</java.version>-->
  18 +<!-- <spring-cloud.version>Finchley.SR1</spring-cloud.version>-->
  19 +<!-- </properties>-->
  20 +
  21 + <dependencies>
  22 + <dependency>
  23 + <groupId>com.sincere</groupId>
  24 + <artifactId>common</artifactId>
  25 + <version>1.0.0</version>
  26 + </dependency>
  27 + <dependency>
  28 + <groupId>org.apache.mina</groupId>
  29 + <artifactId>mina-core</artifactId>
  30 + <version>2.1.3</version>
  31 + </dependency>
  32 + <dependency>
  33 + <groupId>org.apache.poi</groupId>
  34 + <artifactId>poi</artifactId>
  35 + <version>4.1.0</version>
  36 + </dependency>
  37 +
  38 + <dependency>
  39 + <groupId>org.springframework.boot</groupId>
  40 + <artifactId>spring-boot-starter-test</artifactId>
  41 + <scope>test</scope>
  42 + </dependency>
  43 + <dependency>
  44 + <groupId>org.springframework.cloud</groupId>
  45 + <artifactId>spring-cloud-starter-feign</artifactId>
  46 + <version>1.3.6.RELEASE</version>
  47 + </dependency>
  48 + <dependency>
  49 + <groupId>org.springframework.cloud</groupId>
  50 + <artifactId>spring-cloud-openfeign-core</artifactId>
  51 + <version>2.1.2.RELEASE</version>
  52 + </dependency>
  53 + <dependency>
  54 + <groupId>io.springfox</groupId>
  55 + <artifactId>springfox-swagger2</artifactId>
  56 + <version>2.5.0</version>
  57 + </dependency>
  58 + <dependency>
  59 + <groupId>io.springfox</groupId>
  60 + <artifactId>springfox-swagger-ui</artifactId>
  61 + <version>2.5.0</version>
  62 + </dependency>
  63 + <dependency>
  64 + <groupId>org.apache.commons</groupId>
  65 + <artifactId>commons-lang3</artifactId>
  66 + <version>3.3.2</version>
  67 + </dependency>
  68 +
  69 + </dependencies>
  70 +
  71 + <dependencyManagement>
  72 + <dependencies>
  73 + <dependency>
  74 + <groupId>org.springframework.cloud</groupId>
  75 + <artifactId>spring-cloud-dependencies</artifactId>
  76 + <version>${spring-cloud.version}</version>
  77 + <type>pom</type>
  78 + <scope>import</scope>
  79 + </dependency>
  80 + </dependencies>
  81 + </dependencyManagement>
  82 +
  83 + <build>
  84 + <!--打包文件名-->
  85 + <finalName>weigeng</finalName>
  86 + <!--打包方式-->
  87 + <plugins>
  88 + <!-- 设置编译版本 -->
  89 + <plugin>
  90 + <groupId>org.apache.maven.plugins</groupId>
  91 + <artifactId>maven-compiler-plugin</artifactId>
  92 + <version>3.1</version>
  93 + <configuration>
  94 + <source>1.8</source>
  95 + <target>1.8</target>
  96 + <encoding>UTF-8</encoding>
  97 + </configuration>
  98 + </plugin>
  99 + <!-- 打包jar文件时,配置manifest文件,加入lib包的jar依赖 -->
  100 + <!-- 本地启动需要注释-->
  101 + <plugin>
  102 + <groupId>org.apache.maven.plugins</groupId>
  103 + <artifactId>maven-jar-plugin</artifactId>
  104 + <configuration>
  105 + <archive>
  106 + <manifest>
  107 + <mainClass>com.com.sincere.weigeng.WeigengApplication</mainClass>
  108 + <addClasspath>true</addClasspath>
  109 + <classpathPrefix>lib/</classpathPrefix>
  110 + </manifest>
  111 + <manifestEntries>
  112 + <Class-Path>./config/</Class-Path>
  113 + </manifestEntries>
  114 + </archive>
  115 + <excludes>
  116 + <exclude>config/**</exclude>
  117 + </excludes>
  118 + <classesDirectory></classesDirectory>
  119 + </configuration>
  120 + </plugin>
  121 + <!-- 拷贝依赖的jar包到lib目录 -->
  122 + <plugin>
  123 + <groupId>org.apache.maven.plugins</groupId>
  124 + <artifactId>maven-dependency-plugin</artifactId>
  125 + <executions>
  126 + <execution>
  127 + <id>copy</id>
  128 + <phase>package</phase>
  129 + <goals>
  130 + <goal>copy-dependencies</goal>
  131 + </goals>
  132 + <configuration>
  133 + <outputDirectory>
  134 + ${project.build.directory}/lib
  135 + </outputDirectory>
  136 + </configuration>
  137 + </execution>
  138 + </executions>
  139 + </plugin>
  140 + <!-- 解决资源文件的编码问题 -->
  141 + <plugin>
  142 + <groupId>org.apache.maven.plugins</groupId>
  143 + <artifactId>maven-resources-plugin</artifactId>
  144 + <version>2.5</version>
  145 + <configuration>
  146 + <encoding>UTF-8</encoding>
  147 + </configuration>
  148 + </plugin>
  149 + <!-- 打包source文件为jar文件 -->
  150 + <plugin>
  151 + <artifactId>maven-source-plugin</artifactId>
  152 + <version>2.2</version>
  153 + <configuration>
  154 + <attach>true</attach>
  155 + </configuration>
  156 + <executions>
  157 + <execution>
  158 + <phase>compile</phase>
  159 + <goals>
  160 + <goal>jar</goal>
  161 + </goals>
  162 + </execution>
  163 + </executions>
  164 + </plugin>
  165 + </plugins>
  166 + </build>
  167 +
  168 +</project>
cloud/weigeng/src/main/java/com/sincere/weigeng/WeigengApplication.java 0 → 100644
@@ -0,0 +1,17 @@ @@ -0,0 +1,17 @@
  1 +package com.sincere.weigeng;
  2 +
  3 +import org.springframework.boot.SpringApplication;
  4 +import org.springframework.boot.autoconfigure.SpringBootApplication;
  5 +import org.springframework.cloud.netflix.eureka.EnableEurekaClient;
  6 +import org.springframework.cloud.openfeign.EnableFeignClients;
  7 +
  8 +@EnableFeignClients(basePackages = "com.sincere.weigeng.feign")
  9 +@EnableEurekaClient
  10 +@SpringBootApplication
  11 +public class WeigengApplication {
  12 +
  13 + public static void main(String[] args) {
  14 + SpringApplication.run(WeigengApplication.class, args);
  15 + }
  16 +
  17 +}