springboot+springcloudgateway+nacos+sleuth+zipkin+mysql

news/2024/5/20 9:08:15/文章来源:https://blog.csdn.net/fivehundredyearsago/article/details/127324779

zipkin服务端安装

1.下载zipkin的Jar包

https://search.maven.org/remote_content?g=io.zipkin.java&a=zipkin-server&v=LATEST&c=exec

windows 命令行cd到zipkin目录下 C:\zipkin

启动命令:java -jar zipkin-server-2.12.9-exec.jar

打开浏览器:http://localhost:9411

nacos下载地址:https://github.com/alibaba/nacos/releases

windows 命令行cd到zipkin目录下 C:\nacos\bin

启动命令:startup.cmd -m standalone

2.springboot

1)父pom

<?xml version="1.0" encoding="UTF-8"?>
<projectxmlns="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"><modelVersion>4.0.0</modelVersion><parent><groupId>org.springframework.boot</groupId><artifactId>spring-boot-starter-parent</artifactId><version>2.3.4.RELEASE</version><relativePath/></parent><groupId>datamonitor</groupId><artifactId>data-monitor</artifactId><packaging>pom</packaging><version>1.0.0-SNAPSHOT</version><properties><java.version>1.8</java.version><spring-cloud.version>Hoxton.SR1</spring-cloud.version><maven.compiler.source>1.8</maven.compiler.source><maven.compiler.target>1.8</maven.compiler.target><maven.compiler.compilerVersion>1.8</maven.compiler.compilerVersion></properties><dependencies></dependencies><dependencyManagement><dependencies><dependency><groupId>org.springframework.cloud</groupId><artifactId>spring-cloud-dependencies</artifactId><version>${spring-cloud.version}</version><type>pom</type></dependency><dependency><groupId>org.springframework.cloud</groupId><artifactId>spring-cloud-alibaba-dependencies</artifactId><version>0.2.2.RELEASE</version><type>pom</type></dependency></dependencies></dependencyManagement><modules><module>data-monitor-gateway</module><module>data-monitor-user</module></modules>
</project>

2)网关pom

<?xml version="1.0" encoding="UTF-8"?>
<projectxmlns="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"><modelVersion>4.0.0</modelVersion><artifactId>data-monitor-gateway</artifactId><version>1.0</version><description>网关模块</description><parent><groupId>datamonitor</groupId><artifactId>data-monitor</artifactId><version>1.0.0-SNAPSHOT</version><relativePath>../pom.xml</relativePath></parent><properties><project.build.sourceEncoding>UTF-8</project.build.sourceEncoding><maven.compiler.source>1.8</maven.compiler.source><maven.compiler.target>1.8</maven.compiler.target><maven.compiler.compilerVersion>1.8</maven.compiler.compilerVersion></properties><dependencies><!--nacos dicovery--><dependency><groupId>com.alibaba.cloud</groupId><artifactId>spring-cloud-starter-alibaba-nacos-discovery</artifactId><version>2021.1</version></dependency><dependency><groupId>com.alibaba.cloud</groupId><artifactId>spring-cloud-starter-alibaba-nacos-config</artifactId><version>2021.1</version></dependency><dependency><groupId>org.springframework.cloud</groupId><artifactId>spring-cloud-starter-bootstrap</artifactId><version>3.1.4</version><exclusions><exclusion><artifactId>spring-cloud-starter</artifactId><groupId>org.springframework.cloud</groupId></exclusion><exclusion><artifactId>spring-cloud-context</artifactId><groupId>org.springframework.cloud</groupId></exclusion><exclusion><artifactId>spring-cloud-commons</artifactId><groupId>org.springframework.cloud</groupId></exclusion></exclusions></dependency><dependency><groupId>org.springframework.boot</groupId><artifactId>spring-boot-starter-test</artifactId><scope>test</scope></dependency><dependency><groupId>org.springframework.cloud</groupId><artifactId>spring-cloud-starter-gateway</artifactId><version>2.2.6.RELEASE</version><exclusions><exclusion><artifactId>spring-cloud-starter</artifactId><groupId>org.springframework.cloud</groupId></exclusion></exclusions></dependency><dependency><groupId>org.springframework.cloud</groupId><artifactId>spring-cloud-starter-feign</artifactId></dependency><dependency><groupId>org.springframework.cloud</groupId><artifactId>spring-cloud-starter-loadbalancer</artifactId></dependency><dependency><groupId>org.apache.logging.log4j</groupId><artifactId>log4j-core</artifactId></dependency><dependency><groupId>org.projectlombok</groupId><artifactId>lombok</artifactId></dependency><!-- 链路追踪组件 --><dependency><groupId>org.springframework.cloud</groupId><artifactId>spring-cloud-starter-sleuth</artifactId><version>2.1.0.RELEASE</version></dependency><dependency><groupId>org.springframework.cloud</groupId><artifactId>spring-cloud-starter-zipkin</artifactId><version>2.1.0.RELEASE</version></dependency><dependency><groupId>org.springframework.cloud</groupId><artifactId>spring-cloud-netflix-core</artifactId><version>1.3.1.RELEASE</version></dependency><dependency><groupId>com.alibaba.fastjson2</groupId><artifactId>fastjson2</artifactId><version>2.0.14</version><scope>compile</scope></dependency><dependency><groupId>io.zipkin.brave</groupId><artifactId>brave-mysql</artifactId><version>3.9.0</version></dependency></dependencies><build><finalName>data-monitor-gateway</finalName><plugins><plugin><groupId>org.springframework.boot</groupId><artifactId>spring-boot-maven-plugin</artifactId></plugin></plugins></build>
</project>

3)用户pom

<?xml version="1.0" encoding="UTF-8"?>
<projectxmlns="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"><modelVersion>4.0.0</modelVersion><artifactId>data-monitor-user</artifactId><version>1.0</version><description>用户管理模块</description><parent><groupId>datamonitor</groupId><artifactId>data-monitor</artifactId><version>1.0.0-SNAPSHOT</version><relativePath>../pom.xml</relativePath></parent><properties><project.build.sourceEncoding>UTF-8</project.build.sourceEncoding><maven.compiler.source>1.8</maven.compiler.source><maven.compiler.target>1.8</maven.compiler.target><maven.compiler.compilerVersion>1.8</maven.compiler.compilerVersion></properties><dependencies><!--nacos dicovery--><dependency><groupId>com.alibaba.cloud</groupId><artifactId>spring-cloud-starter-alibaba-nacos-discovery</artifactId><version>2021.1</version></dependency><dependency><groupId>com.alibaba.cloud</groupId><artifactId>spring-cloud-starter-alibaba-nacos-config</artifactId><version>2021.1</version></dependency><dependency><groupId>org.springframework.cloud</groupId><artifactId>spring-cloud-starter-bootstrap</artifactId><version>3.1.4</version></dependency><dependency><groupId>org.springframework.boot</groupId><artifactId>spring-boot-starter-web</artifactId></dependency><dependency><groupId>org.springframework.boot</groupId><artifactId>spring-boot-starter-test</artifactId><scope>test</scope></dependency><dependency><groupId>org.springframework.boot</groupId><artifactId>spring-boot-starter-jdbc</artifactId></dependency><dependency><groupId>mysql</groupId><artifactId>mysql-connector-java</artifactId><version>8.0.30</version><scope>runtime</scope></dependency><dependency><groupId>org.mybatis.spring.boot</groupId><artifactId>mybatis-spring-boot-starter-test</artifactId><version>2.2.2</version><scope>test</scope></dependency><!-- druid连接池 --><dependency><groupId>com.alibaba</groupId><artifactId>druid-spring-boot-starter</artifactId><version>1.2.12</version></dependency><dependency><groupId>com.baomidou</groupId><artifactId>mybatis-plus-boot-starter</artifactId><version>3.4.0</version></dependency><!--代码生成器依赖--><dependency><groupId>com.baomidou</groupId><artifactId>mybatis-plus-generator</artifactId><version>3.4.0</version></dependency><!-- velocity 模板 --><dependency><groupId>org.apache.velocity</groupId><artifactId>velocity</artifactId><version>1.7</version></dependency><dependency><groupId>org.springframework.boot</groupId><artifactId>spring-boot-starter-aop</artifactId><version>2.4.5</version></dependency><!-- spring cloud --><dependency><groupId>org.springframework.cloud</groupId><artifactId>spring-cloud-context</artifactId><version>3.0.2</version></dependency><!-- spring security --><!--<dependency><groupId>org.springframework.boot</groupId><artifactId>spring-boot-starter-security</artifactId></dependency><dependency><groupId>org.springframework.security</groupId><artifactId>spring-security-jwt</artifactId><version>1.1.1.RELEASE</version><exclusions><exclusion><groupId>org.bouncycastle</groupId><artifactId>bcpkix-jdk15on</artifactId></exclusion></exclusions></dependency>&lt;!&ndash;JWT(Json Web Token)登录支持 &ndash;&gt;<dependency><groupId>io.jsonwebtoken</groupId><artifactId>jjwt</artifactId><version>0.9.1</version><exclusions><exclusion><groupId>com.fasterxml.jackson.core</groupId><artifactId>jackson-databind</artifactId></exclusion></exclusions></dependency>--><!-- slf4j --><dependency><groupId>org.slf4j</groupId><artifactId>slf4j-api</artifactId><version>1.7.30</version></dependency><!-- lang3 --><dependency><groupId>org.apache.commons</groupId><artifactId>commons-lang3</artifactId><version>3.12.0</version></dependency><dependency><groupId>com.alibaba</groupId><artifactId>fastjson</artifactId><version>2.0.14</version></dependency><dependency><groupId>cn.hutool</groupId><artifactId>hutool-all</artifactId><version>5.8.7</version></dependency><dependency><groupId>org.projectlombok</groupId><artifactId>lombok</artifactId><version>1.18.20</version></dependency><dependency><groupId>com.squareup.okhttp3</groupId><artifactId>okhttp</artifactId><version>3.14.9</version></dependency><!-- 链路追踪组件 --><dependency><groupId>org.springframework.cloud</groupId><artifactId>spring-cloud-starter-sleuth</artifactId><version>2.1.0.RELEASE</version><exclusions><exclusion><artifactId>spring-boot-starter-aop</artifactId><groupId>org.springframework.boot</groupId></exclusion><exclusion><artifactId>spring-cloud-commons</artifactId><groupId>org.springframework.cloud</groupId></exclusion><exclusion><artifactId>spring-cloud-context</artifactId><groupId>org.springframework.cloud</groupId></exclusion><exclusion><artifactId>spring-cloud-starter</artifactId><groupId>org.springframework.cloud</groupId></exclusion></exclusions></dependency><dependency><groupId>org.springframework.cloud</groupId><artifactId>spring-cloud-starter-zipkin</artifactId><version>2.1.0.RELEASE</version><exclusions><exclusion><artifactId>spring-cloud-commons</artifactId><groupId>org.springframework.cloud</groupId></exclusion></exclusions></dependency><dependency><groupId>org.apache.commons</groupId><artifactId>commons-io</artifactId><version>1.3.2</version></dependency><!--<dependency><groupId>commons-io</groupId><artifactId>commons-io</artifactId><version>2.3</version></dependency>--></dependencies><build><finalName>data-monitor-user</finalName><plugins><plugin><groupId>org.apache.maven.plugins</groupId><artifactId>maven-resources-plugin</artifactId><version>3.2.0</version><configuration><encoding>utf-8</encoding><useDefaultDelimiters>true</useDefaultDelimiters></configuration></plugin><plugin><groupId>org.springframework.boot</groupId><artifactId>spring-boot-maven-plugin</artifactId></plugin></plugins><resources><resource><directory>src/main/java</directory><includes><include>**/*.xml</include></includes></resource><resource><directory>src/main/resources</directory><includes><include>**/*.*</include></includes></resource></resources></build>
</project>

4)网关bootstrap

server:port: 9001
spring:application:name: data-monitor-gatewayprofiles:active: testcloud:nacos:config:name: data-monitor-gatewayserver-addr: localhost:8848namespace: 85ca310b-80b9-4982-9174-d690c69f222cgroup: DEFAULT_GROUPfile-extension: ymldiscovery:server-addr: localhost:8848namespace: 85ca310b-80b9-4982-9174-d690c69f222cgroup: DEFAULT_GROUPservice: data-monitor-gatewayenabled: trueservice-registry:auto-registration:enabled: truegateway:routes:- id: data-monitor-useruri: http://localhost:9002#uri: lb://data-monitor-userpredicates:- Path=/gateway/**filters:- StripPrefix=1zipkin:base-url: http://localhost:9411/sender:#同步数据的方式type: websleuth:web:client:# 开启采集链路enabled: truesampler:probability: 1.0health:config:enabled: truesleuth:log:json:enabled: falseslf4j:enabled: false
#####################################################################################################
management:port: 9001security:enabled: falsehealth:defaults:enabled: falseendpoints:web:exposure:include: [ "prometheus","health" ]base-path: /

5)用户bootstrap

server:port: 9002
spring:application:name: data-monitor-userprofiles:active: testzipkin:base-url: http://localhost:9411/sender:#同步数据的方式type: websleuth:sampler:probability: 1.0cloud:nacos:config:name: data-monitor-userserver-addr: localhost:8848namespace: 85ca310b-80b9-4982-9174-d690c69f222cgroup: DEFAULT_GROUPfile-extension: ymldiscovery:server-addr: localhost:8848namespace: 85ca310b-80b9-4982-9174-d690c69f222cgroup: DEFAULT_GROUPservice: data-monitor-userservice-registry:auto-registration:enabled: truelogging:level:org.springframework.web.servlet.DispatcherServlet: debugorg.springframework.cloud.sleuth: debug

3.zipkin使用mysql存储

注意,没必要集成zipkin-server!!!

注意,没必要集成zipkin-server!!!

注意,没必要集成zipkin-server!!!

1)sql脚本 库名zipkin

CREATE TABLE IF NOT EXISTS zipkin_spans (`trace_id_high` BIGINT NOT NULL DEFAULT 0 COMMENT 'If non zero, this means the trace uses 128 bit traceIds instead of 64 bit',`trace_id` BIGINT NOT NULL,`id` BIGINT NOT NULL,`name` VARCHAR(255) NOT NULL,`parent_id` BIGINT,`debug` BIT(1),`start_ts` BIGINT COMMENT 'Span.timestamp(): epoch micros used for endTs query and to implement TTL',`duration` BIGINT COMMENT 'Span.duration(): micros used for minDuration and maxDuration query'
) ENGINE=InnoDB ROW_FORMAT=COMPRESSED CHARACTER SET=utf8 COLLATE utf8_general_ci;ALTER TABLE zipkin_spans ADD UNIQUE KEY(`trace_id_high`, `trace_id`, `id`) COMMENT 'ignore insert on duplicate';
ALTER TABLE zipkin_spans ADD INDEX(`trace_id_high`, `trace_id`, `id`) COMMENT 'for joining with zipkin_annotations';
ALTER TABLE zipkin_spans ADD INDEX(`trace_id_high`, `trace_id`) COMMENT 'for getTracesByIds';
ALTER TABLE zipkin_spans ADD INDEX(`name`) COMMENT 'for getTraces and getSpanNames';
ALTER TABLE zipkin_spans ADD INDEX(`start_ts`) COMMENT 'for getTraces ordering and range';CREATE TABLE IF NOT EXISTS zipkin_annotations (`trace_id_high` BIGINT NOT NULL DEFAULT 0 COMMENT 'If non zero, this means the trace uses 128 bit traceIds instead of 64 bit',`trace_id` BIGINT NOT NULL COMMENT 'coincides with zipkin_spans.trace_id',`span_id` BIGINT NOT NULL COMMENT 'coincides with zipkin_spans.id',`a_key` VARCHAR(255) NOT NULL COMMENT 'BinaryAnnotation.key or Annotation.value if type == -1',`a_value` BLOB COMMENT 'BinaryAnnotation.value(), which must be smaller than 64KB',`a_type` INT NOT NULL COMMENT 'BinaryAnnotation.type() or -1 if Annotation',`a_timestamp` BIGINT COMMENT 'Used to implement TTL; Annotation.timestamp or zipkin_spans.timestamp',`endpoint_ipv4` INT COMMENT 'Null when Binary/Annotation.endpoint is null',`endpoint_ipv6` BINARY(16) COMMENT 'Null when Binary/Annotation.endpoint is null, or no IPv6 address',`endpoint_port` SMALLINT COMMENT 'Null when Binary/Annotation.endpoint is null',`endpoint_service_name` VARCHAR(255) COMMENT 'Null when Binary/Annotation.endpoint is null'
) ENGINE=InnoDB ROW_FORMAT=COMPRESSED CHARACTER SET=utf8 COLLATE utf8_general_ci;ALTER TABLE zipkin_annotations ADD UNIQUE KEY(`trace_id_high`, `trace_id`, `span_id`, `a_key`, `a_timestamp`) COMMENT 'Ignore insert on duplicate';
ALTER TABLE zipkin_annotations ADD INDEX(`trace_id_high`, `trace_id`, `span_id`) COMMENT 'for joining with zipkin_spans';
ALTER TABLE zipkin_annotations ADD INDEX(`trace_id_high`, `trace_id`) COMMENT 'for getTraces/ByIds';
ALTER TABLE zipkin_annotations ADD INDEX(`endpoint_service_name`) COMMENT 'for getTraces and getServiceNames';
ALTER TABLE zipkin_annotations ADD INDEX(`a_type`) COMMENT 'for getTraces and autocomplete values';
ALTER TABLE zipkin_annotations ADD INDEX(`a_key`) COMMENT 'for getTraces and autocomplete values';
ALTER TABLE zipkin_annotations ADD INDEX(`trace_id`, `span_id`, `a_key`) COMMENT 'for dependencies job';CREATE TABLE IF NOT EXISTS zipkin_dependencies (`day` DATE NOT NULL,`parent` VARCHAR(255) NOT NULL,`child` VARCHAR(255) NOT NULL,`call_count` BIGINT,`error_count` BIGINT
) ENGINE=InnoDB ROW_FORMAT=COMPRESSED CHARACTER SET=utf8 COLLATE utf8_general_ci;ALTER TABLE zipkin_dependencies ADD UNIQUE KEY(`day`, `parent`, `child`);

2)、修改zipkin启动命令

java -jar zipkin-server-2.12.9-exec.jar --STORAGE_TYPE=mysql --MYSQL_HOST=localhost --MYSQL_TCP_PORT=3306 --MYSQL_DB=zipkin --MYSQL_USER=root --MYSQL_PASS=root

重启zipkin,执行,服务调用后数据入库。

 

写文档是方便大家用的,不要抄来抄去,却这少那的,请勿互卷,做程序员要认真。

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.luyixian.cn/news_show_23322.aspx

如若内容造成侵权/违法违规/事实不符,请联系dt猫网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

如何在贵金属白银现货走势分析中积累经验?

贵金属白银现货走势分析中&#xff0c;只有一种东西是只可意会不可言传的&#xff0c;那就是经验。很多人会有这样的经历&#xff0c;为什么大家学习的是同样的方法&#xff0c; 他能够赚钱&#xff0c;而我不能够赚钱呢&#xff1f;这其实就是经验所致。在贵金属白银现货走势分…

猿创征文|我这样看国产数据库TBase

文章目录一、云原生数据库二、功能介绍三、适用场景一、云原生数据库 随着云业务形态的诞生&#xff0c;这两年在传统的数据库架构基础上&#xff0c;产生一种比较流行的新架构–云原生架构&#xff0c;日志即数据库。 它会把数据库的业务逻辑沉到底层的存储节点里面去&…

操作系统导论习题解答(41. Fast File System (FFS))

Locality and The Fast File System "old UNIX file system" looked like this:super block(S): contains information about the entire file system inode region: contains all the inodes for the file system data region: contains user data 1. The Problem…

UE4 /UE5 PC/安卓优化

一、概述 UE4/UE5场景中的资源越多&#xff0c;消耗的内存就越大&#xff0c;就会越卡顿。这里教大家如何进行场景优化&#xff0c;来减少内存&#xff0c;使得场景更加流畅。 二、模型优化 2.1、使用3Dmax或者Maya制作的模型&#xff0c;面数最好不要太多&#xff0c;虽然UE4…

国内首家车身区域控制器量产 电子电气架构进入中央集中式3.0阶段

从功能独立的分布式架构&#xff0c;到功能集成的域控制架构&#xff0c;如今整车电子电气架构正在加速跨入集中式电子电气架构3.0阶段。 在中央集中式架构中&#xff0c;算力逐渐向中央集中&#xff0c;多个域控制器继续融合最终形成1个中央计算平台N个区域控制器的终极布局&…

操作系统导论习题解答(29. Locked Data Structures)

Lock-based Concurrent Data Structures 带着问题:给定一个数据结构,如何给其添加锁使其拥有正确性和高效性? 1. Concurrent Counters 1.1 Simple But Not Scalable上述代码满足了正确性,但是对于性能,我们一无所知。为了了解性能优劣,做了一个基准测试,如下所示(preci…

零时科技 || Rabby Swap合约遭受攻击事件详解

0x1 背景 2022年10月12日&#xff0c;Rabby Swap合约中存在疑似任意用户资产转移漏洞。Rabby Swap官方表示&#xff0c;如果有使用&#xff0c;请撤销所有链上所有现有的 Rabby Swap 批准。对于没有使用过 Swap 的人来说&#xff0c;钱包安全且不受影响。零时科技安全团队及时…

RxJS - interval、take制作倒计时效果

获取验证码按钮功能&#xff1a; 引入所需的RxJS的方法&#xff0c;定义变量&#xff1a; import { interval } from rxjs; import { take } from rxjs/operators; buttonText 获取验证码; isDisabled false; // 按钮是否灰显 seconds 60; // 倒计时开始时间编写点击按钮…

Typora+PicGo+七牛云实现图片上传存储

1. 注册七牛云 首先&#xff0c;需要在七牛云官网注册账号并进行实名认证&#xff0c;注册----->申请个人账户----->填写注册信息----->实名认证&#xff0c;基本上就是这个步骤&#xff0c;不做细说&#xff0c;相信难不到聪明的你 2. 配置存储空间 2.1 新建空间 …

实训十二:路由器静态路由配置

一、 实验目的 理解路由表掌握静态路由的配置 二、 应用环境 在小规模环境里&#xff0c;静态路由是最佳的选择静态路由开销小&#xff0c;但不灵活&#xff0c;适用于相对稳定的网络 三、 实验设备 1、DCR-2655 三台 2、网线&#xff08;交叉线&#xff09; 四条 四、 实验拓扑…

操作系统导论习题解答(16. Segmentation)

Segmentation 1. Segmentation: Generalized Base/Bounds我们可以看一下(Figure 16.1),尽管每个CPU都有一对硬件寄存器(base register和bounds register),但是还是不可避免的会产生内存浪费(阴影部分表示未被使用)。为了解决这个问题,就引入了segmentation:既然每一…

植物大战 string——C++

“朝朝暮暮” 猛戳订阅&#x1f341;&#x1f341; &#x1f449; [C详解专栏] &#x1f448; &#x1f341;&#x1f341; 这里是目录一、编码1.ASCII码2.unicode编码3.gbk二、string的使用1.构造函数无参构造函数string()常量字符串构造string(const char* s)拷贝构造string(…

风控场景中值得收藏的10个经典算法模型的实操与应用

在风控领域中&#xff0c;我们也经常接触到回归模型场景&#xff0c;常见的例如产品额度定价、客户价值评估、信息指数分析等。针对回归模型&#xff0c;建模的目标变量是连续型&#xff0c;这是在特征数据上与分类模型最明显的区别。在模型具体实现的过程中&#xff0c;采用的…

Linux 学习 -- shell中字串的一些用法

1、简单用法&#xff1a;返回变量的内容 命令 &#xff1a; ${变量} 或者 $变量 2、返回变量的长度 命令&#xff1a;${#变量} // 返回变量长度&#xff0c;字符长度 3、返回变量start数值之后的字符,包括start 命令&#xff1a;${变量:start} 4、提取start之…

Docker 基础及安装

更多内容&#xff0c;前往 IT-BLOG 一、简介 Docker是基于Go语言实现的云开源项目。主要目标是 “Build&#xff0c;Ship and Run Any App,Anywhere”&#xff0c;也就是通过对应用组件的封装、分发、部署、运行等生命周期的管理&#xff0c;使用户的APP&#xff08;Web应用或…

微信壁纸小程序(SpringBoot后台V1.3.0发布)

前篇&#xff1a;微信壁纸小程序V1.2.0&#xff08;自带后台上传图片&#xff09;_热衷与自由的博客-CSDN博客_手机壁纸api 如果你还不知道小程序的前身&#xff0c;可以看看前篇哦~ 上次9月末小编发布了V1.2.0版本&#xff0c;完成了后台的基本功能&#xff08;上传壁纸、头像…

操作系统导论习题解答(8. Multi-level Feedback)

0. 文件地址 Homework 1. MLFQ: Basic Rules2. Attempt #1: How To Change Priority2.1 Example 1: A Single Long-Running Job2.2 Example 2: Along Came A Short Job In this example, there are two jobs: A, which is a long-running CPU-intensive job, and B, which is …

基于Linux的Nginx安装

文章目录基于Linux的Nginx安装1、Nginx用户设置1.1 创建新用户&#xff08;注意权限问题&#xff1a;切换为root用户&#xff09;1.2 添加新用户nginx&#xff0c;并设置相关信息&#xff08;一直回车默认即可&#xff09;1.3 退出当前用户&#xff0c;登录nginx用户&#xff0…

T278789 滑冰

(芭芭拉太可爱了叭......) 题目描述 在企鹅国,企鹅们是通过滑冰出行的。每次滑冰需要选择一个营地作为起点,一个营地作为终点,然后从营地 \(A(a_x,a_y)\) 滑到营地 \(B(b_x,b_y)\) 需要的时间是 \(min \{|a_x-b_x |,|a_y-b_y | \}\)。 现在企鹅豆豆在 \(1\) 号营地,他需要…

利用workflows工作流Actions自动部署Vue项目Deploy to GitHub Pages

文档 https://github.com/marketplace/actions/deploy-to-github-pageshttps://cli.vuejs.org/zh/guide/deployment.html#github-pages 目录第一步&#xff1a;配置workflows第二步&#xff1a;开启GitHub Pages使用GitHub Pages部署一个在线Demo&#xff0c;每次更新代码都要…