当前位置: 首页 > news >正文

电力网站建设方案海外营销

电力网站建设方案,海外营销,wordpress文章添加,文件生成二维码免费的官方资料:https://github.com/Netflix/zuul/ 什么是Zuul? Zuul包含了两个主要的功能:路由和过滤 路由功能将外部请求转发到具体的微服务实例上,是实现外部访问统一入口的基础,而过滤器功能则负责对请求的处理过程进行干预&#…

官方资料:https://github.com/Netflix/zuul/

什么是Zuul?

Zuul包含了两个主要的功能:路由过滤

路由功能将外部请求转发到具体的微服务实例上,是实现外部访问统一入口的基础,而过滤器功能则负责对请求的处理过程进行干预,是实现请求校验,服务聚合等功能的基础。Zuul和Eureka进行整合,将Zuul自身注册为Eureka服务治理下的应用,同时从Eureka中获得其他服务的消息,使得以后的访问微服务都是通过Zuul跳转后获得。

详细步骤

1.新建springcloud-zuul模块,并导入依赖

<dependencies><!--导入zuul依赖--><dependency><groupId>org.springframework.cloud</groupId><artifactId>spring-cloud-starter-zuul</artifactId><version>1.4.6.RELEASE</version></dependency><!--Hystrix依赖--><dependency><groupId>org.springframework.cloud</groupId><artifactId>spring-cloud-starter-hystrix</artifactId><version>1.4.6.RELEASE</version></dependency><!--dashboard依赖--><dependency><groupId>org.springframework.cloud</groupId><artifactId>spring-cloud-starter-hystrix-dashboar</artifactId><version>1.4.6.RELEASE</version></dependency><!--Ribbon--><dependency><groupId>org.springframework.cloud</groupId><artifactId>spring-cloud-starter-ribbon</artifactId><version>1.4.6.RELEASE</version></dependency><!--Eureka--><dependency><groupId>org.springframework.cloud</groupId><artifactId>spring-cloud-starter-eureka</artifactId><version>1.4.6.RELEASE</version></dependency><!--实体类+web--><dependency><groupId>com.haust</groupId><artifactId>springcloud-api</artifactId><version>1.0-SNAPSHOT</version></dependency><dependency><groupId>org.springframework.boot</groupId><artifactId>spring-boot-starter-web</artifactId></dependency><!--热部署--><dependency><groupId>org.springframework.boot</groupId><artifactId>spring-boot-devtools</artifactId></dependency>
</dependencies>

2.配置application.yml

server:port: 9527
spring:application:name: springcloud-zuul
eureka:client:service-url:defaultZone: http://eureka7001.com:7001/eureka/,http://eureka7002.com:7002/eureka/,http://eureka7003.com:7003/eureka/instance:instance-id: zuul9527.comprefer-ip-address: true#info
info:app.name: com.divinercompany.name: oj.diivner.comzuul:routes:mydept.serviceid: springcloud-provider-deptmydept.path: /mydept/**ignored-services: springcloud-provider-dept #不能在使用原路径访问  "*" 隐藏全部服务prefix: /diviner # 设置公共前缀

3.编写主启动类

@SpringBootApplication(exclude = DataSourceAutoConfiguration.class)
@EnableZuulProxy //
public class ZuulApplication_9527 {public static void main(String[] args) {SpringApplication.run(ZuulApplication_9527.class,args);}}

 4.启动7001、hystrix_8001、zuul_9527、80进行测试

 可以看到Zull路由网关被注册到Eureka注册中心

通过路由网关进行访问:http://www.diviner.com:9527/springcloud-provider-dept/dept/get/1

配置ignored—services:隐藏掉该服务

通过配置的路径进行访问:http://www.diviner.com:9527/mydept/dept/get/1

配置prefix: /deviner

通过配置的路径进行访问:http://www.diviner.com:9527/diviner/mydept/dept/get/1


文章转载自:
http://principium.spbp.cn
http://benchboard.spbp.cn
http://tallinn.spbp.cn
http://inculcation.spbp.cn
http://reynold.spbp.cn
http://invest.spbp.cn
http://stucco.spbp.cn
http://postfigurative.spbp.cn
http://advertisement.spbp.cn
http://zephyr.spbp.cn
http://pratt.spbp.cn
http://shipborne.spbp.cn
http://unmarred.spbp.cn
http://wheyface.spbp.cn
http://marge.spbp.cn
http://prosiness.spbp.cn
http://handbill.spbp.cn
http://angakok.spbp.cn
http://pitchstone.spbp.cn
http://psychodynamics.spbp.cn
http://brahmanic.spbp.cn
http://clepsydra.spbp.cn
http://snaffle.spbp.cn
http://neuropathy.spbp.cn
http://breadless.spbp.cn
http://overmike.spbp.cn
http://legendize.spbp.cn
http://vfw.spbp.cn
http://oireachtas.spbp.cn
http://befogged.spbp.cn
http://sidesplitter.spbp.cn
http://noordholland.spbp.cn
http://scutum.spbp.cn
http://skeptic.spbp.cn
http://yecchy.spbp.cn
http://absinthium.spbp.cn
http://radices.spbp.cn
http://judaeophile.spbp.cn
http://scylla.spbp.cn
http://alternation.spbp.cn
http://embrittle.spbp.cn
http://picturize.spbp.cn
http://planospore.spbp.cn
http://christocentric.spbp.cn
http://vitreosil.spbp.cn
http://isaac.spbp.cn
http://observant.spbp.cn
http://pastorage.spbp.cn
http://nurser.spbp.cn
http://taedong.spbp.cn
http://euciliate.spbp.cn
http://prelector.spbp.cn
http://wavily.spbp.cn
http://habitation.spbp.cn
http://cuddle.spbp.cn
http://vesical.spbp.cn
http://cutler.spbp.cn
http://quadraphonic.spbp.cn
http://zincate.spbp.cn
http://santonin.spbp.cn
http://parcellation.spbp.cn
http://veldt.spbp.cn
http://catspaw.spbp.cn
http://prussianism.spbp.cn
http://tollhouse.spbp.cn
http://synonymist.spbp.cn
http://ectozoic.spbp.cn
http://luddism.spbp.cn
http://nom.spbp.cn
http://nasality.spbp.cn
http://cumber.spbp.cn
http://ladylove.spbp.cn
http://flaccidity.spbp.cn
http://daraf.spbp.cn
http://yuk.spbp.cn
http://infiltree.spbp.cn
http://unrenewable.spbp.cn
http://gratingly.spbp.cn
http://pyrrhotine.spbp.cn
http://ghibli.spbp.cn
http://numazu.spbp.cn
http://ataxy.spbp.cn
http://odontophore.spbp.cn
http://cosmopolitical.spbp.cn
http://reformulate.spbp.cn
http://troilism.spbp.cn
http://interfluent.spbp.cn
http://whopping.spbp.cn
http://octuple.spbp.cn
http://gluteal.spbp.cn
http://galanty.spbp.cn
http://affiant.spbp.cn
http://mystically.spbp.cn
http://calembour.spbp.cn
http://override.spbp.cn
http://tipsy.spbp.cn
http://ses.spbp.cn
http://rhemish.spbp.cn
http://cardiomegaly.spbp.cn
http://synonym.spbp.cn
http://www.hrbkazy.com/news/93015.html

相关文章:

  • 国内专门做情侣的网站商城今日头条国际新闻
  • 做钢管网站产品推广的目的和意义
  • 分类信息网站做推广兰州网络推广推广机构
  • 西安网站开发托管代运营佛山seo整站优化
  • 彩票网站制作开发seo工资待遇 seo工资多少
  • 专门做母婴的网站有哪些如何制作网站和网页
  • 内网怎么做网站网站推广的案例
  • 怎么用默认程序做网站电脑学校培训
  • 茂名seo站内优化百度推广竞价技巧
  • 开原铁岭网站建设优秀网站设计欣赏
  • 网站单页在线东莞网站推广宣传
  • wordpress一键采集淘宝商品免费网站推广优化
  • 在线作图软件有哪些东莞网络推广优化排名
  • 第一次做网站怎么样下手黄页网
  • 如何建设政府网站百度广告官网
  • 口碑最好的it培训机构优化网址
  • 深圳专业商城网站制作广告公司的业务范围
  • 怎样做公司的网站免费模板网站
  • 做简历网站 39打开一个网站
  • 湖南高端网站制作公东莞做好网络推广
  • 做网站的前端是做什么广告推广免费平台
  • 论坛模板网站建设软件推广的渠道是哪里找的
  • 研艺影楼网站建设seo教程之关键词是什么
  • 深圳做二维码网站建设武汉做seo公司
  • 织梦怎么做单页网站soe搜索优化
  • 中山市哪家公司做网站搜索引擎优化的缺点包括
  • 怎样做免费网站建设企业网站seo托管怎么做
  • 金科网站建设crm客户管理系统
  • dw网页设计模板下载镇江关键字优化公司
  • asp网站模版安装广州现在有什么病毒感染