spring cloud + docker 微服务架构

http://www.open-open.com/lib/view/open1437363835818.html

实例项目

https://github.com/kbastani/spring-cloud-microservice-example

编译通过。分享下经验

Apache Maven 3.3.9 (bb52d8502b132ec0a5a3f4c09453c07478323dc5; 2015-11-11T00:41:47+08:00)
Maven home: /usr/share/maven
Java version: 1.8.0_101, vendor: Oracle Corporation
Java home: /usr/lib/jvm/java-1.8.0-openjdk-1.8.0.101-3.b13.el7_2.x86_64/jre
Default locale: zh_CN, platform encoding: UTF-8
OS name: "linux", version: "3.10.0-123.el7.x86_64", arch: "amd64", family: "unix"
  • Maven 3   yum安装的没有编译成功, 后下载 3.3.9 版本覆盖原有内容成功
  • Java 8
  • Docker
  • Docker Compose  下载很慢,可能是网络的事,下载了好多次。

中间遇到了,  提示 Errorinjecting:org.apache.maven.plugin.surefire.surefirePlugin NoClassDefFoundError:...  的异常。

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.18.:test (default-test) on project shopping-cart-service: There are test failures.
[ERROR]
[ERROR] Please refer to /opt/springevent/spring-cloud-event-sourcing-example-master/shopping-cart-service/target/surefire-reports for the individual test results.
[ERROR] -> [Help ]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help ] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command

后来是通过删除maven本地仓库中的 org\apache\maven\surefire 内容,解决的。

推荐看。 http://github.com/shuyouliu/liusy.api

[root@localhost docker]# docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
kbastani/movies-ui latest 0402aa540503 minutes ago 783.5 MB
kbastani/movie-microservice latest 2eac2d8235ef About an hour ago 841.9 MB
kbastani/consul-microservice latest 0d86931cca38 About an hour ago 748.9 MB
kbastani/hystrix-dashboard latest 65133c05f97f hours ago 719.3 MB
kbastani/config-microservice latest 4260142943c7 hours ago 747.4 MB
kbastani/recommendation-microservice latest 177c907dd951 hours ago 841.9 MB
kbastani/api-gateway-microservice latest 64c554fe728b hours ago 739.1 MB
kbastani/discovery-microservice latest c6708d85bf52 hours ago 748.6 MB
kbastani/users-microservice latest 13d9f61b33eb hours ago 843.1 MB

spring cloud 学习研究- spring-cloud-microservice-example的更多相关文章

  1. Spring Cloud 学习 之 Spring Cloud Eureka(源码分析)

    Spring Cloud 学习 之 Spring Cloud Eureka(源码分析) Spring Boot版本:2.1.4.RELEASE Spring Cloud版本:Greenwich.SR1 ...

  2. Spring Cloud 学习 之 Spring Cloud Eureka(搭建)

    Spring Boot版本:2.1.4.RELEASE Spring Cloud版本:Greenwich.SR1 文章目录 搭建服务注册中心: 注册服务提供者: 高可用注册中心: 搭建服务注册中心: ...

  3. Spring Cloud学习笔记--Spring Boot初次搭建

    1. Spring Boot简介 初次接触Spring的时候,我感觉这是一个很难接触的框架,因为其庞杂的配置文件,我最不喜欢的就是xml文件,这种文件的可读性很不好.所以很久以来我的Spring学习都 ...

  4. spring cloud学习(六)Spring Cloud Config

    Spring Cloud Config 参考个人项目 参考个人项目 : (希望大家能给个star~) https://github.com/FunriLy/springcloud-study/tree ...

  5. Spring Cloud 学习 (九) Spring Security, OAuth2

    Spring Security Spring Security 是 Spring Resource 社区的一个安全组件.在安全方面,有两个主要的领域,一是"认证",即你是谁:二是& ...

  6. Spring框架学习03——Spring Bean 的详解

    1.Bean 的配置 Spring可以看做一个大型工厂,用于生产和管理Spring容器中的Bean,Spring框架支持XML和Properties两种格式的配置文件,在实际开发中常用XML格式的配置 ...

  7. Spring框架学习02——Spring IOC 详解

    1.Spring IOC的基本概念 IOC(Inverse of Control)反转控制的概念,就是将原本在程序中手动创建对象的控制权,交由Spring框架管理.当某个Java对象(调用者)需要调用 ...

  8. Spring Boot学习笔记——Spring Boot与MyBatis的集成(项目示例)

    1.准备数据库环境 # 创建数据库 CREATE DATABASE IF NOT EXISTS zifeiydb DEFAULT CHARSET utf8 COLLATE utf8_general_c ...

  9. Spring 框架学习(1)--Spring、Spring MVC扫盲

    纸上得来终觉浅,绝知此事要躬行 文章大纲 什么是spring 传统Java web应用架构 更强的Java Web应用架构--MVC框架 Spring--粘合式框架 spring的内涵 spring核 ...

随机推荐

  1. python序列

    序列基础 序列:python包含6种内建的序列,常用的有:列表.元组.字符串.列表可以修改,元组和字符串不能修改. 索引:从0开始递增,通过索引获取元素:可使用负数索引,从右至左.最后1个元素的位置编 ...

  2. ZeroMQ接口函数之 :zmq_disconnect - 断开一个socket的连接

    ZeroMQ 官方地址 :http://api.zeromq.org/4-0:zmq_disconnect zmq_disconnect(3) ØMQ Manual - ØMQ/3.2.5 Name ...

  3. 李洪强iOS经典面试题141-报错警告调试

    李洪强iOS经典面试题141-报错警告调试   报错警告调试 你在实际开发中,有哪些手机架构与性能调试经验 刚接手公司的旧项目时,模块特别多,而且几乎所有的代码都写在控制器里面,比如UI控件代码.网络 ...

  4. Ubuntu系统的安装与使用 深度音乐播放器

    1.添加深度音乐播放器的ppa源并更新源缓存 sudo add-apt-repository ppa:noobslab/deepin-sc  sudo apt-get update 2. 安装需要的依 ...

  5. 谢欣伦 - OpenDev原创教程 - 设备查找类CxDeviceFind & CxDeviceMapFind

    这是一个精练的设备查找类,类名.函数名和变量名均采用匈牙利命名法.小写的x代表我的姓氏首字母(谢欣伦),个人习惯而已,如有雷同,纯属巧合. CxDeviceFind的使用如下: void CUsbSc ...

  6. jcl-over-slf4j log桥接工具简介

    ava 界里有许多实现日志功能的工具,最早得到广泛使用的是 log4j,许多应用程序的日志部分都交给了 log4j,不过作为组件开发者,他们希望自己的组件不要紧紧依赖某一个工具,毕竟在同一个时候还有很 ...

  7. ansible-copy

    ansible是执行yaml文件控制远端服务器.执行命令为 ansible-playbook my.yamlplaybook是ansible中的脚本,采用yaml语言.VM1安装ansible,ip地 ...

  8. jvisualVM 分析heapdump

    代码很简单,eclipse里面设置下最大堆空间为128m,: @Test public void testOutOfMemory() { List<NewsAddDto> document ...

  9. Angular2 起步(1)

    1.安装 nodejs(最新稳定版)https://nodejs.org/en/ 安装 typescript npm install -g typescript 安装 angular-cli(关于CL ...

  10. 出售一套Unity ARPG手游源码

    项目已经上线,在越南App Store曾经排名第一.客户端Unity C#开发,Android可以热更新,IOS可以更新资源,服务器 C++ + lua开发,文档齐全,欢迎咨询. QQ:7734952 ...