建设网站的准备/域名权重是什么意思
ElasticSearch 8.9.0 开发模式安装
JDK安装
官方提供版本与JDK支持关系:https://www.elastic.co/cn/support/matrix#matrix_jvm
我们安装Elasticsearch 8.9.x,看到支持的最低JDK版本是17。
JDK(Windows/Mac含M1/M2 Arm原生JDK)安装,附各个版本JDK下载链接:https://es-cn.blog.csdn.net/article/details/126861940
Oracle JDK 官方下载:https://download.oracle.com/java/17/latest/jdk-17_windows-x64_bin.exe
按照默认设置进行安装。
安装之后我们默认的JDK版本会变成17,这是因为安装过程自动添加了环境变量。在Path环境变量中清理如下两个环境变量(一般在最上面,移动到下面也可以):
- C:\Program Files\Common Files\Oracle\Java\javapath
- C:\Program Files (x86)\Common Files\Oracle\Java\javapath
新建环境变量:
变量名 | 变量值 |
---|---|
ES_JAVA_HOME | C:\Program Files\Java\jdk-17 |
ElasticSearch下载安装
ElasticSearch下载页面:https://www.elastic.co/cn/downloads/elasticsearch
ElasticSearch 8.9.0 版本下载:https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-8.9.0-windows-x86_64.zip
注意:路径中不能存在空格
解压,修改config目录下elasticsearch.yml
# ======================== Elasticsearch Configuration =========================
#
# NOTE: Elasticsearch comes with reasonable defaults for most settings.
# Before you set out to tweak and tune the configuration, make sure you
# understand what are you trying to accomplish and the consequences.
#
# The primary way of configuring a node is via this file. This template lists
# the most important settings you may want to configure for a production cluster.
#
# Please consult the documentation for further information on configuration options:
# https://www.elastic.co/guide/en/elasticsearch/reference/index.html
#
# ---------------------------------- Cluster -----------------------------------
# 代表一个集群,集群中有多个节点,其中有一个为主节点,这个主节点是可以通过选举产生的,主从节点是对于集群内部来说的
# Elasticsearch的一个概念就是去中心化,字面上理解就是无中心节点,这是对于集群外部来说的,因为从外部来看Elasticsearch集群,在逻辑上是个整体,你与任何一个节点的通信和与整个Elasticsearch集群通信是等价的。
# cluster.name可以确定你的集群名称,当你的elasticsearch集群在同一个网段中elasticsearch会自动的找到具有相同cluster.name的Elasticsearch服务。所以当同一个网段具有多个Elasticsearch集群时cluster.name就成为同一个集群的标识。
# Use a descriptive name for your cluster:
# 集群名称,默认是elasticsearch
cluster.name: elasticsearch
#
# ------------------------------------ Node ------------------------------------
#
# Use a descriptive name for the node:
# 节点名称同理,可自动生成也可手动配置.
node.name: es-node
#
# Add custom attributes to the node:
# 每个节点都可以定义一些与之关联的通用属性,用于后期集群进行碎片分配时的过滤
#node.attr.rack: r1
#
# ----------------------------------- Paths ------------------------------------
#
# Path to directory where to store the data (separate multiple locations by comma):
# 可以指定Elasticsearch的数据存储目录,默认存储在es_home/data目录下
#path.data: /path/to/data
#
# Path to log files:
# 可以指定Elasticsearch的日志存储目录,默认存储在es_home/logs目录下
#path.logs: /path/to/logs
#
# ----------------------------------- Memory -----------------------------------
#
# Lock the memory on startup:
# 当JVM开始写入交换空间时(swapping)ElasticSearch性能会低下,你应该保证它不会写入交换空间
# 锁定物理内存地址,防止elasticsearch内存被交换出去,也就是避免elasticsearch使用swap交换分区
bootstrap.memory_lock: true
#
# 确保ES_HEAP_SIZE参数设置为系统可用内存的一半左右
# Make sure that the heap size is set to about half the memory available
# on the system and that the owner of the process is allowed to use this
# limit.# 确保 ES_MIN_MEM 和 ES_MAX_MEM 环境变量设置为相同的值,以及机器有足够的内存分配给Elasticsearch
# 注意:内存也不是越大越好,一般64位机器,最大分配内存别才超过32G #
# 当系统进行内存交换的时候,elasticsearch的性能很差
# Elasticsearch performs poorly when the system is swapping the memory.
#
# ---------------------------------- Network -----------------------------------
#
# By default Elasticsearch is only accessible on localhost. Set a different
# address here to expose this node on the network:
# 为Elasticsearch设置ip绑定,默认是127.0.0.1,也就是默认只能通过127.0.0.1 或者localhost才能访问
network.host: 127.0.0.1
#
# By default Elasticsearch listens for HTTP traffic on the first free port it
# finds starting at 9200. Set a specific HTTP port here:
# 为Elasticsearch设置自定义端口,默认是9200
http.port: 9200
#
# For more information, consult the network module documentation.
#
# --------------------------------- Discovery ----------------------------------
#
# Pass an initial list of hosts to perform discovery when this node is started:
# The default list of hosts is ["127.0.0.1", "[::1]"]
#
#discovery.seed_hosts: ["host1", "host2"]
#
# Bootstrap the cluster using an initial set of master-eligible nodes:
#
#cluster.initial_master_nodes: ["node-1", "node-2"]
#
# For more information, consult the discovery and cluster formation module documentation.
#
# ---------------------------------- Various -----------------------------------
#
# Allow wildcard deletion of indices:
#
#action.destructive_requires_name: false
# ---------------------------------- Xpack -----------------------------------
xpack.security.enabled: false
回到bin目录下,双击elasticsearch.bat启动
启动会占用系统物理内存的一半,建议根据实际情况调整jvm.options文件-Xms、-Xmx的值。
验证
访问:http://localhost:9200
ElasticSearch 8 默认启动Security,这对新手学习很不友好,实际上违背了Elastic官方设置开发模式的初衷,安全固然重要,但是没必要把门槛设置这么高。
参考:https://es-cn.blog.csdn.net/article/details/123936913
ElasticSearch目录结构
目录名称 | 描述 |
---|---|
bin | 可执行脚本文件,包括启动ElasticSearch服务、插件管理、函数命令等。 |
config | 配置文件目录,如ElasticSearch配置、角色配置、jvm配置等。 |
jdk | 7.x以后特有,自带的Java环境,8.x版本自带jdk 17 |
lib | ElasticSearch所依赖的Java库 |
logs | 默认的日志文件存储路径,生产环境要求必须修改 |
modules | 包含所有的ElasticSearch模块,如Cluster、Discovery、Indices等。 |
plugins | 已经安装的插件的目录 |
data | 默认的数据存放目录,包含节点、分片、索引、文档的所有数据,生产环境要求必须修改 |
SkyWalking
SkyWalking下载安装
SkyWalking官网:https://skywalking.apache.org/
Application performance monitor tool for distributed systems, especially designed for microservices, cloud native and container-based (Kubernetes) architectures.
SkyWalking 9.5.0 版本下载:https://dlcdn.apache.org/skywalking/9.5.0/apache-skywalking-apm-9.5.0.tar.gz
解压缩
注意:路径中不能存在空格
修改bin目录下startup.bat文件中
@REM
@REM Licensed to the Apache Software Foundation (ASF) under one or more
@REM contributor license agreements. See the NOTICE file distributed with
@REM this work for additional information regarding copyright ownership.
@REM The ASF licenses this file to You under the Apache License, Version 2.0
@REM (the "License"); you may not use this file except in compliance with
@REM the License. You may obtain a copy of the License at
@REM
@REM http://www.apache.org/licenses/LICENSE-2.0
@REM
@REM Unless required by applicable law or agreed to in writing, software
@REM distributed under the License is distributed on an "AS IS" BASIS,
@REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@REM See the License for the specific language governing permissions and
@REM limitations under the License.@echo offsetlocal
SET JAVA_HOME=%ES_JAVA_HOME%
call "%~dp0"\oapService.bat start
call "%~dp0"\webappService.bat start
endlocal
修改webapp目录下application.yml文件
serverPort: ${SW_SERVER_PORT:-8080}
修改为:
serverPort: ${SW_SERVER_PORT:-8888}
验证
访问:http://localhost:8888/
SkyWalking默认是使用H2作为存储的,我们修改为ElasticSearch。
修改config目录下application.yml文件
storage:selector: ${SW_STORAGE:elasticsearch}elasticsearch:namespace: ${SW_NAMESPACE:"elasticsearch"}clusterNodes: ${SW_STORAGE_ES_CLUSTER_NODES:localhost:9200}protocol: ${SW_STORAGE_ES_HTTP_PROTOCOL:"http"}connectTimeout: ${SW_STORAGE_ES_CONNECT_TIMEOUT:3000}socketTimeout: ${SW_STORAGE_ES_SOCKET_TIMEOUT:30000}responseTimeout: ${SW_STORAGE_ES_RESPONSE_TIMEOUT:15000}numHttpClientThread: ${SW_STORAGE_ES_NUM_HTTP_CLIENT_THREAD:0}user: ${SW_ES_USER:""}password: ${SW_ES_PASSWORD:""}
# trustStorePath: ${SW_STORAGE_ES_SSL_JKS_PATH:""}
# trustStorePass: ${SW_STORAGE_ES_SSL_JKS_PASS:""}secretsManagementFile: ${SW_ES_SECRETS_MANAGEMENT_FILE:""} # Secrets management file in the properties format includes the username, password, which are managed by 3rd party tool.dayStep: ${SW_STORAGE_DAY_STEP:1} # Represent the number of days in the one minute/hour/day index.indexShardsNumber: ${SW_STORAGE_ES_INDEX_SHARDS_NUMBER:1} # Shard number of new indexesindexReplicasNumber: ${SW_STORAGE_ES_INDEX_REPLICAS_NUMBER:1} # Replicas number of new indexes# Specify the settings for each index individually.# If configured, this setting has the highest priority and overrides the generic settings.specificIndexSettings: ${SW_STORAGE_ES_SPECIFIC_INDEX_SETTINGS:""}# Super data set has been defined in the codes, such as trace segments.The following 3 config would be improve es performance when storage super size data in es.superDatasetDayStep: ${SW_STORAGE_ES_SUPER_DATASET_DAY_STEP:-1} # Represent the number of days in the super size dataset record index, the default value is the same as dayStep when the value is less than 0superDatasetIndexShardsFactor: ${SW_STORAGE_ES_SUPER_DATASET_INDEX_SHARDS_FACTOR:5} # This factor provides more shards for the super data set, shards number = indexShardsNumber * superDatasetIndexShardsFactor. Also, this factor effects Zipkin traces.superDatasetIndexReplicasNumber: ${SW_STORAGE_ES_SUPER_DATASET_INDEX_REPLICAS_NUMBER:0} # Represent the replicas number in the super size dataset record index, the default value is 0.indexTemplateOrder: ${SW_STORAGE_ES_INDEX_TEMPLATE_ORDER:0} # the order of index templatebulkActions: ${SW_STORAGE_ES_BULK_ACTIONS:5000} # Execute the async bulk record data every ${SW_STORAGE_ES_BULK_ACTIONS} requestsbatchOfBytes: ${SW_STORAGE_ES_BATCH_OF_BYTES:10485760} # A threshold to control the max body size of ElasticSearch Bulk flush.# flush the bulk every 5 seconds whatever the number of requestsflushInterval: ${SW_STORAGE_ES_FLUSH_INTERVAL:5}concurrentRequests: ${SW_STORAGE_ES_CONCURRENT_REQUESTS:2} # the number of concurrent requestsresultWindowMaxSize: ${SW_STORAGE_ES_QUERY_MAX_WINDOW_SIZE:10000}metadataQueryMaxSize: ${SW_STORAGE_ES_QUERY_MAX_SIZE:10000}scrollingBatchSize: ${SW_STORAGE_ES_SCROLLING_BATCH_SIZE:5000}segmentQueryMaxSize: ${SW_STORAGE_ES_QUERY_SEGMENT_SIZE:200}profileTaskQueryMaxSize: ${SW_STORAGE_ES_QUERY_PROFILE_TASK_SIZE:200}profileDataQueryBatchSize: ${SW_STORAGE_ES_QUERY_PROFILE_DATA_BATCH_SIZE:100}oapAnalyzer: ${SW_STORAGE_ES_OAP_ANALYZER:"{\"analyzer\":{\"oap_analyzer\":{\"type\":\"stop\"}}}"} # the oap analyzer.oapLogAnalyzer: ${SW_STORAGE_ES_OAP_LOG_ANALYZER:"{\"analyzer\":{\"oap_log_analyzer\":{\"type\":\"standard\"}}}"} # the oap log analyzer. It could be customized by the ES analyzer configuration to support more language log formats, such as Chinese log, Japanese log and etc.advanced: ${SW_STORAGE_ES_ADVANCED:""}# Enable shard metrics and records indices into multi-physical indices, one index template per metric/meter aggregation function or record.logicSharding: ${SW_STORAGE_ES_LOGIC_SHARDING:false}# Custom routing can reduce the impact of searches. Instead of having to fan out a search request to all the shards in an index, the request can be sent to just the shard that matches the specific routing value (or values).enableCustomRouting: ${SW_STORAGE_ES_ENABLE_CUSTOM_ROUTING:false}
相关文章:

开发者本地搭建性能监测工具(Windows)
ElasticSearch 8.9.0 开发模式安装 JDK安装 官方提供版本与JDK支持关系:https://www.elastic.co/cn/support/matrix#matrix_jvm 我们安装Elasticsearch 8.9.x,看到支持的最低JDK版本是17。 JDK(Windows/Mac含M1/M2 Arm原生JDK)…...

嵌入式Linux开发实操(八):UART串口开发
串口可以说是非常好用的一个接口,它同USB、CAN、I2C、SPI等接口一样,为SOC/MCU构建了丰富的接口功能。那么在嵌入式linux中又是如何搭建和使用UART接口的呢? 一、Console接口即ttyS0 ttyS0通常做为u-boot(bootloader的一种,像是Windows的BIOS),它需要一个交互界面,一般…...

公告:微信小程序备案期限官方要求
备案期限要求 1、若微信小程序未上架,自2023年9月1日起,微信小程序须完成备案后才可上架,备案时间1-20日不等; 2、若微信小程序已上架,请于2024年3月31日前完成备案,逾期未完成备案,平台将按照…...

cesium中获取高度的误区
this.ellipsoid viewer.scene.globe.ellipsoid; var cartesian viewer.camera.pickEllipsoid(e.position, this.ellipsoid);if(cartesian){// 苗卡尔椭球体的三维坐标 转 地图坐标(弧度)var cartographic viewer.scene.globe.ellipsoid.cartesianToCa…...

基于Centos:服务器基础环境安装: JDK、Maven、Python、Go、Docker、K8s
创建用户 useradd dev groupadd op chown -R :op /opt chmod -R 770 /opt usermod -aG op devJDK8 yum install -y java-1.8.0-openjdk-devel echo export JAVA_HOME/usr/lib/jvm/java-1.8.0/>> /etc/profilesource /etc/profileJDK11 yum install -y java-11-openjd…...

Elasticsearch的数据删除策略只能触发一次
在Elasticsearch中,可以使用Index Lifecycle Management(ILM)来设置删除数据的保留时长。ILM是Elasticsearch的一项功能,用于管理索引的生命周期,包括数据保留、备份、归档等操作。 要设置删除数据的保留时长…...

Open3D 最小二乘拟合空间直线(方法一)
目录 一、算法原理1、空间直线2、最小二乘法拟合二、代码实现三、结果展示本文由CSDN点云侠原创,原文链接。如果你不是在点云侠的博客中看到该文章,那么此处便是不要脸的爬虫。 一、算法原理 1、空间直线 x −...

解决uniapp 二次登陆 登录页是首页时,登录页闪现问题
pages.json文件中,pages数组中第一项是登录页,用户第一次登录后,存储登录状态,以后再进入应用时,自动登录跳转至首页。 但是自动登录跳转至首页时,登录页总是会闪现一下。 第一步:manifest.js…...

如何快速制作一个房地产电子传单?
在如今高度数字化的时代,电子传单成为了宣传推广的一种重要方式。下面将介绍如何利用乔拓云平台快速制作一个房地产电子传单。 第一步,找一个可靠的第三方制作平台/工具,比如乔拓云平台。乔拓云平台是一个功能强大、简单易用的电子传单制作工…...

golang云原生项目之:etcd服务注册与发现
服务注册与发现:ETCD 1直接调包 kitex-contrib: 上面有实现的案例,直接cv。下面是具体的理解 2 相关概念 EtcdResolver: etcd resolver是一种DNS解析器,用于将域名转换为etcd集群中的具体地址,以便应用程序可以与et…...

arm:day4
1. 实现三盏灯的点亮 .text .global _start_start: led1初始化函数LED_INIT: 1 通过RCC_AHB4_ENSETR寄存器,设置GPIOE F组控制器使能 0x50000A28[5:4]1ldr r0,0X50000A28ldr r1,[r0]orr r1,r1,#(0X3<<4)str r1,[r0] 2.1 通过GPIOE_MODER寄存器,…...

flutter 常见的状态管理器
flutter 常见的状态管理器 前言一、Provider二、Bloc三、Redux四、GetX总结 前言 当我们构建复杂的移动应用时,有效的状态管理是至关重要的,因为应用的不同部分可能需要共享数据、相应用户交互并保持一致的状态。Flutter 中有多种状态管理解决方案&#…...

Kotlin的Map
在 Kotlin 中,Map 是一种键值对的集合数据结构,用于存储一组关联的键和值。Kotlin 标准库提供了 Map 接口和多种实现类,使得操作和处理键值对数据更加方便。下面详细描述 Kotlin 的 Map 的用法: 创建 Map Kotlin 提供了几种方式…...

STM32 串口复习
按数据通信方式分类: 串行通信:数据逐位按顺序依次传输。传输速率较低,抗干扰能力较强,通信距离较长,I/O资源占用较少,成本较低。并行通信:数据各位通过多条线同时传输。 按数据传输方向分类&…...
VScode替换cmd powershell为git bash 终端,并设置为默认
效果图 步骤 1. 解决VScode缺少git bash的问题_failed to start bash - is git-bash.exe on the syst_Rudon滨海渔村的博客-CSDN博客效果解决步骤找到git安装目录下的/bin/bash.exe,复制其绝对路径,例如D:\Program Files\Git\bin\bash.exe把路径的右斜…...

网络基础(一)桥接网络
网络基础知识 桥接网络 桥接网络是一种网络设计技术,其目的是将两个或多个网络段连接在一起,使它们在逻辑上表现为单个网络。这通过使用网络桥来实现,网络桥工作在数据链路层(第2层),只关心MAC地址&#…...

C#程序变量统一管理例子 - 开源研究系列文章
今天讲讲关于C#应用程序中使用到的变量的统一管理的代码例子。 我们知道,在C#里使用变量,除了private私有变量外,程序中使用到的公共变量就需要进行统一的存放和管理。这里笔者使用到的公共变量管理库划分为:1)窗体;2)…...

信息熵,信息增益,增益率的理解
西瓜数据集D如下: 编号色泽根蒂敲声纹理脐部触感好瓜1青绿蜷缩浊响清晰凹陷硬滑是2乌黑蜷缩沉闷清晰凹陷硬滑是3乌黑蜷缩浊响清晰凹陷硬滑是4青绿蜷缩沉闷清晰凹陷硬滑是5浅白蜷缩浊响清晰凹陷硬滑是6青绿稍蜷浊响清晰稍凹软粘是7乌黑稍蜷浊响稍糊稍凹软粘是8乌黑稍蜷浊响清晰…...

二级MySQL(一)——基本概念与方法
数据库系统的核心是【数据库管理系统】 E-R图提供了表示信息世界中的方法,主要有实体、属性和【联系】 E-R图是数据库设计的工具之一,一般适用于建立数据库的【概念模型】 将E-R图转换到关系模式时,实体与联系都可以表示成【关系】 关系数…...

13 Web全栈 pnpm
什么是pnpm? 可以理解成performant npm缩写 速度快、节省磁盘空间的软件包管理器 特点 快速- pnpm比其他包管理器快2倍高效- node_modules中的文件链接自特定的内容寻址存储库支持monorepos- 内置支持单仓多包严格- pnpm默认创建了一个非平铺的node_modules 因此代…...

回归预测 | MATLAB实现CSO-BP布谷鸟优化算法优化BP神经网络多输入单输出回归预测(多指标,多图)
回归预测 | MATLAB实现CSO-BP布谷鸟优化算法优化BP神经网络多输入单输出回归预测(多指标,多图) 目录 回归预测 | MATLAB实现CSO-BP布谷鸟优化算法优化BP神经网络多输入单输出回归预测(多指标,多图)效果一览…...

JavaScript中的事件冒泡和事件捕获机制
聚沙成塔每天进步一点点 ⭐ 专栏简介⭐ 事件冒泡和事件捕获机制⭐ 事件冒泡(Event Bubbling)⭐ 事件捕获(Event Capturing)⭐ 停止事件传播⭐ 写在最后 ⭐ 专栏简介 前端入门之旅:探索Web开发的奇妙世界 记得点击上方或…...

秋招面经——结合各方面试经验
Mysql mysql事务 共享锁与排他锁 共享锁:允许一个事务去读一行,阻止其他事务获得相同数据集的排他锁。(读都允许读,但我在读不允许你去改) 排他锁:允许一个事务去读一行,阻止其他事务获得相同…...

Python random模块用法整理
随机数在计算机科学领域扮演着重要的角色,用于模拟真实世界的随机性、数据生成、密码学等多个领域。Python 中的 random 模块提供了丰富的随机数生成功能,本文整理了 random 模块的使用。 文章目录 Python random 模块注意事项Python random 模块的内置…...

【Redis从头学-5】Redis中的List数据类型实战场景之天猫热销榜单
🧑💻作者名称:DaenCode 🎤作者简介:啥技术都喜欢捣鼓捣鼓,喜欢分享技术、经验、生活。 😎人生感悟:尝尽人生百味,方知世间冷暖。 📖所属专栏:Re…...

基于Python的HTTP代理爬虫开发初探
前言 随着互联网的发展,爬虫技术已经成为了信息采集、数据分析的重要手段。然而在进行爬虫开发的过程中,由于个人或机构的目的不同,也会面临一些访问限制或者防护措施。这时候,使用HTTP代理爬虫可以有效地解决这些问题࿰…...

时序预测 | MATLAB实现WOA-CNN-LSTM鲸鱼算法优化卷积长短期记忆神经网络时间序列预测
时序预测 | MATLAB实现WOA-CNN-LSTM鲸鱼算法优化卷积长短期记忆神经网络时间序列预测 目录 时序预测 | MATLAB实现WOA-CNN-LSTM鲸鱼算法优化卷积长短期记忆神经网络时间序列预测预测效果基本介绍模型描述程序设计学习总结参考资料 预测效果 基本介绍 时序预测 | MATLAB实现WOA-…...

每日一题之二进制中1的个数
二进制中1的个数 问题描述: 输入一个整数 n ,输出该数 32 位二进制表示中 1 的个数。其中负数用补码表示。 科普一下有符号数的三种表示:原码、反码和补码,可能有时候遗忘了。 真值:带有符号位的机器数(一…...

8.17校招 内推 面经
绿泡泡: neituijunsir 交流裙,内推/实习/校招汇总表格 1、校招 | 腾讯2024校园招聘全面启动(内推) 校招 | 腾讯2024校园招聘全面启动(内推) 2、校招 | 大华股份2024届全球校园招聘正式启动(内推) 校招 | 大华股份2024届全球校园招聘正式启动(内推) …...

VScode搭建Opencv(C++开发环境)
VScode配置Opencv 一、 软件版本二 、下载软件2.1 MinGw下载2.2 Cmake下载2.3 Opencv下载 三、编译3.1 cmake-gui3.2 make3.3 install 四、 VScode配置4.1 launch.json4.2 c_cpp_properties.json4.3 tasks.json 五、测试 一、 软件版本 cmake :cmake-3.27.2-windows-x86_64 Mi…...