[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"site-config":3,"primary-menu":6,"cat-spring-cloud":85,"catposts-spring-cloud":99,"post-detail-post-sc-components-dbcccb25":208},{"config":4,"socialLinks":5},null,[],{"metadata":7,"spec":10,"menuItems":20},{"name":8,"creationTimestamp":9},"primary","2026-09-12T06:13:55.024154Z",{"displayName":11,"menuItems":12},"主菜单",[13,14,15,16,17,18,19],"88c3f10b-321c-4092-86a8-70db00251b74","menu-item-izrtmxer","c4c814d1-0c2c-456b-8c96-4864965fee94","menu-item-column","menu-item-tools","menu-item-zsxq","menu-item-ocrxlczu",[21,30,40,49,58,67,76],{"displayName":22,"metadata":23,"spec":25,"status":28,"children":29},"首页",{"name":13,"creationTimestamp":24},"2026-09-12T06:13:54.422830Z",{"displayName":22,"href":26,"priority":27,"menuName":8},"\u002F",0,{"displayName":22,"href":26},[],{"displayName":31,"metadata":32,"spec":34,"status":38,"children":39},"Java面试八股",{"name":14,"creationTimestamp":33},"2026-09-13T09:42:02.854891Z",{"displayName":31,"href":35,"target":36,"priority":37,"menuName":8},"\u002Fjava-interview","_self",1,{"displayName":31,"href":35},[],{"displayName":41,"metadata":42,"spec":44,"status":47,"children":48},"文章",{"name":15,"creationTimestamp":43},"2026-09-12T06:13:54.457307Z",{"displayName":41,"href":45,"priority":46,"menuName":8},"\u002Farchives",2,{"displayName":41,"href":45},[],{"displayName":50,"metadata":51,"spec":53,"status":56,"children":57},"项目实战",{"name":16,"creationTimestamp":52},"2026-09-14T00:35:08.138170Z",{"displayName":50,"href":54,"target":36,"priority":55,"menuName":8},"\u002Fcolumn",3,{"displayName":50,"href":54},[],{"displayName":59,"metadata":60,"spec":62,"status":65,"children":66},"在线工具",{"name":17,"creationTimestamp":61},"2026-09-14T00:35:08.171474Z",{"displayName":59,"href":63,"target":36,"priority":64,"menuName":8},"\u002Ftools",4,{"displayName":59,"href":63},[],{"displayName":68,"metadata":69,"spec":71,"status":74,"children":75},"知识星球",{"name":18,"creationTimestamp":70},"2026-09-14T00:35:08.199145Z",{"displayName":68,"href":72,"target":36,"priority":73,"menuName":8},"\u002Fzsxq",5,{"displayName":68,"href":72},[],{"displayName":77,"metadata":78,"spec":80,"status":83,"children":84},"特价云服务器",{"name":19,"creationTimestamp":79},"2026-09-25T15:30:59.201614Z",{"displayName":77,"href":81,"target":36,"priority":82,"menuName":8},"\u002Fserver",6,{"displayName":77,"href":81},[],{"metadata":86,"spec":91,"status":97,"postCount":73},{"name":87,"creationTimestamp":88,"labels":89},"spring-cloud","2026-09-13T09:13:25.651927Z",{"haloweb.section":90},"interview",{"displayName":92,"slug":87,"cover":93,"description":94,"priority":95,"hideFromList":96,"preventParentPostCascadeQuery":96},"Spring Cloud 面试题","","Spring Cloud 微服务面试题：注册中心、网关、配置中心、熔断限流与链路治理。",16,false,{"permalink":98,"postCount":73,"visiblePostCount":73},"\u002Fcategories\u002Fspring-cloud",[100,124,145,166,187],{"metadata":101,"spec":104,"status":113,"categories":118},{"name":102,"creationTimestamp":103},"post-sc-feign-edab66ba","2026-09-13T10:01:03.910779Z",{"title":105,"slug":106,"cover":93,"excerpt":107,"publishTime":109,"categories":110,"tags":111,"priority":27,"pinned":96,"deleted":96,"visible":112,"allowComment":108},"OpenFeign 的工作原理？","sc-feign",{"raw":93,"autoGenerate":108},true,"2026-09-13T10:01:03.959628Z",[87],[],"PUBLIC",{"permalink":114,"excerpt":115,"lastModifyTime":116,"phase":117},"\u002Farchives\u002Fsc-feign","一、使用 @FeignClient(name = \"user-service\")\npublic interface UserClient {\n    @GetMapping(\"\u002Fuser\u002F{id}\")\n    User getUser(@PathVariable Long id);\n}\n 二、原理 ","2026-09-16T09:14:40.781919Z","PUBLISHED",[119],{"metadata":120,"spec":122,"status":123,"postCount":73},{"name":87,"creationTimestamp":88,"labels":121},{"haloweb.section":90},{"displayName":92,"slug":87,"cover":93,"description":94,"priority":95,"hideFromList":96,"preventParentPostCascadeQuery":96},{"permalink":98,"postCount":73,"visiblePostCount":73},{"metadata":125,"spec":128,"status":135,"categories":139},{"name":126,"creationTimestamp":127},"post-sc-sentinel-aca6d4ca","2026-09-13T10:01:03.588033Z",{"title":129,"slug":130,"cover":93,"excerpt":131,"publishTime":132,"categories":133,"tags":134,"priority":27,"pinned":96,"deleted":96,"visible":112,"allowComment":108},"Sentinel 的工作原理？","sc-sentinel",{"raw":93,"autoGenerate":108},"2026-09-13T10:01:03.793927Z",[87],[],{"permalink":136,"excerpt":137,"lastModifyTime":138,"phase":117},"\u002Farchives\u002Fsc-sentinel","一、核心功能 流量控制：QPS、线程数限流，支持匀速、预热等模式。 熔断降级：慢调用比例、异常比例、异常数达到阈值时熔断。 系统保护：CPU、负载、入口 QPS、平均 RT、并发线程数。 热点参数限流：针对参数维度限流。 二、工作原理 基于滑动窗口统计实时指标。 通过责任链模式处理请求：NodeSe","2026-09-16T09:14:38.324239Z",[140],{"metadata":141,"spec":143,"status":144,"postCount":73},{"name":87,"creationTimestamp":88,"labels":142},{"haloweb.section":90},{"displayName":92,"slug":87,"cover":93,"description":94,"priority":95,"hideFromList":96,"preventParentPostCascadeQuery":96},{"permalink":98,"postCount":73,"visiblePostCount":73},{"metadata":146,"spec":149,"status":156,"categories":160},{"name":147,"creationTimestamp":148},"post-sc-gateway-3716276a","2026-09-13T10:01:03.236916Z",{"title":150,"slug":151,"cover":93,"excerpt":152,"publishTime":153,"categories":154,"tags":155,"priority":27,"pinned":96,"deleted":96,"visible":112,"allowComment":108},"Spring Cloud Gateway 的工作原理？","sc-gateway",{"raw":93,"autoGenerate":108},"2026-09-13T10:01:03.432717Z",[87],[],{"permalink":157,"excerpt":158,"lastModifyTime":159,"phase":117},"\u002Farchives\u002Fsc-gateway","一、核心概念 Route：路由，由 ID、目标 URI、断言、过滤器组成。 Predicate：断言，匹配 HTTP 请求的条件（路径、方法、Header 等）。 Filter：过滤器，请求前后处理（鉴权、限流、日志、修改请求\u002F响应）。 二、执行流程 请求进入 Gateway，由 HandlerMa","2026-09-16T09:14:40.145885Z",[161],{"metadata":162,"spec":164,"status":165,"postCount":73},{"name":87,"creationTimestamp":88,"labels":163},{"haloweb.section":90},{"displayName":92,"slug":87,"cover":93,"description":94,"priority":95,"hideFromList":96,"preventParentPostCascadeQuery":96},{"permalink":98,"postCount":73,"visiblePostCount":73},{"metadata":167,"spec":170,"status":177,"categories":181},{"name":168,"creationTimestamp":169},"post-sc-nacos-14cc902b","2026-09-13T10:01:03.041394Z",{"title":171,"slug":172,"cover":93,"excerpt":173,"publishTime":174,"categories":175,"tags":176,"priority":27,"pinned":96,"deleted":96,"visible":112,"allowComment":108},"Nacos 的 CP 和 AP 模式？","sc-nacos",{"raw":93,"autoGenerate":108},"2026-09-13T10:01:03.086427Z",[87],[],{"permalink":178,"excerpt":179,"lastModifyTime":180,"phase":117},"\u002Farchives\u002Fsc-nacos","一、AP 模式（临时实例） 服务实例注册后，通过心跳维持，心跳超时则剔除。 各节点数据可能短暂不一致，但保证可用性。 适合服务注册场景，实例变化频繁。 二、CP 模式（持久实例） 实例注册需要集群半数以上节点确认，强一致性。 节点不可用时不会自动剔除，需手动注销。 适合需要强一致性的场景。 三、切换","2026-09-16T09:14:39.577571Z",[182],{"metadata":183,"spec":185,"status":186,"postCount":73},{"name":87,"creationTimestamp":88,"labels":184},{"haloweb.section":90},{"displayName":92,"slug":87,"cover":93,"description":94,"priority":95,"hideFromList":96,"preventParentPostCascadeQuery":96},{"permalink":98,"postCount":73,"visiblePostCount":73},{"metadata":188,"spec":191,"status":198,"categories":202},{"name":189,"creationTimestamp":190},"post-sc-components-dbcccb25","2026-09-13T10:01:02.855129Z",{"title":192,"slug":193,"cover":93,"excerpt":194,"publishTime":195,"categories":196,"tags":197,"priority":27,"pinned":96,"deleted":96,"visible":112,"allowComment":108},"Spring Cloud 常用组件有哪些？","sc-components",{"raw":93,"autoGenerate":108},"2026-09-13T10:01:02.906713Z",[87],[],{"permalink":199,"excerpt":200,"lastModifyTime":201,"phase":117},"\u002Farchives\u002Fsc-components","一、注册中心 Eureka：Netflix 出品，AP，自我保护机制。 Nacos：阿里出品，支持 CP\u002FAP 切换，同时支持配置中心。 Consul：支持服务发现、KV 存储、健康检查。 二、配置中心 Spring Cloud Config：基于 Git。 Nacos Config：配置实时推送。","2026-09-16T09:14:35.918447Z",[203],{"metadata":204,"spec":206,"status":207,"postCount":73},{"name":87,"creationTimestamp":88,"labels":205},{"haloweb.section":90},{"displayName":92,"slug":87,"cover":93,"description":94,"priority":95,"hideFromList":96,"preventParentPostCascadeQuery":96},{"permalink":98,"postCount":73,"visiblePostCount":73},{"metadata":209,"spec":210,"status":214,"categories":215,"content":221},{"name":189,"creationTimestamp":190},{"title":192,"slug":193,"cover":93,"excerpt":211,"publishTime":195,"categories":212,"tags":213,"priority":27,"pinned":96,"deleted":96,"visible":112,"allowComment":108},{"raw":93,"autoGenerate":108},[87],[],{"permalink":199,"excerpt":200,"lastModifyTime":201,"phase":117},[216],{"metadata":217,"spec":219,"status":220,"postCount":73},{"name":87,"creationTimestamp":88,"labels":218},{"haloweb.section":90},{"displayName":92,"slug":87,"cover":93,"description":94,"priority":95,"hideFromList":96,"preventParentPostCascadeQuery":96},{"permalink":98,"postCount":73,"visiblePostCount":73},{"content":222,"raw":222},"\u003Ch2>一、注册中心\u003C\u002Fh2>\n\u003Cul>\n\u003Cli>\u003Cstrong>Eureka\u003C\u002Fstrong>：Netflix 出品，AP，自我保护机制。\u003C\u002Fli>\n\u003Cli>\u003Cstrong>Nacos\u003C\u002Fstrong>：阿里出品，支持 CP\u002FAP 切换，同时支持配置中心。\u003C\u002Fli>\n\u003Cli>\u003Cstrong>Consul\u003C\u002Fstrong>：支持服务发现、KV 存储、健康检查。\u003C\u002Fli>\n\u003C\u002Ful>\n\u003Ch2>二、配置中心\u003C\u002Fh2>\n\u003Cul>\n\u003Cli>\u003Cstrong>Spring Cloud Config\u003C\u002Fstrong>：基于 Git。\u003C\u002Fli>\n\u003Cli>\u003Cstrong>Nacos Config\u003C\u002Fstrong>：配置实时推送。\u003C\u002Fli>\n\u003Cli>\u003Cstrong>Apollo\u003C\u002Fstrong>：携程开源，功能完善。\u003C\u002Fli>\n\u003C\u002Ful>\n\u003Ch2>三、网关\u003C\u002Fh2>\n\u003Cul>\n\u003Cli>\u003Cstrong>Gateway\u003C\u002Fstrong>：Spring 官方，基于 WebFlux，异步非阻塞。\u003C\u002Fli>\n\u003Cli>\u003Cstrong>Zuul\u003C\u002Fstrong>：Netflix 出品，同步阻塞，已停止维护。\u003C\u002Fli>\n\u003C\u002Ful>\n\u003Ch2>四、负载均衡\u003C\u002Fh2>\n\u003Cul>\n\u003Cli>\u003Cstrong>Ribbon\u003C\u002Fstrong>：客户端负载均衡（已停更，被 LoadBalancer 替代）。\u003C\u002Fli>\n\u003Cli>\u003Cstrong>Spring Cloud LoadBalancer\u003C\u002Fstrong>：官方替代。\u003C\u002Fli>\n\u003C\u002Ful>\n\u003Ch2>五、熔断降级\u003C\u002Fh2>\n\u003Cul>\n\u003Cli>\u003Cstrong>Hystrix\u003C\u002Fstrong>（停更）→ \u003Cstrong>Resilience4j\u003C\u002Fstrong> \u002F \u003Cstrong>Sentinel\u003C\u002Fstrong>（阿里）。\u003C\u002Fli>\n\u003C\u002Ful>\n\u003Ch2>六、调用\u003C\u002Fh2>\n\u003Cul>\n\u003Cli>\u003Cstrong>OpenFeign\u003C\u002Fstrong>：声明式 HTTP 客户端。\u003C\u002Fli>\n\u003C\u002Ful>"]