Apache Dubbo编程指南系列之Dubbo-Admin安装和使用

下载https://github.com/apache/dubbo-admin最新板块,在这个板块中Dubbo-admin已经升级为前后端分离,因此这里对于使用者比较难得是安装Dubbo-admin-ui板块了。

dubbo-admin-develop项目部署

1.下载dubbo-admin-develop项目,下载地址:https://github.com/apache/dubbo-admin
2.解压dubbo-admin-develop.zip,解压后的文件如下:
在这里插入图片描述
3.将dubbo-admin-server导入到IDEA开发工具中,修改application.properties文件

#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements.  See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License.  You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#

# centers in dubbo2.7
admin.registry.address=zookeeper://CentOS7:2181
admin.config-center=zookeeper://CentOS7:2181
admin.metadata-report.address=zookeeper://CentOS7:2181

admin.root.user.name=root
admin.root.user.password=root
#group
admin.registry.group=dubbo
admin.config-center.group=dubbo
admin.metadata-report.group=dubbo

admin.apollo.token=e16e5cd903fd0c97a116c873b448544b9d086de9
admin.apollo.appId=test
admin.apollo.env=dev
admin.apollo.cluster=default
admin.apollo.namespace=dubbo

#compress
server.compression.enabled=true
server.compression.mime-types=text/css,text/javascript,application/javascript
server.compression.min-response-size=10240

4.然后执行springboot:run命令启动醒目服务

  .   ____          _            __ _ _
 /\\ / ___'_ __ _ _(_)_ __  __ _ \ \ \ \
( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
 \\/  ___)| |_)| | | | | || (_| |  ) ) ) )
  '  |____| .__|_| |_|_| |_\__, | / / / /
 =========|_|==============|___/=/_/_/_/
 :: Spring Boot ::        (v2.1.4.RELEASE)

log4j:WARN No appenders could be found for logger (org.apache.dubbo.common.logger.LoggerFactory).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.
2020-12-14 15:21:01.636  INFO 5432 --- [           main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat initialized with port(s): 8080 (http)
2020-12-14 15:21:02.191  INFO 5432 --- [           main] o.s.web.context.ContextLoader            : Root WebApplicationContext: initialization completed in 4359 ms
2020-12-14 15:21:05.185  INFO 5432 --- [           main] pertySourcedRequestMappingHandlerMapping : Mapped URL path [/v2/api-docs] onto method [public org.springframework.http.ResponseEntity<springfox.documentation.spring.web.json.Json> springfox.documentation.swagger2.web.Swagger2Controller.getDocumentation(java.lang.String,javax.servlet.http.HttpServletRequest)]
2020-12-14 15:21:05.578  INFO 5432 --- [           main] o.s.s.concurrent.ThreadPoolTaskExecutor  : Initializing ExecutorService 'applicationTaskExecutor'
2020-12-14 15:21:05.979  INFO 5432 --- [           main] d.s.w.p.DocumentationPluginsBootstrapper : Context refreshed
2020-12-14 15:21:06.049  INFO 5432 --- [           main] d.s.w.p.DocumentationPluginsBootstrapper : Found 1 custom documentation plugin(s)
2020-12-14 15:21:06.161  INFO 5432 --- [           main] s.d.s.w.s.ApiListingReferenceScanner     : Scanning for api listing references
2020-12-14 15:21:06.589  INFO 5432 --- [           main] .d.s.w.r.o.CachingOperationNameGenerator : Generating unique operation named: disableRouteUsingPUT_1
2020-12-14 15:21:06.593  INFO 5432 --- [           main] .d.s.w.r.o.CachingOperationNameGenerator : Generating unique operation named: enableRouteUsingPUT_1
2020-12-14 15:21:06.670  INFO 5432 --- [           main] .d.s.w.r.o.CachingOperationNameGenerator : Generating unique operation named: searchServiceUsingGET_1
2020-12-14 15:21:06.794  INFO 5432 --- [           main] .d.s.w.r.o.CachingOperationNameGenerator : Generating unique operation named: createRuleUsingPOST_1
2020-12-14 15:21:06.801  INFO 5432 --- [           main] .d.s.w.r.o.CachingOperationNameGenerator : Generating unique operation named: deleteRouteUsingDELETE_1
2020-12-14 15:21:06.812  INFO 5432 --- [           main] .d.s.w.r.o.CachingOperationNameGenerator : Generating unique operation named: detailRouteUsingGET_1
2020-12-14 15:21:06.831  INFO 5432 --- [           main] .d.s.w.r.o.CachingOperationNameGenerator : Generating unique operation named: disableRouteUsingPUT_2
2020-12-14 15:21:06.840  INFO 5432 --- [           main] .d.s.w.r.o.CachingOperationNameGenerator : Generating unique operation named: enableRouteUsingPUT_2
2020-12-14 15:21:06.857  INFO 5432 --- [           main] .d.s.w.r.o.CachingOperationNameGenerator : Generating unique operation named: searchRoutesUsingGET_1
2020-12-14 15:21:06.863  INFO 5432 --- [           main] .d.s.w.r.o.CachingOperationNameGenerator : Generating unique operation named: updateRuleUsingPUT_1
2020-12-14 15:21:07.348  INFO 5432 --- [           main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 8080 (http) with context path ''
...

5.安装Nodejs服务

  • 下载https://nodejs.org/dist/latest-v12.x/node-v12.20.0-x64.msi服务,傻瓜试安装

6.进入到dubbo-admin-ui的目录下,进入CMD黑窗口执行以下脚本

> npm config set registry  https://registry.npm.taobao.org
> npm install
> npm run dev
...
  App running at:
  - Local:   http://localhost:8082/
  - Network: http://192.168.31.86:8082/

  Note that the development build is not optimized.
  To create a production build, run npm run build.

如果执行失败,删除cache,重新执行。 npm cache clean --force 换完源之后执行这个命令清除一下缓存

7.访问localhost:8082,输入rootroot即可进入页面
在这里插入图片描述

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值