核心方法:SEO通用排名优化手法
优采云 发布时间: 2022-12-22 08:14核心方法:SEO通用排名优化手法
不知道为什么,百度对站点的首页非常重视。 一般来说,首页是最容易获得排名和流量的。 当然,这也与站长把SEO重点放在首页有关,但不可否认的是,百度在首页上有非常大的优势。 但是,其他搜索引擎一视同仁的特点尤为明显。 无论是首页还是内页,在被其他搜索引擎认可方面都具有相同的优势。
3、外链的意义和页面的相关性不同
近年来,百度对外链的重视程度不断减弱,尤其是那些垃圾外链,几乎成为站内优化的绊脚石,所以很多站长在外链建设上更加慎重,要求从数量到质量也被百度改了大半。 百度更注重网站内部内容的质量。 好的高质量内容的网站才是它喜欢的网站。 它不太关心外部链接的数量。 外部链接的作用在减弱,但页面元素的相关性在发挥更强的作用。 如果你想让百度更加信任你的网站,那么目标关键词一定要出现在正确的地方。
4.不同的排名变化
百度算法的小幅调整可能会改变某些网站的排名。 通常,百度的排名经常波动很大。 也许有一天当你打开站长工具查询时,发现网站各项指标都有所提升; 或者突然之间一切都在一夜之间消失了。 这种情况很常见,可能是因为百度的一个小调整,也可能是你之前的优化做得很好。 但是,这种情况出现在其他搜索引擎上的概率很小。 一般来说,其他搜索引擎对网站排名的处理都是循序渐进的,不可能突然上升或下降。 SEO优化,当然,如果你作弊厉害,那一切皆有可能!
5、网站更新的重视程度不同
如果你想让百度给你的站点足够的信任,你需要非常注意保持更新频率和更新内容的原创性。 因为一个不经常更新的网站,基本不会被百度喜欢,所以才会有好的排名,所以SEO新手还是老老实实更新文章吧! 百度非常重视网站的更新频率,我们的定期更新可以有效提高您的搜索引擎排名。 一般来说,不管我们优化什么搜索引擎,只要我们的SEO优化正规合法,符合搜索引擎的要求,那么无论在哪个搜索引擎上,我们的网站都会有一个好的排名。 不同的搜索引擎SEO优化之间的差异非常小。
操作方法:详解Opentelemetry Collector采集器
Binary使用proto3编码标准,必须在请求头中标明Content-Type: application/x-protobuf
JSON格式使用proto3标准定义的JSON Mapping来处理Protobuf与JSON的映射关系。
OTLP/gRPC
普通请求:客户端与服务端建立连接后,客户端可以不断向服务端发送请求,服务端会一一响应。 并发请求:客户端可以在服务器响应之前发送下一个请求以增加并发量。
Collector采集器简介
OpenTelemetry 提供了一个开源的 Collector 来报告、采集、处理和输出客户端数据。 otel采集器是一个支持多种协议和数据源的“通用”采集器。 可以说他可以直接支持很多你能想到的数据源。
otel采集器使用golang实现php,目前写文章的时候已经发布了rc 1.0.0版本。 Collector分为两个项目opentelemetry-collector和opentelemetry-collector-contrib。 opentelemetry-collector是核心项目,实现了collector的基本机制和一些基础组件,而opentelemetry-collector-contrib会有大量的组件,这些组件因为各种原因不方便直接集成到核心collector中,所以单独构建了一个项目来集成这些组件。 我们后续的collector功能介绍和验证会基于opentelemetry-collector-contrib。
采集器用途
otel collector的构成很明确,分为:
接收者
处理器
出口商
延期
服务
整个配置文件的样例如下:
receivers:
otlp:
protocols:
grpc:
http:
exporters:
jaeger:
endpoint: localhost:14250
tls:
insecure: true
logging:
loglevel: debug
processors:
batch:
extensions:
health_check:
pprof:
zpages:
service:
extensions: [pprof, zpages, health_check]
pipelines:
traces:
receivers: [otlp]
exporters: [jaeger, logging]
processors: [batch]
这个配置是我本地测试用的一个配置。 这个配置非常简单。 它接收otlp http/grpc的上报数据,进行批处理,然后输出到控制台log和jaeger。 在我们配置好各种数据源和插件之后,我们来配置流水线中使用的数据源和插件。
接收者
Receiver是指接收者,即采集器接收到的数据源的形式。 Receiver可以支持多种数据源,也可以支持pull和push模式。
receivers:
# Data sources: logs
fluentforward:
endpoint: 0.0.0.0:8006
# Data sources: metrics
hostmetrics:
scrapers:
cpu:
disk:
filesystem:
load:
memory:
network:
process:
processes:
swap:
# Data sources: traces
jaeger:
protocols:
grpc:
thrift_binary:
thrift_compact:
thrift_http:
# Data sources: traces
kafka:
protocol_version: 2.0.0
# Data sources: traces, metrics
opencensus:
# Data sources: traces, metrics, logs
otlp:
protocols:
grpc:
http:
# Data sources: metrics
<p>
prometheus:
config:
scrape_configs:
- job_name: "otel-collector"
scrape_interval: 5s
static_configs:
- targets: ["localhost:8888"]
# Data sources: traces
zipkin:
</p>
上面是一个receiver的例子,展示了接收数据源的多种配置。
处理器
Processor是一个类似处理Receiver和Exportor之间执行的数据的插件。 可以根据配置中管道的顺序配置多个处理器并依次执行。
以下是一些示例处理器配置:
processors:
# Data sources: traces
attributes:
actions:
- key: environment
value: production
action: insert
- key: db.statement
action: delete
- key: email
action: hash
# Data sources: traces, metrics, logs
batch:
# Data sources: metrics
filter:
metrics:
include:
match_type: regexp
metric_names:
- prefix/.*
- prefix_.*
# Data sources: traces, metrics, logs
memory_limiter:
check_interval: 5s
limit_mib: 4000
spike_limit_mib: 500
# Data sources: traces
resource:
attributes:
- key: cloud.zone
value: "zone-1"
action: upsert
- key: k8s.cluster.name
from_attribute: k8s-cluster
action: insert
- key: redundant-attribute
action: delete
# Data sources: traces
probabilistic_sampler:
hash_seed: 22
sampling_percentage: 15
# Data sources: traces
span:
name:
to_attributes:
rules:
- ^\/api\/v1\/document\/(?P<documentId>.*)\/update$
from_attributes: ["db.svc", "operation"]
separator: "::"
出口商
Exportor是指导出器,即采集器输出数据源的形式。 Exportor 可以支持多种数据源,也可以支持pull 和push 模式。
以下是一些出口商样品:
exporters:
# Data sources: traces, metrics, logs
file:
path: ./filename.json
# Data sources: traces
jaeger:
endpoint: "jaeger-all-in-one:14250"
tls:
cert_file: cert.pem
key_file: cert-key.pem
# Data sources: traces
kafka:
<p>
protocol_version: 2.0.0
# Data sources: traces, metrics, logs
logging:
loglevel: debug
# Data sources: traces, metrics
opencensus:
endpoint: "otelcol2:55678"
# Data sources: traces, metrics, logs
otlp:
endpoint: otelcol2:4317
tls:
cert_file: cert.pem
key_file: cert-key.pem
# Data sources: traces, metrics
otlphttp:
endpoint: https://example.com:4318/v1/traces
# Data sources: metrics
prometheus:
endpoint: "prometheus:8889"
namespace: "default"
# Data sources: metrics
prometheusremotewrite:
endpoint: "http://some.url:9411/api/prom/push"
# For official Prometheus (e.g. running via docker)
# endpoint: 'http://prometheus:9090/api/v1/write'
# tls:
# insecure: true
# Data sources: traces
zipkin:
endpoint: "http://localhost:9411/api/v2/spans"
</p>
延期
扩展是采集器的扩展。 应该注意的是,扩展不处理 otel 数据。 负责健康检查服务发现、压缩算法等非酒店数据的扩展能力。
一些扩展示例:
extensions:
health_check:
pprof:
zpages:
memory_ballast:
size_mib: 512
服务
上述配置是配置的具体数据源或插件本身的应用配置,但是否真正生效,使用顺序是在Service中配置的。 主要包括以下项目:
扩展名
管道
遥测
扩展以数组的形式配置,不分先后顺序:
service:
extensions: [health_check, pprof, zpages]
pipelines配置区分traces、metrics和logs,每一个都可以配置独立的receiver、processor和exporter,都以数组的形式配置,其中processors的数组配置需要根据需要配置执行顺序,而其他顺序无所谓。
service:
pipelines:
metrics:
receivers: [opencensus, prometheus]
exporters: [opencensus, prometheus]
traces:
receivers: [opencensus, jaeger]
processors: [batch]
exporters: [opencensus, zipkin]
telemetry配置是collector本身的配置,主要是log和metrics。 下面的配置配置了collector自身的日志级别和metrics的输出地址:
service:
telemetry:
logs:
level: debug
initial_fields:
service: my-instance
metrics:
level: detailed
address: 0.0.0.0:8888
个性化采集器
如果你想定制一个个性化的Collector,收录你想要的Receiver、Exportor等,最终的解决方案是下载源码,然后配置golang环境,根据需要修改代码并编译。 这种方式可以完美定制,但是会比较麻烦,尤其是非golang开发者,搭建golang环境非常麻烦。
OpenTelemetry 提供了一个ocb(OpenTelemetry Collector Builder)方法来方便自定义Collector。 有兴趣的朋友可以参考这个文档来使用。
总结
采集器是整个调用链的重要组成部分。 所有的客户端数据都需要一个统一的采集器来接收数据并进行一定的清洗和转发任务。 当前的 OpenTelemetry Collector 在保持兼容性和性能方面做了很多工作。 期待OpenTelemetry Collector 1.0.0版本尽快正式发布。
以上就是Opentelemetry 采集器的详细内容。 更多关于Opentelemetry 采集器的信息,请关注我们的其他相关文章!
如有侵权,请发邮件至[emailprotected]