ServiceComb实战

  

<强> ServiceComb实战combDemo
<强>步骤一,配置POM

  
 <代码> & lt; ?xml version=" 1.0 " encoding=" utf - 8 " ?比;
  & lt;项目xmlns=" http://maven.apache.org/POM/4.0.0 " xmlns: xsi=" http://www.w3.org/2001/XMLSchema-instance "
  xsi: schemaLocation=" http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd”比;
  & lt; modelVersion> 4.0.0
  
  & lt; groupId> cn.qchcolud
  & lt; artifactId> combDemo
  & lt; version> 0.0.1-SNAPSHOT
  & lt; packaging> jar
  
  & lt; name> combDemo
  & lt; description> ServiceComb-Spring<演示项目;/description>
  
  & lt; parent>
  & lt; groupId> org.springframework.boot
  & lt; artifactId> spring-boot-starter-parent
  & lt; version> 1.5.12.RELEASE
  & lt; relativePath/比;& lt; !——从库中查找父——比;
  & lt;/parent>
  
  & lt; properties>
  & lt; project.build.sourceEncoding> UTF-8
  & lt; project.reporting.outputEncoding> UTF-8
  & lt; java.version> 1.8 & lt;/java.version>
  & lt;/properties>
  
  & lt; dependencies>
  & lt; dependency>
  & lt; groupId> org.hibernate
  & lt; artifactId> hibernate-validator
  & lt;/dependency>
  
  & lt; dependency>
  & lt; groupId> org.springframework.boot
  & lt; artifactId> spring-boot-starter
  & lt;/dependency>
  & lt; dependency>
  & lt; groupId> org.springframework.boot
  & lt; artifactId> spring-boot-starter-web
  & lt;/dependency>
  & lt; dependency>
  & lt; groupId> org.apache.servicecomb
  & lt; artifactId> spring-boot-starter-provider
  & lt;/dependency>
  
  & lt; dependency>
  & lt; groupId> org.springframework.boot
  & lt; artifactId> spring-boot-starter-test
  & lt; scope> test
  & lt;/dependency>
  & lt; dependency>
  & lt; groupId> mysql
  & lt; artifactId> mysql-connector-java
  & lt;/dependency>
  & lt; dependency>
  & lt; groupId> org.springframework.boot
  & lt; artifactId> spring-boot-starter-data-jpa
  & lt;/dependency>
  & lt; dependency>
  & lt; groupId> io.jsonwebtoken
  & lt; artifactId> jjwt-api
  & lt; version> 0.10.5
  & lt;/dependency>
  & lt; dependency>
  & lt; groupId> io.jsonwebtoken
  & lt; artifactId> jjwt-impl
  & lt; version> 0.10.5
  & lt; scope> runtime
  & lt;/dependency>
  & lt; dependency>
  & lt; groupId> io.jsonwebtoken
  & lt; artifactId> jjwt-jackson
  & lt; version> 0.10.5
  & lt; scope> runtime
  & lt;/dependency>
  
  & lt; dependency>
  & lt; groupId> com.fasterxml.jackson.core
  & lt; artifactId> jackson-databind
  & lt; version> 2.8.8.1
  & lt;/dependency>
  & lt;/dependencies>
  
  & lt; dependencyManagement>
  & lt; dependencies>
  & lt; dependency>
  & lt; groupId> org.apache.servicecomb
  & lt; artifactId> java-chassis-dependencies
  & lt; version> 1.0.0-m2
  & lt; type> pom
  & lt; scope> import
  & lt;/dependency>
  & lt;/dependencies>
  & lt;/dependencyManagement>
  
  & lt; build>
  & lt; plugins>
  & lt; plugin>
  & lt; groupId> org.springframework.boot
  & lt; artifactId> spring-boot-maven-plugin
  & lt;/plugin>
  & lt; plugin>
  & lt; groupId> org.springframework.boot
  & lt; artifactId> spring-boot-maven-plugin
  & lt; version> 1.5.12.RELEASE
  & lt; executions>
  & lt; execution>
  & lt; goals>
  & lt; goal> repackage
  & lt;/goals>
  & lt; configuration>
  & lt; outputDirectory>目标/bin
  & lt; classifier> exec
  & lt;/configuration>
  & lt;/execution>
  & lt;/executions>
  & lt;/plugin>
  & lt; plugin>
  & lt; groupId> org.apache.maven.plugins
  & lt; artifactId> maven-jar-plugin
  & lt; version> 2.6 & lt;/version>
  & lt; configuration>
  & lt; archive>
  & lt; manifestEntries>
  & lt; Class-Path>灵活;/Class-Path>
  & lt;/manifestEntries>
  & lt;/archive>
  & lt;/configuration>
  & lt;/plugin>
  & lt;/plugins>
  & lt;/build>
  
  & lt;/project>
  

ServiceComb实战