序
本文主要研究一下如何停止某个pod的流量
配置
# Copyright Istio Authors
#
# Licensed 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.
##################################################################################################
# Ratings service
##################################################################################################
apiVersion: v1
kind: Service
metadata:
name: ratings
labels:
app: ratings
service: rat

本文详细介绍了如何在SpringBoot应用中配置liveness和readiness探针,以及如何通过更改ReadinessState来停止某个Pod的流量。通过kubectl命令监控Pod状态,当设置为REFUSING_TRAFFIC时,Pod会从服务流量中移除,不增加副本数量。
最低0.47元/天 解锁文章
819

被折叠的 条评论
为什么被折叠?



