相关文章推荐
果断的猴子
·
WPF MVVM框架 Prism ...
·
3 月前
·
风度翩翩的山寨机
·
sql循环遍历查询 - 百度
·
8 月前
·
眼睛小的西装
·
ClickHouse ...
·
1 年前
·
坏坏的黑框眼镜
·
在 Vue ...
·
1 年前
·
Code
›
TiDB 高并发写入场景最佳实践 | PingCAP 文档中心
https://docs.pingcap.com/zh/tidb/stable/high-concurrency-best-practices/
不要命的汉堡包
4 月前
</noscript><noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-TPX49SBK" height="0" width="0" style="display: none; visibility: hidden" aria-hidden="true"/></noscript><div id="___gatsby"><div style="outline:none" tabindex="-1" id="gatsby-focus-wrapper"><style data-emotion="css 6ko3zs">.css-6ko3zs{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;width:100%;box-sizing:border-box;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;position:fixed;z-index:1100;top:0;left:auto;right:0;background-color:#1976d2;color:#fff;background-color:#f9f9f9;border-bottom:1px solid #e5e5e5;box-shadow:0px 1px 6px rgba(0, 0, 0, 0.08);height:5rem;}@media print{.css-6ko3zs{}}</style><style data-emotion="css foju0o">.css-foju0o{background-color:#fff;color:rgba(0, 0, 0, 0.87);-webkit-transition:box-shadow 300ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:box-shadow 300ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;box-shadow:0px 2px 4px -1px rgba(0,0,0,0.2),0px 4px 5px 0px rgba(0,0,0,0.14),0px 1px 10px 0px rgba(0,0,0,0.12);display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;width:100%;box-sizing:border-box;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;position:fixed;z-index:1100;top:0;left:auto;right:0;background-color:#1976d2;color:#fff;background-color:#f9f9f9;border-bottom:1px solid #e5e5e5;box-shadow:0px 1px 6px rgba(0, 0, 0, 0.08);height:5rem;}@media print{.css-foju0o{}}</style><header class="MuiPaper-root MuiPaper-elevation MuiPaper-elevation4 MuiAppBar-root MuiAppBar-colorPrimary MuiAppBar-positionFixed doc-site-header mui-fixed css-foju0o"><style data-emotion="css 1xw2ef0">.css-1xw2ef0{position:relative;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;padding-left:16px;padding-right:16px;min-height:56px;height:100%;}@media (min-width:600px){.css-1xw2ef0{padding-left:24px;padding-right:24px;}}@media (min-width:0px){@media (orientation: landscape){.css-1xw2ef0{min-height:48px;}}}@media (min-width:600px){.css-1xw2ef0{min-height:64px;}}@media (min-width:900px){.css-1xw2ef0{padding-left:2rem;padding-right:2rem;}}</style><div class="MuiToolbar-root MuiToolbar-gutters MuiToolbar-regular css-1xw2ef0"><style data-emotion="css 16bbyrv">.css-16bbyrv{text-align:center;-webkit-flex:0 0 auto;-ms-flex:0 0 auto;flex:0 0 auto;font-size:1.5rem;padding:8px;border-radius:50%;overflow:visible;color:rgba(0, 0, 0, 0.54);-webkit-transition:background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;}.css-16bbyrv:hover{background-color:rgba(0, 0, 0, 0.04);}@media (hover: none){.css-16bbyrv:hover{background-color:transparent;}}.css-16bbyrv.Mui-disabled{background-color:transparent;color:rgba(0, 0, 0, 0.26);}@media (min-width:1200px){.css-16bbyrv{;}}</style><style data-emotion="css iuftj9">.css-iuftj9{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;position:relative;box-sizing:border-box;-webkit-tap-highlight-color:transparent;background-color:transparent;outline:0;border:0;margin:0;border-radius:0;padding:0;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;vertical-align:middle;-moz-appearance:none;-webkit-appearance:none;-webkit-text-decoration:none;text-decoration:none;color:inherit;text-align:center;-webkit-flex:0 0 auto;-ms-flex:0 0 auto;flex:0 0 auto;font-size:1.5rem;padding:8px;border-radius:50%;overflow:visible;color:rgba(0, 0, 0, 0.54);-webkit-transition:background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;}.css-iuftj9::-moz-focus-inner{border-style:none;}.css-iuftj9.Mui-disabled{pointer-events:none;cursor:default;}@media print{.css-iuftj9{-webkit-print-color-adjust:exact;color-adjust:exact;}}.css-iuftj9:hover{background-color:rgba(0, 0, 0, 0.04);}@media (hover: none){.css-iuftj9:hover{background-color:transparent;}}.css-iuftj9.Mui-disabled{background-color:transparent;color:rgba(0, 0, 0, 0.26);}@media (min-width:1200px){.css-iuftj9{;}}</style><button class="MuiButtonBase-root MuiIconButton-root MuiIconButton-sizeMedium css-iuftj9" tabindex="0" type="button" aria-label="menu"><style data-emotion="css vubbuv">.css-vubbuv{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;width:1em;height:1em;display:inline-block;fill:currentColor;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;-webkit-transition:fill 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:fill 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;font-size:1.5rem;}</style><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="MenuIcon"><path d="M3 18h18v-2H3v2zm0-5h18v-2H3v2zm0-7v2h18V6H3z"/></svg></button><style data-emotion="css a3xyjy">.css-a3xyjy{z-index:1200;}</style><style data-emotion="css 13tqxrv">@media (min-width:0px){.css-13tqxrv{;}}@media (min-width:900px){.css-13tqxrv{display:block;}}</style><div class="MuiBox-root css-13tqxrv"><style data-emotion="css tx8jsd">.css-tx8jsd{margin:0;font-size:1rem;line-height:1.5rem;font-family:"Helvetica Neue","sans-serif";font-weight:400;font-style:normal;color:#666666;}</style><a class="MuiTypography-root MuiTypography-body1 css-tx8jsd" target="_blank" href="https://cn.pingcap.com/" style="text-decoration:none"><style data-emotion="css uz5bjn">.css-uz5bjn{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;width:1em;height:1em;display:inline-block;fill:currentColor;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;-webkit-transition:fill 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:fill 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;font-size:1.5rem;width:6.75rem;}@media (min-width:0px){.css-uz5bjn{;}}@media (min-width:600px){.css-uz5bjn{display:block;}}</style><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-uz5bjn" focusable="false" aria-hidden="true" viewbox="0 0 769.89 203.08"><g id="Layer_2" data-name="Layer 2"><g id="Layer_1-2" data-name="Layer 1"><path fill="#082265" d="M100.11,47.34l-88-25.1A9.5,9.5,0,0,0,0,31.38v162.2a9.51,9.51,0,0,0,9.48,9.5,9.35,9.35,0,0,0,2.22-.26l88-21h0a9.48,9.48,0,0,0,7.3-9.25V56.48A9.54,9.54,0,0,0,100.11,47.34Z"/><path fill="#00aeef" d="M160.05,41.57a9.55,9.55,0,0,0-6.88-9.11L41.16.37A9.5,9.5,0,0,0,29,9.51V132.59a9.47,9.47,0,0,0,11.72,9.23l112.14-27a9.47,9.47,0,0,0,7.28-9.26Z"/><path fill="#303eab" d="M100.11,47.34,29,27.07V132.59a9.47,9.47,0,0,0,11.72,9.23L107,125.88V56.48A9.54,9.54,0,0,0,100.11,47.34Z"/><path fill="#082265" d="M576.1,126.26h0l-.23.37a40.12,40.12,0,0,1-13.72,13.09,36.62,36.62,0,0,1-18.78,5.43c-10.94,0-20.51-4.36-28.42-13a43.82,43.82,0,0,1-11.37-31,43.09,43.09,0,0,1,11.74-29.38c7.62-8.17,16.81-12.31,27.3-12.31,14.37-.13,25.2,5.8,33.13,18.13L576,78h.22l9.33-5.77a51.65,51.65,0,0,0-15.42-16.39,48.17,48.17,0,0,0-26.73-8.09A46.85,46.85,0,0,0,507.66,63c-9.94,10.23-15,23.28-15,38.77,0,15,5,28.08,14.84,38.9,9.81,10.64,21.69,16,35.33,16h.51c17.92-.37,32.69-9.06,42.11-24.6Z"/><polygon fill="#082265" points="645.84 49.09 633.16 49.09 586.01 154.63 601.05 154.63 615.63 119.55 615.65 119.55 620.8 108.59 620.78 108.59 639.76 64.05 658.36 108.59 631.66 108.59 626.79 119.55 662.69 119.55 677.4 154.63 690.66 154.63 645.84 49.09"/><path fill="#082265" d="M759.63,58.75c-7-6.32-15.81-9.52-26.18-9.52H699.3v105.4h12.44V113.34h0V102.25h0V60.59H734a24.73,24.73,0,0,1,16.22,5.63,18.12,18.12,0,0,1,7.37,14c.39,6.62-1.77,11.88-6.61,16.07a23.43,23.43,0,0,1-16.31,6H721.77v11.09h14.91a33.34,33.34,0,0,0,23.23-8.85,29,29,0,0,0,10-21.91C770,72.89,766.58,64.87,759.63,58.75Z"/><rect fill="#082265" x="296.25" y="51.17" width="12.44" height="12.44"/><rect fill="#082265" x="296.25" y="79.04" width="12.44" height="75.74"/><path fill="#082265" d="M483.63,147.21V114.69a38.6,38.6,0,0,0-12.25-29.2c-8.22-8.22-18.1-12.27-29.35-12a39.17,39.17,0,0,0-27.82,12.54,40.08,40.08,0,0,0-11.29,28.49,41,41,0,0,0,12.24,29.59c8.19,8.18,18,12.12,29.22,11.71a38.78,38.78,0,0,0,27.48-12.33v5.17m0,0c0,6.88-2.73,12.89-8.11,17.88a27.1,27.1,0,0,1-19,7.73,27.83,27.83,0,0,1-16.93-5.64,25.92,25.92,0,0,1-9-10.54l-9.52,5.5a36.63,36.63,0,0,0,9.94,12c6.6,5.25,14.75,8.13,24.23,8.54.59,0,1.18,0,1.77,0a40.89,40.89,0,0,0,26-9.25c8.17-6.52,12.32-14.86,12.32-24.8v-2.95m-12-31.74a29.23,29.23,0,0,1-8.41,20.22,25.68,25.68,0,0,1-19.5,8.38,27.3,27.3,0,0,1-20.2-8.39,28.22,28.22,0,0,1-8.66-20.34,28.66,28.66,0,0,1,7.88-20.61,27.21,27.21,0,0,1,19.53-9.45c.51,0,1,0,1.5,0,7.61,0,14,2.85,19.45,8.69A28.51,28.51,0,0,1,471.59,115.47Z"/><path fill="#082265" d="M274.1,58.75c-7-6.32-15.81-9.52-26.19-9.52H213.76v105.4h12.45V113.34h0V102.25h0V60.59h22.24a24.73,24.73,0,0,1,16.23,5.63,18.12,18.12,0,0,1,7.37,14c.39,6.62-1.77,11.88-6.61,16.07a23.43,23.43,0,0,1-16.31,6H236.24v11.09h14.91a33.34,33.34,0,0,0,23.23-8.85,29,29,0,0,0,10-21.91C284.5,72.89,281.05,64.87,274.1,58.75Z"/><path fill="#082265" d="M357.54,74.41c-9.92,0-18.3,3.43-24.94,10.2s-9.91,15.24-9.91,25.33v44.53h12V108.86a21.82,21.82,0,0,1,6.75-16.1A22.08,22.08,0,0,1,357.54,86a21.49,21.49,0,0,1,15.82,6.75,21.86,21.86,0,0,1,6.89,16.1v45.61h12V109.94c0-10.09-3.34-18.61-9.92-25.33A33.47,33.47,0,0,0,357.54,74.41Z"/></g></g></svg></a></div><style data-emotion="css 5qlh60">.css-5qlh60{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;padding-left:2rem;height:100%;}.css-5qlh60>:not(style)+:not(style){margin:0;margin-left:24px;}@media (min-width:0px){.css-5qlh60{;}}@media (min-width:900px){.css-5qlh60{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}}</style><div class="css-5qlh60"><style data-emotion="css kiou0g">.css-kiou0g{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;padding-top:0.25rem;padding-bottom:0.25rem;}</style><div class="MuiBox-root css-kiou0g"><a style="text-decoration:none" hreflang="zh" href="/zh/"><style data-emotion="css 2jgwiy">.css-2jgwiy{margin:0;font-size:1rem;line-height:1.5rem;font-family:"Helvetica Neue","sans-serif";font-weight:400;font-style:normal;color:#666666;color:#282a36;font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Helvetica,Arial,"IBM Plex Sans",sans-serif,"Apple Color Emoji","Segoe UI Emoji";display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;gap:4px;}</style><div class="MuiTypography-root MuiTypography-body1 css-2jgwiy">文档中心</div></a></div><div class="MuiBox-root css-kiou0g"><a style="text-decoration:none" hreflang="zh" href="/zh/tidb/stable"><div class="MuiTypography-root MuiTypography-body1 css-2jgwiy">TiDB</div></a></div><div class="MuiBox-root css-kiou0g"><a class="MuiTypography-root MuiTypography-body1 css-tx8jsd" target="_blank" href="https://asktug.com/" style="text-decoration:none"><div class="MuiTypography-root MuiTypography-body1 css-2jgwiy">社区</div></a></div><div class="MuiBox-root css-kiou0g"><a class="MuiTypography-root MuiTypography-body1 css-tx8jsd" target="_blank" href="https://cn.pingcap.com/contact/" style="text-decoration:none"><div class="MuiTypography-root MuiTypography-body1 css-2jgwiy">联系我们</div></a></div><div class="MuiBox-root css-kiou0g"><a class="MuiTypography-root MuiTypography-body1 css-tx8jsd" target="_blank" href="https://cn.pingcap.com/product/#SelectProduct" style="text-decoration:none"><div class="MuiTypography-root MuiTypography-body1 css-2jgwiy"><style data-emotion="css xnd31y">.css-xnd31y{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;width:1em;height:1em;display:inline-block;fill:currentColor;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;-webkit-transition:fill 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:fill 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;font-size:inherit;padding-top:0.5rem;}</style><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeInherit css-xnd31y" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="DownloadIcon"><path d="M5 20h14v-2H5v2zM19 9h-4V3H9v6H5l7 7 7-7z"/></svg></div></a></div></div><style data-emotion="css 1vn3uc0">.css-1vn3uc0{color:#282a36;}@media (min-width:900px){.css-1vn3uc0{;}}</style><div class="MuiBox-root css-1vn3uc0"><style data-emotion="css btg76o">.css-btg76o{text-transform:none;font-family:-apple-system,"Poppins","Helvetica Neue",sans-serif,"Noto Sans","Fira Code","IBM Plex Sans","sans-serif";font-weight:500;font-size:0.875rem;line-height:1.75;min-width:64px;padding:6px 8px;border-radius:4px;-webkit-transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;color:inherit;border-color:currentColor;box-shadow:none;}.css-btg76o:hover{-webkit-text-decoration:none;text-decoration:none;background-color:rgba(0, 0, 0, 0.04);}@media (hover: none){.css-btg76o:hover{background-color:transparent;}}.css-btg76o.Mui-disabled{color:rgba(0, 0, 0, 0.26);}.css-btg76o:hover{box-shadow:none;}.css-btg76o.Mui-focusVisible{box-shadow:none;}.css-btg76o:active{box-shadow:none;}.css-btg76o.Mui-disabled{box-shadow:none;}</style><style data-emotion="css 1ei260h">.css-1ei260h{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;position:relative;box-sizing:border-box;-webkit-tap-highlight-color:transparent;background-color:transparent;outline:0;border:0;margin:0;border-radius:0;padding:0;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;vertical-align:middle;-moz-appearance:none;-webkit-appearance:none;-webkit-text-decoration:none;text-decoration:none;color:inherit;text-transform:none;font-family:-apple-system,"Poppins","Helvetica Neue",sans-serif,"Noto Sans","Fira Code","IBM Plex Sans","sans-serif";font-weight:500;font-size:0.875rem;line-height:1.75;min-width:64px;padding:6px 8px;border-radius:4px;-webkit-transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;color:inherit;border-color:currentColor;box-shadow:none;}.css-1ei260h::-moz-focus-inner{border-style:none;}.css-1ei260h.Mui-disabled{pointer-events:none;cursor:default;}@media print{.css-1ei260h{-webkit-print-color-adjust:exact;color-adjust:exact;}}.css-1ei260h:hover{-webkit-text-decoration:none;text-decoration:none;background-color:rgba(0, 0, 0, 0.04);}@media (hover: none){.css-1ei260h:hover{background-color:transparent;}}.css-1ei260h.Mui-disabled{color:rgba(0, 0, 0, 0.26);}.css-1ei260h:hover{box-shadow:none;}.css-1ei260h.Mui-focusVisible{box-shadow:none;}.css-1ei260h:active{box-shadow:none;}.css-1ei260h.Mui-disabled{box-shadow:none;}</style><button class="MuiButtonBase-root MuiButton-root MuiButton-text MuiButton-textInherit MuiButton-sizeMedium MuiButton-textSizeMedium MuiButton-colorInherit MuiButton-disableElevation css-1ei260h" tabindex="0" type="button" id="header-nav-items" aria-haspopup="true"><style data-emotion="css 6xugel">.css-6xugel{display:inherit;margin-right:8px;margin-left:-4px;}.css-6xugel>*:nth-of-type(1){font-size:20px;}</style><span class="MuiButton-startIcon MuiButton-iconSizeMedium css-6xugel"><style data-emotion="css 1x9zct">.css-1x9zct{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;width:1em;height:1em;display:inline-block;fill:currentColor;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;-webkit-transition:fill 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:fill 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;font-size:1.5rem;width:6.75rem;height:1.5rem;}</style><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-1x9zct" focusable="false" aria-hidden="true" viewbox="0 0 769.89 203.08"><g id="Layer_2" data-name="Layer 2"><g id="Layer_1-2" data-name="Layer 1"><path fill="#082265" d="M100.11,47.34l-88-25.1A9.5,9.5,0,0,0,0,31.38v162.2a9.51,9.51,0,0,0,9.48,9.5,9.35,9.35,0,0,0,2.22-.26l88-21h0a9.48,9.48,0,0,0,7.3-9.25V56.48A9.54,9.54,0,0,0,100.11,47.34Z"/><path fill="#00aeef" d="M160.05,41.57a9.55,9.55,0,0,0-6.88-9.11L41.16.37A9.5,9.5,0,0,0,29,9.51V132.59a9.47,9.47,0,0,0,11.72,9.23l112.14-27a9.47,9.47,0,0,0,7.28-9.26Z"/><path fill="#303eab" d="M100.11,47.34,29,27.07V132.59a9.47,9.47,0,0,0,11.72,9.23L107,125.88V56.48A9.54,9.54,0,0,0,100.11,47.34Z"/><path fill="#082265" d="M576.1,126.26h0l-.23.37a40.12,40.12,0,0,1-13.72,13.09,36.62,36.62,0,0,1-18.78,5.43c-10.94,0-20.51-4.36-28.42-13a43.82,43.82,0,0,1-11.37-31,43.09,43.09,0,0,1,11.74-29.38c7.62-8.17,16.81-12.31,27.3-12.31,14.37-.13,25.2,5.8,33.13,18.13L576,78h.22l9.33-5.77a51.65,51.65,0,0,0-15.42-16.39,48.17,48.17,0,0,0-26.73-8.09A46.85,46.85,0,0,0,507.66,63c-9.94,10.23-15,23.28-15,38.77,0,15,5,28.08,14.84,38.9,9.81,10.64,21.69,16,35.33,16h.51c17.92-.37,32.69-9.06,42.11-24.6Z"/><polygon fill="#082265" points="645.84 49.09 633.16 49.09 586.01 154.63 601.05 154.63 615.63 119.55 615.65 119.55 620.8 108.59 620.78 108.59 639.76 64.05 658.36 108.59 631.66 108.59 626.79 119.55 662.69 119.55 677.4 154.63 690.66 154.63 645.84 49.09"/><path fill="#082265" d="M759.63,58.75c-7-6.32-15.81-9.52-26.18-9.52H699.3v105.4h12.44V113.34h0V102.25h0V60.59H734a24.73,24.73,0,0,1,16.22,5.63,18.12,18.12,0,0,1,7.37,14c.39,6.62-1.77,11.88-6.61,16.07a23.43,23.43,0,0,1-16.31,6H721.77v11.09h14.91a33.34,33.34,0,0,0,23.23-8.85,29,29,0,0,0,10-21.91C770,72.89,766.58,64.87,759.63,58.75Z"/><rect fill="#082265" x="296.25" y="51.17" width="12.44" height="12.44"/><rect fill="#082265" x="296.25" y="79.04" width="12.44" height="75.74"/><path fill="#082265" d="M483.63,147.21V114.69a38.6,38.6,0,0,0-12.25-29.2c-8.22-8.22-18.1-12.27-29.35-12a39.17,39.17,0,0,0-27.82,12.54,40.08,40.08,0,0,0-11.29,28.49,41,41,0,0,0,12.24,29.59c8.19,8.18,18,12.12,29.22,11.71a38.78,38.78,0,0,0,27.48-12.33v5.17m0,0c0,6.88-2.73,12.89-8.11,17.88a27.1,27.1,0,0,1-19,7.73,27.83,27.83,0,0,1-16.93-5.64,25.92,25.92,0,0,1-9-10.54l-9.52,5.5a36.63,36.63,0,0,0,9.94,12c6.6,5.25,14.75,8.13,24.23,8.54.59,0,1.18,0,1.77,0a40.89,40.89,0,0,0,26-9.25c8.17-6.52,12.32-14.86,12.32-24.8v-2.95m-12-31.74a29.23,29.23,0,0,1-8.41,20.22,25.68,25.68,0,0,1-19.5,8.38,27.3,27.3,0,0,1-20.2-8.39,28.22,28.22,0,0,1-8.66-20.34,28.66,28.66,0,0,1,7.88-20.61,27.21,27.21,0,0,1,19.53-9.45c.51,0,1,0,1.5,0,7.61,0,14,2.85,19.45,8.69A28.51,28.51,0,0,1,471.59,115.47Z"/><path fill="#082265" d="M274.1,58.75c-7-6.32-15.81-9.52-26.19-9.52H213.76v105.4h12.45V113.34h0V102.25h0V60.59h22.24a24.73,24.73,0,0,1,16.23,5.63,18.12,18.12,0,0,1,7.37,14c.39,6.62-1.77,11.88-6.61,16.07a23.43,23.43,0,0,1-16.31,6H236.24v11.09h14.91a33.34,33.34,0,0,0,23.23-8.85,29,29,0,0,0,10-21.91C284.5,72.89,281.05,64.87,274.1,58.75Z"/><path fill="#082265" d="M357.54,74.41c-9.92,0-18.3,3.43-24.94,10.2s-9.91,15.24-9.91,25.33v44.53h12V108.86a21.82,21.82,0,0,1,6.75-16.1A22.08,22.08,0,0,1,357.54,86a21.49,21.49,0,0,1,15.82,6.75,21.86,21.86,0,0,1,6.89,16.1v45.61h12V109.94c0-10.09-3.34-18.61-9.92-25.33A33.47,33.47,0,0,0,357.54,74.41Z"/></g></g></svg></span><style data-emotion="css 1n4a93h">.css-1n4a93h{display:inherit;margin-right:-4px;margin-left:8px;}.css-1n4a93h>*:nth-of-type(1){font-size:20px;}</style><span class="MuiButton-endIcon MuiButton-iconSizeMedium css-1n4a93h"><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="KeyboardArrowDownIcon"><path d="M7.41 8.59 12 13.17l4.59-4.58L18 10l-6 6-6-6 1.41-1.41z"/></svg></span></button></div><style data-emotion="css jnv64h">.css-jnv64h{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;margin-left:auto;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}@media (min-width:0px){.css-jnv64h>:not(style)+:not(style){margin:0;margin-left:8px;}}@media (min-width:1200px){.css-jnv64h>:not(style)+:not(style){margin:0;margin-left:24px;}}</style><div class="css-jnv64h"><style data-emotion="css 1qlh2t1">.css-1qlh2t1{color:#282a36;}</style><div class="MuiBox-root css-1qlh2t1"><style data-emotion="css 1mvsusm">.css-1mvsusm{text-align:center;-webkit-flex:0 0 auto;-ms-flex:0 0 auto;flex:0 0 auto;font-size:1.5rem;padding:8px;border-radius:50%;overflow:visible;color:rgba(0, 0, 0, 0.54);-webkit-transition:background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;color:inherit;}.css-1mvsusm:hover{background-color:rgba(0, 0, 0, 0.04);}@media (hover: none){.css-1mvsusm:hover{background-color:transparent;}}.css-1mvsusm.Mui-disabled{background-color:transparent;color:rgba(0, 0, 0, 0.26);}@media (min-width:1200px){.css-1mvsusm{;}}</style><style data-emotion="css jwr93t">.css-jwr93t{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;position:relative;box-sizing:border-box;-webkit-tap-highlight-color:transparent;background-color:transparent;outline:0;border:0;margin:0;border-radius:0;padding:0;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;vertical-align:middle;-moz-appearance:none;-webkit-appearance:none;-webkit-text-decoration:none;text-decoration:none;color:inherit;text-align:center;-webkit-flex:0 0 auto;-ms-flex:0 0 auto;flex:0 0 auto;font-size:1.5rem;padding:8px;border-radius:50%;overflow:visible;color:rgba(0, 0, 0, 0.54);-webkit-transition:background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;color:inherit;}.css-jwr93t::-moz-focus-inner{border-style:none;}.css-jwr93t.Mui-disabled{pointer-events:none;cursor:default;}@media print{.css-jwr93t{-webkit-print-color-adjust:exact;color-adjust:exact;}}.css-jwr93t:hover{background-color:rgba(0, 0, 0, 0.04);}@media (hover: none){.css-jwr93t:hover{background-color:transparent;}}.css-jwr93t.Mui-disabled{background-color:transparent;color:rgba(0, 0, 0, 0.26);}@media (min-width:1200px){.css-jwr93t{;}}</style><button class="MuiButtonBase-root MuiIconButton-root MuiIconButton-sizeMedium css-jwr93t" tabindex="0" type="button"><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="LanguageIcon"><path d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zm6.93 6h-2.95c-.32-1.25-.78-2.45-1.38-3.56 1.84.63 3.37 1.91 4.33 3.56zM12 4.04c.83 1.2 1.48 2.53 1.91 3.96h-3.82c.43-1.43 1.08-2.76 1.91-3.96zM4.26 14C4.1 13.36 4 12.69 4 12s.1-1.36.26-2h3.38c-.08.66-.14 1.32-.14 2 0 .68.06 1.34.14 2H4.26zm.82 2h2.95c.32 1.25.78 2.45 1.38 3.56-1.84-.63-3.37-1.9-4.33-3.56zm2.95-8H5.08c.96-1.66 2.49-2.93 4.33-3.56C8.81 5.55 8.35 6.75 8.03 8zM12 19.96c-.83-1.2-1.48-2.53-1.91-3.96h3.82c-.43 1.43-1.08 2.76-1.91 3.96zM14.34 14H9.66c-.09-.66-.16-1.32-.16-2 0-.68.07-1.35.16-2h4.68c.09.65.16 1.32.16 2 0 .68-.07 1.34-.16 2zm.25 5.56c.6-1.11 1.06-2.31 1.38-3.56h2.95c-.96 1.65-2.49 2.93-4.33 3.56zM16.36 14c.08-.66.14-1.32.14-2 0-.68-.06-1.34-.14-2h3.38c.16.64.26 1.31.26 2s-.1 1.36-.26 2h-3.38z"/></svg></button><style data-emotion="css t5gsfy">.css-t5gsfy{text-transform:none;font-family:-apple-system,"Poppins","Helvetica Neue",sans-serif,"Noto Sans","Fira Code","IBM Plex Sans","sans-serif";font-weight:500;font-size:0.875rem;line-height:1.75;min-width:64px;padding:6px 8px;border-radius:4px;-webkit-transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;color:inherit;border-color:currentColor;box-shadow:none;}.css-t5gsfy:hover{-webkit-text-decoration:none;text-decoration:none;background-color:rgba(0, 0, 0, 0.04);}@media (hover: none){.css-t5gsfy:hover{background-color:transparent;}}.css-t5gsfy.Mui-disabled{color:rgba(0, 0, 0, 0.26);}.css-t5gsfy:hover{box-shadow:none;}.css-t5gsfy.Mui-focusVisible{box-shadow:none;}.css-t5gsfy:active{box-shadow:none;}.css-t5gsfy.Mui-disabled{box-shadow:none;}@media (min-width:0px){.css-t5gsfy{;}}@media (min-width:1200px){.css-t5gsfy{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;}}</style><style data-emotion="css 1csz7wa">.css-1csz7wa{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;position:relative;box-sizing:border-box;-webkit-tap-highlight-color:transparent;background-color:transparent;outline:0;border:0;margin:0;border-radius:0;padding:0;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;vertical-align:middle;-moz-appearance:none;-webkit-appearance:none;-webkit-text-decoration:none;text-decoration:none;color:inherit;text-transform:none;font-family:-apple-system,"Poppins","Helvetica Neue",sans-serif,"Noto Sans","Fira Code","IBM Plex Sans","sans-serif";font-weight:500;font-size:0.875rem;line-height:1.75;min-width:64px;padding:6px 8px;border-radius:4px;-webkit-transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;color:inherit;border-color:currentColor;box-shadow:none;}.css-1csz7wa::-moz-focus-inner{border-style:none;}.css-1csz7wa.Mui-disabled{pointer-events:none;cursor:default;}@media print{.css-1csz7wa{-webkit-print-color-adjust:exact;color-adjust:exact;}}.css-1csz7wa:hover{-webkit-text-decoration:none;text-decoration:none;background-color:rgba(0, 0, 0, 0.04);}@media (hover: none){.css-1csz7wa:hover{background-color:transparent;}}.css-1csz7wa.Mui-disabled{color:rgba(0, 0, 0, 0.26);}.css-1csz7wa:hover{box-shadow:none;}.css-1csz7wa.Mui-focusVisible{box-shadow:none;}.css-1csz7wa:active{box-shadow:none;}.css-1csz7wa.Mui-disabled{box-shadow:none;}@media (min-width:0px){.css-1csz7wa{;}}@media (min-width:1200px){.css-1csz7wa{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;}}</style><button class="MuiButtonBase-root MuiButton-root MuiButton-text MuiButton-textInherit MuiButton-sizeMedium MuiButton-textSizeMedium MuiButton-colorInherit MuiButton-disableElevation css-1csz7wa" tabindex="0" type="button" id="header-lang-switch" aria-haspopup="true"><span class="MuiButton-startIcon MuiButton-iconSizeMedium css-6xugel"><style data-emotion="css 1slalk2">.css-1slalk2{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;width:1em;height:1em;display:inline-block;fill:currentColor;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;-webkit-transition:fill 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:fill 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;font-size:1.5rem;fill:#282a36;}</style><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-1slalk2" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="LanguageIcon"><path d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zm6.93 6h-2.95c-.32-1.25-.78-2.45-1.38-3.56 1.84.63 3.37 1.91 4.33 3.56zM12 4.04c.83 1.2 1.48 2.53 1.91 3.96h-3.82c.43-1.43 1.08-2.76 1.91-3.96zM4.26 14C4.1 13.36 4 12.69 4 12s.1-1.36.26-2h3.38c-.08.66-.14 1.32-.14 2 0 .68.06 1.34.14 2H4.26zm.82 2h2.95c.32 1.25.78 2.45 1.38 3.56-1.84-.63-3.37-1.9-4.33-3.56zm2.95-8H5.08c.96-1.66 2.49-2.93 4.33-3.56C8.81 5.55 8.35 6.75 8.03 8zM12 19.96c-.83-1.2-1.48-2.53-1.91-3.96h3.82c-.43 1.43-1.08 2.76-1.91 3.96zM14.34 14H9.66c-.09-.66-.16-1.32-.16-2 0-.68.07-1.35.16-2h4.68c.09.65.16 1.32.16 2 0 .68-.07 1.34-.16 2zm.25 5.56c.6-1.11 1.06-2.31 1.38-3.56h2.95c-.96 1.65-2.49 2.93-4.33 3.56zM16.36 14c.08-.66.14-1.32.14-2 0-.68-.06-1.34-.14-2h3.38c.16.64.26 1.31.26 2s-.1 1.36-.26 2h-3.38z"/></svg></span><style data-emotion="css 15r93eu">.css-15r93eu{margin:0;font-size:1rem;line-height:1.5rem;font-family:"Helvetica Neue","sans-serif";font-weight:400;font-style:normal;color:#666666;color:inherit;}</style><span class="MuiTypography-root MuiTypography-body1 css-15r93eu">语言</span><span class="MuiButton-endIcon MuiButton-iconSizeMedium css-1n4a93h"><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-1slalk2" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="KeyboardArrowDownIcon"><path d="M7.41 8.59 12 13.17l4.59-4.58L18 10l-6 6-6-6 1.41-1.41z"/></svg></span></button></div><button class="MuiButtonBase-root MuiIconButton-root MuiIconButton-sizeMedium css-iuftj9" tabindex="0" type="button"><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="SearchIcon"><path d="M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z"/></svg></button><style data-emotion="css ahtg4s">.css-ahtg4s{max-width:13rem;}@media (min-width:0px){.css-ahtg4s{;}}@media (min-width:1200px){.css-ahtg4s{display:block;}}</style><form class="MuiBox-root css-ahtg4s" novalidate="" autocomplete="off"><style data-emotion="css 24u6h2">.css-24u6h2 .MuiOutlinedInput-root:hover fieldset{border-color:#0ca6f2;border-width:1px;}.css-24u6h2 .MuiOutlinedInput-root.Mui-focused fieldset{border-color:#0ca6f2;border-width:1px;}</style><style data-emotion="css fzbqas">.css-fzbqas .MuiOutlinedInput-root:hover fieldset{border-color:#0ca6f2;border-width:1px;}.css-fzbqas .MuiOutlinedInput-root.Mui-focused fieldset{border-color:#0ca6f2;border-width:1px;}</style><style data-emotion="css bj7gct">.css-bj7gct{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;position:relative;min-width:0;padding:0;margin:0;border:0;vertical-align:top;width:100%;}.css-bj7gct .MuiOutlinedInput-root:hover fieldset{border-color:#0ca6f2;border-width:1px;}.css-bj7gct .MuiOutlinedInput-root.Mui-focused fieldset{border-color:#0ca6f2;border-width:1px;}</style><div class="MuiFormControl-root MuiFormControl-fullWidth MuiTextField-root css-bj7gct"><style data-emotion="css-global 1prfaxn">@-webkit-keyframes mui-auto-fill{from{display:block;}}@keyframes mui-auto-fill{from{display:block;}}@-webkit-keyframes mui-auto-fill-cancel{from{display:block;}}@keyframes mui-auto-fill-cancel{from{display:block;}}</style><style data-emotion="css sv5gtw">.css-sv5gtw{font-size:1rem;line-height:1.4375em;font-family:"Helvetica Neue","sans-serif";font-weight:400;font-style:normal;color:rgba(0, 0, 0, 0.87);box-sizing:border-box;position:relative;cursor:text;display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;width:100%;position:relative;border-radius:4px;padding-left:14px;background:#fff;}.css-sv5gtw.Mui-disabled{color:rgba(0, 0, 0, 0.38);cursor:default;}.css-sv5gtw:hover .MuiOutlinedInput-notchedOutline{border-color:rgba(0, 0, 0, 0.87);}@media (hover: none){.css-sv5gtw:hover .MuiOutlinedInput-notchedOutline{border-color:rgba(0, 0, 0, 0.23);}}.css-sv5gtw.Mui-focused .MuiOutlinedInput-notchedOutline{border-color:#1976d2;border-width:2px;}.css-sv5gtw.Mui-error .MuiOutlinedInput-notchedOutline{border-color:#d32f2f;}.css-sv5gtw.Mui-disabled .MuiOutlinedInput-notchedOutline{border-color:rgba(0, 0, 0, 0.26);}</style><div class="MuiInputBase-root MuiOutlinedInput-root MuiInputBase-colorPrimary MuiInputBase-fullWidth MuiInputBase-formControl MuiInputBase-sizeSmall MuiInputBase-adornedStart css-sv5gtw"><style data-emotion="css 1a6giau">.css-1a6giau{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;height:0.01em;max-height:2em;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;white-space:nowrap;color:rgba(0, 0, 0, 0.54);margin-right:8px;}</style><div class="MuiInputAdornment-root MuiInputAdornment-positionStart MuiInputAdornment-outlined MuiInputAdornment-sizeSmall css-1a6giau"><span class="notranslate"></span><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-vubbuv" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="SearchIcon"><path d="M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z"/></svg></div><style data-emotion="css f2zrvi">.css-f2zrvi{font:inherit;letter-spacing:inherit;color:currentColor;padding:4px 0 5px;border:0;box-sizing:content-box;background:none;height:1.4375em;margin:0;-webkit-tap-highlight-color:transparent;display:block;min-width:0;width:100%;-webkit-animation-name:mui-auto-fill-cancel;animation-name:mui-auto-fill-cancel;-webkit-animation-duration:10ms;animation-duration:10ms;padding-top:1px;-moz-appearance:textfield;padding:8.5px 14px;padding-left:0;}.css-f2zrvi::-webkit-input-placeholder{color:currentColor;opacity:0.42;-webkit-transition:opacity 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:opacity 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;}.css-f2zrvi::-moz-placeholder{color:currentColor;opacity:0.42;-webkit-transition:opacity 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:opacity 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;}.css-f2zrvi:-ms-input-placeholder{color:currentColor;opacity:0.42;-webkit-transition:opacity 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:opacity 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;}.css-f2zrvi::-ms-input-placeholder{color:currentColor;opacity:0.42;-webkit-transition:opacity 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:opacity 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;}.css-f2zrvi:focus{outline:0;}.css-f2zrvi:invalid{box-shadow:none;}.css-f2zrvi::-webkit-search-decoration{-webkit-appearance:none;}label[data-shrink=false]+.MuiInputBase-formControl .css-f2zrvi::-webkit-input-placeholder{opacity:0!important;}label[data-shrink=false]+.MuiInputBase-formControl .css-f2zrvi::-moz-placeholder{opacity:0!important;}label[data-shrink=false]+.MuiInputBase-formControl .css-f2zrvi:-ms-input-placeholder{opacity:0!important;}label[data-shrink=false]+.MuiInputBase-formControl .css-f2zrvi::-ms-input-placeholder{opacity:0!important;}label[data-shrink=false]+.MuiInputBase-formControl .css-f2zrvi:focus::-webkit-input-placeholder{opacity:0.42;}label[data-shrink=false]+.MuiInputBase-formControl .css-f2zrvi:focus::-moz-placeholder{opacity:0.42;}label[data-shrink=false]+.MuiInputBase-formControl .css-f2zrvi:focus:-ms-input-placeholder{opacity:0.42;}label[data-shrink=false]+.MuiInputBase-formControl .css-f2zrvi:focus::-ms-input-placeholder{opacity:0.42;}.css-f2zrvi.Mui-disabled{opacity:1;-webkit-text-fill-color:rgba(0, 0, 0, 0.38);}.css-f2zrvi:-webkit-autofill{-webkit-animation-duration:5000s;animation-duration:5000s;-webkit-animation-name:mui-auto-fill;animation-name:mui-auto-fill;}.css-f2zrvi:-webkit-autofill{border-radius:inherit;}</style><input type="search" aria-invalid="false" id="doc-search" placeholder="搜索文档" value="" class="MuiInputBase-input MuiOutlinedInput-input MuiInputBase-inputTypeSearch MuiInputBase-inputSizeSmall MuiInputBase-inputAdornedStart css-f2zrvi"/><style data-emotion="css 19w1uun">.css-19w1uun{border-color:rgba(0, 0, 0, 0.23);}</style><style data-emotion="css igs3ac">.css-igs3ac{text-align:left;bottom:0;right:0;top:-5px;left:0;margin:0;padding:0 8px;pointer-events:none;border-radius:inherit;border-style:solid;border-width:1px;overflow:hidden;min-width:0%;border-color:rgba(0, 0, 0, 0.23);}</style><fieldset aria-hidden="true" class="MuiOutlinedInput-notchedOutline css-igs3ac"><style data-emotion="css hdw1oc">.css-hdw1oc{float:unset;overflow:hidden;padding:0;line-height:11px;-webkit-transition:width 150ms cubic-bezier(0.0, 0, 0.2, 1) 0ms;transition:width 150ms cubic-bezier(0.0, 0, 0.2, 1) 0ms;}</style><legend class="css-hdw1oc"><span class="notranslate"></span></legend></fieldset></div></div></form></div></div></header><style data-emotion="css s1brf2">.css-s1brf2{margin-top:5rem;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}</style><div class="PingCAP-Doc MuiBox-root css-s1brf2"><style data-emotion="css hboir5">.css-hboir5{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;width:100%;}</style><div class="MuiBox-root css-hboir5"><style data-emotion="css 2tzg8">.css-2tzg8{width:18.75rem;border-right:1px solid #E5E4E4;}@media (min-width:0px){.css-2tzg8{;}}@media (min-width:1200px){.css-2tzg8{display:block;}}</style><aside class="MuiBox-root css-2tzg8"><style data-emotion="css 1eohm8p">.css-1eohm8p{position:-webkit-sticky;position:sticky;top:5rem;height:100%;max-height:calc(100vh - 7rem);overflow-y:auto;padding:1rem;}</style><div class="MuiBox-root css-1eohm8p"><style data-emotion="css fmyu0n">.css-fmyu0n{text-transform:none;font-family:-apple-system,"Poppins","Helvetica Neue",sans-serif,"Noto Sans","Fira Code","IBM Plex Sans","sans-serif";font-weight:500;font-size:0.875rem;line-height:1.75;min-width:64px;padding:6px 8px;border-radius:4px;-webkit-transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;color:#1976d2;width:100%;height:2rem;-webkit-box-pack:justify;-webkit-justify-content:space-between;justify-content:space-between;border-style:solid;border-width:1px;border-color:#e5e5e5;margin-bottom:1rem;}.css-fmyu0n:hover{-webkit-text-decoration:none;text-decoration:none;background-color:rgba(25, 118, 210, 0.04);}@media (hover: none){.css-fmyu0n:hover{background-color:transparent;}}.css-fmyu0n.Mui-disabled{color:rgba(0, 0, 0, 0.26);}</style><style data-emotion="css 1rq233s">.css-1rq233s{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;position:relative;box-sizing:border-box;-webkit-tap-highlight-color:transparent;background-color:transparent;outline:0;border:0;margin:0;border-radius:0;padding:0;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;vertical-align:middle;-moz-appearance:none;-webkit-appearance:none;-webkit-text-decoration:none;text-decoration:none;color:inherit;text-transform:none;font-family:-apple-system,"Poppins","Helvetica Neue",sans-serif,"Noto Sans","Fira Code","IBM Plex Sans","sans-serif";font-weight:500;font-size:0.875rem;line-height:1.75;min-width:64px;padding:6px 8px;border-radius:4px;-webkit-transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,border-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;color:#1976d2;width:100%;height:2rem;-webkit-box-pack:justify;-webkit-justify-content:space-between;justify-content:space-between;border-style:solid;border-width:1px;border-color:#e5e5e5;margin-bottom:1rem;}.css-1rq233s::-moz-focus-inner{border-style:none;}.css-1rq233s.Mui-disabled{pointer-events:none;cursor:default;}@media print{.css-1rq233s{-webkit-print-color-adjust:exact;color-adjust:exact;}}.css-1rq233s:hover{-webkit-text-decoration:none;text-decoration:none;background-color:rgba(25, 118, 210, 0.04);}@media (hover: none){.css-1rq233s:hover{background-color:transparent;}}.css-1rq233s.Mui-disabled{color:rgba(0, 0, 0, 0.26);}</style><button class="MuiButtonBase-root MuiButton-root MuiButton-text MuiButton-textPrimary MuiButton-sizeMedium MuiButton-textSizeMedium css-1rq233s" tabindex="0" type="button" id="version-select-button" aria-haspopup="true"><style data-emotion="css 3cb5vr">.css-3cb5vr{margin:0;font-size:1rem;line-height:1.5rem;font-family:"Helvetica Neue","sans-serif";font-weight:400;font-style:normal;color:#666666;padding:0 0.25rem;font-size:0.875rem;line-height:1.25rem;}</style><div class="MuiTypography-root MuiTypography-body1 css-3cb5vr">v8.1</div><style data-emotion="css 1n4a93h">.css-1n4a93h{display:inherit;margin-right:-4px;margin-left:8px;}.css-1n4a93h>*:nth-of-type(1){font-size:20px;}</style><span class="MuiButton-endIcon MuiButton-iconSizeMedium css-1n4a93h"><style data-emotion="css b5l66">.css-b5l66{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;width:1em;height:1em;display:inline-block;fill:currentColor;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;-webkit-transition:fill 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:fill 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;font-size:1.5rem;-webkit-transform:rotate(0deg);-moz-transform:rotate(0deg);-ms-transform:rotate(0deg);transform:rotate(0deg);height:1.5rem;width:1.5rem;fill:#999999;margin-right:0.25rem;}</style><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium css-b5l66" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ChevronRightIcon"><path d="M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></svg></span></button><style data-emotion="css 1c58svf">.css-1c58svf .MuiPaper-root{border-radius:6px;margin-top:8px;min-width:268px;color:rgb(55, 65, 81);box-shadow:rgb(255, 255, 255) 0px 0px 0px 0px,rgba(0, 0, 0, 0.05) 0px 0px 0px 1px,rgba(0, 0, 0, 0.1) 0px 10px 15px -3px,rgba(0, 0, 0, 0.05) 0px 4px 6px -2px;}.css-1c58svf .MuiPaper-root .MuiMenu-list{padding:4px 0;}.css-1c58svf .MuiPaper-root .MuiMenuItem-root .MuiSvgIcon-root{font-size:18px;color:rgba(0, 0, 0, 0.6);margin-right:12px;}.css-1c58svf .MuiPaper-root .MuiMenuItem-root:active{background-color:rgba(25, 118, 210, 0.08);}</style><style data-emotion="css yvxbj">.css-yvxbj .MuiPaper-root{border-radius:6px;margin-top:8px;min-width:268px;color:rgb(55, 65, 81);box-shadow:rgb(255, 255, 255) 0px 0px 0px 0px,rgba(0, 0, 0, 0.05) 0px 0px 0px 1px,rgba(0, 0, 0, 0.1) 0px 10px 15px -3px,rgba(0, 0, 0, 0.05) 0px 4px 6px -2px;}.css-yvxbj .MuiPaper-root .MuiMenu-list{padding:4px 0;}.css-yvxbj .MuiPaper-root .MuiMenuItem-root .MuiSvgIcon-root{font-size:18px;color:rgba(0, 0, 0, 0.6);margin-right:12px;}.css-yvxbj .MuiPaper-root .MuiMenuItem-root:active{background-color:rgba(25, 118, 210, 0.08);}</style><style data-emotion="css oe3wem">.css-oe3wem .MuiPaper-root{border-radius:6px;margin-top:8px;min-width:268px;color:rgb(55, 65, 81);box-shadow:rgb(255, 255, 255) 0px 0px 0px 0px,rgba(0, 0, 0, 0.05) 0px 0px 0px 1px,rgba(0, 0, 0, 0.1) 0px 10px 15px -3px,rgba(0, 0, 0, 0.05) 0px 4px 6px -2px;}.css-oe3wem .MuiPaper-root .MuiMenu-list{padding:4px 0;}.css-oe3wem .MuiPaper-root .MuiMenuItem-root .MuiSvgIcon-root{font-size:18px;color:rgba(0, 0, 0, 0.6);margin-right:12px;}.css-oe3wem .MuiPaper-root .MuiMenuItem-root:active{background-color:rgba(25, 118, 210, 0.08);}</style><style data-emotion="css 12mehxg">.css-12mehxg{padding:0;margin:0;list-style:none;outline:0;}</style><ul role="tree" id="left-nav-treeview" aria-multiselectable="false" class="MuiTreeView-root css-12mehxg" tabindex="0" aria-label="left navigation"><style data-emotion="css 1gesgke">.css-1gesgke .MuiTreeItem-content{color:#282a36;border-radius:4px;}.css-1gesgke .MuiTreeItem-content:hover{background-color:#f9f9f9;}.css-1gesgke .MuiTreeItem-content.Mui-selected,.css-1gesgke .MuiTreeItem-content.Mui-selected.Mui-focused{background-color:var(--tree-view-bg-color, #EAF6FB);color:var(--tree-view-color, #0A85C2);}.css-1gesgke .MuiTreeItem-content.Mui-selected svg.MuiTreeItem-ChevronRightIcon,.css-1gesgke .MuiTreeItem-content.Mui-selected.Mui-focused svg.MuiTreeItem-ChevronRightIcon{fill:var(--tree-view-color, #0A85C2);}.css-1gesgke .MuiTreeItem-content.Mui-focused{background-color:#f9f9f9;}.css-1gesgke .MuiTreeItem-content .MuiTreeItem-label{font-weight:inherit;color:inherit;}.css-1gesgke .MuiTreeItem-content .MuiTreeItem-iconContainer{;}.css-1gesgke .MuiTreeItem-group{margin-left:0;}.css-1gesgke .MuiTreeItem-group .MuiTreeItem-content{padding-left:16px;}</style><style data-emotion="css 1oy5rnm">.css-1oy5rnm{list-style:none;margin:0;padding:0;outline:0;}.css-1oy5rnm .MuiTreeItem-content{color:#282a36;border-radius:4px;}.css-1oy5rnm .MuiTreeItem-content:hover{background-color:#f9f9f9;}.css-1oy5rnm .MuiTreeItem-content.Mui-selected,.css-1oy5rnm .MuiTreeItem-content.Mui-selected.Mui-focused{background-color:var(--tree-view-bg-color, #EAF6FB);color:var(--tree-view-color, #0A85C2);}.css-1oy5rnm .MuiTreeItem-content.Mui-selected svg.MuiTreeItem-ChevronRightIcon,.css-1oy5rnm .MuiTreeItem-content.Mui-selected.Mui-focused svg.MuiTreeItem-ChevronRightIcon{fill:var(--tree-view-color, #0A85C2);}.css-1oy5rnm .MuiTreeItem-content.Mui-focused{background-color:#f9f9f9;}.css-1oy5rnm .MuiTreeItem-content .MuiTreeItem-label{font-weight:inherit;color:inherit;}.css-1oy5rnm .MuiTreeItem-content .MuiTreeItem-iconContainer{;}.css-1oy5rnm .MuiTreeItem-group{margin-left:0;}.css-1oy5rnm .MuiTreeItem-group .MuiTreeItem-content{padding-left:16px;}</style><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" id="left-nav-treeview-0-0" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><style data-emotion="css khel7y">.css-khel7y{padding:0 8px;width:100%;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;cursor:pointer;-webkit-tap-highlight-color:transparent;}.css-khel7y:hover{background-color:rgba(0, 0, 0, 0.04);}@media (hover: none){.css-khel7y:hover{background-color:transparent;}}.css-khel7y.Mui-disabled{opacity:0.38;background-color:transparent;}.css-khel7y.Mui-focused{background-color:rgba(0, 0, 0, 0.12);}.css-khel7y.Mui-selected{background-color:rgba(25, 118, 210, 0.08);}.css-khel7y.Mui-selected:hover{background-color:rgba(25, 118, 210, 0.12);}@media (hover: none){.css-khel7y.Mui-selected:hover{background-color:rgba(25, 118, 210, 0.08);}}.css-khel7y.Mui-selected.Mui-focused{background-color:rgba(25, 118, 210, 0.2);}.css-khel7y .MuiTreeItem-iconContainer{margin-right:4px;width:15px;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;}.css-khel7y .MuiTreeItem-iconContainer svg{font-size:18px;}.css-khel7y .MuiTreeItem-label{width:100%;min-width:0;padding-left:4px;position:relative;font-size:1rem;line-height:1.5rem;font-family:"Helvetica Neue","sans-serif";font-weight:400;font-style:normal;color:#666666;}</style><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><style data-emotion="css znl8a3">.css-znl8a3{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;min-height:1.75rem;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;padding-left:0rem;padding-top:0.25rem;padding-bottom:0.25rem;}</style><div class="css-znl8a3"><style data-emotion="css tx8jsd">.css-tx8jsd{margin:0;font-size:1rem;line-height:1.5rem;font-family:"Helvetica Neue","sans-serif";font-weight:400;font-style:normal;color:#666666;}</style><a class="MuiTypography-root MuiTypography-body1 css-tx8jsd" target="_blank" href="https://docs.pingcap.com/zh" style="text-decoration:none;width:100%;color:inherit"><style data-emotion="css 8atqhb">.css-8atqhb{width:100%;}</style><div class="MuiBox-root css-8atqhb"><style data-emotion="css 1hwyipb">.css-1hwyipb{margin:0;font-size:1rem;line-height:1.5rem;font-family:"Helvetica Neue","sans-serif";font-weight:400;font-style:normal;color:#666666;color:inherit;font-size:0.875rem;line-height:1.25rem;}</style><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">文档中心</div></div></a></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" aria-expanded="false" id="left-nav-treeview-0-1" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-znl8a3"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">关于 TiDB</div></div><style data-emotion="css xjq79n">.css-xjq79n{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;width:1em;height:1em;display:inline-block;fill:currentColor;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;-webkit-transition:fill 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:fill 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;font-size:1.5rem;fill:#999999;height:1rem;width:1rem;margin-left:auto;-webkit-transform:none;-moz-transform:none;-ms-transform:none;transform:none;}</style><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium MuiTreeItem-ChevronRightIcon css-xjq79n" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ChevronRightIcon"><path d="M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></svg></div></div></div><style data-emotion="css 1jozaee">.css-1jozaee{margin:0;padding:0;margin-left:17px;}</style></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" aria-expanded="false" id="left-nav-treeview-0-2" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-znl8a3"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">快速上手</div></div><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium MuiTreeItem-ChevronRightIcon css-xjq79n" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ChevronRightIcon"><path d="M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></svg></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" aria-expanded="false" id="left-nav-treeview-0-3" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-znl8a3"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">应用开发</div></div><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium MuiTreeItem-ChevronRightIcon css-xjq79n" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ChevronRightIcon"><path d="M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></svg></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" aria-expanded="false" id="left-nav-treeview-0-4" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-znl8a3"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">部署标准集群</div></div><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium MuiTreeItem-ChevronRightIcon css-xjq79n" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ChevronRightIcon"><path d="M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></svg></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" aria-expanded="false" id="left-nav-treeview-0-5" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-znl8a3"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">数据迁移</div></div><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium MuiTreeItem-ChevronRightIcon css-xjq79n" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ChevronRightIcon"><path d="M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></svg></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" aria-expanded="false" id="left-nav-treeview-0-6" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-znl8a3"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">数据集成</div></div><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium MuiTreeItem-ChevronRightIcon css-xjq79n" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ChevronRightIcon"><path d="M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></svg></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" aria-expanded="false" id="left-nav-treeview-0-7" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-znl8a3"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">运维操作</div></div><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium MuiTreeItem-ChevronRightIcon css-xjq79n" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ChevronRightIcon"><path d="M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></svg></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" aria-expanded="false" id="left-nav-treeview-0-8" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-znl8a3"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">监控与告警</div></div><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium MuiTreeItem-ChevronRightIcon css-xjq79n" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ChevronRightIcon"><path d="M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></svg></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" aria-expanded="false" id="left-nav-treeview-0-9" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-znl8a3"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">故障诊断</div></div><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium MuiTreeItem-ChevronRightIcon css-xjq79n" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ChevronRightIcon"><path d="M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></svg></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" aria-expanded="false" id="left-nav-treeview-0-10" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-znl8a3"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">性能调优</div></div><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium MuiTreeItem-ChevronRightIcon css-xjq79n" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ChevronRightIcon"><path d="M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></svg></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" aria-expanded="true" id="left-nav-treeview-0-11" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content Mui-expanded" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-znl8a3"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">教程</div></div><style data-emotion="css 171pefp">.css-171pefp{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;width:1em;height:1em;display:inline-block;fill:currentColor;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;-webkit-transition:fill 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:fill 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;font-size:1.5rem;fill:#999999;height:1rem;width:1rem;margin-left:auto;-webkit-transform:rotate(90deg);-moz-transform:rotate(90deg);-ms-transform:rotate(90deg);transform:rotate(90deg);}</style><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium MuiTreeItem-ChevronRightIcon css-171pefp" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ChevronRightIcon"><path d="M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></svg></div></div></div><style data-emotion="css 1xxsnna">.css-1xxsnna{height:auto;overflow:visible;-webkit-transition:height 300ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:height 300ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;margin:0;padding:0;margin-left:17px;}</style><ul class="MuiCollapse-root MuiCollapse-vertical MuiTreeItem-group MuiCollapse-entered css-1xxsnna" style="min-height:0px" role="group"><div class="MuiCollapse-wrapper MuiCollapse-vertical css-hboir5"><div class="MuiCollapse-wrapperInner MuiCollapse-vertical css-8atqhb"><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" id="left-nav-treeview-0-11-0" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><style data-emotion="css kb2j4b">.css-kb2j4b{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;min-height:1.75rem;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;padding-left:0.5rem;padding-top:0.25rem;padding-bottom:0.25rem;}</style><div class="css-kb2j4b"><a style="text-decoration:none;width:100%;color:inherit" href="/zh/tidb/stable/multi-data-centers-in-one-city-deployment"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">单区域多 AZ 部署</div></div></a></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" id="left-nav-treeview-0-11-1" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-kb2j4b"><a style="text-decoration:none;width:100%;color:inherit" href="/zh/tidb/stable/three-data-centers-in-two-cities-deployment"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">双区域多 AZ 部署</div></div></a></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" id="left-nav-treeview-0-11-2" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-kb2j4b"><a style="text-decoration:none;width:100%;color:inherit" href="/zh/tidb/stable/two-data-centers-in-one-city-deployment"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">单区域双 AZ 部署</div></div></a></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" aria-expanded="false" id="left-nav-treeview-0-11-3" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-kb2j4b"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">读取历史数据</div></div><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium MuiTreeItem-ChevronRightIcon css-xjq79n" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ChevronRightIcon"><path d="M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></svg></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" aria-expanded="true" id="left-nav-treeview-0-11-4" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content Mui-expanded" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-kb2j4b"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">最佳实践</div></div><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium MuiTreeItem-ChevronRightIcon css-171pefp" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ChevronRightIcon"><path d="M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></svg></div></div></div><ul class="MuiCollapse-root MuiCollapse-vertical MuiTreeItem-group MuiCollapse-entered css-1xxsnna" style="min-height:0px" role="group"><div class="MuiCollapse-wrapper MuiCollapse-vertical css-hboir5"><div class="MuiCollapse-wrapperInner MuiCollapse-vertical css-8atqhb"><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" id="left-nav-treeview-0-11-4-0" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><style data-emotion="css snygwd">.css-snygwd{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;min-height:1.75rem;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;padding-left:1rem;padding-top:0.25rem;padding-bottom:0.25rem;}</style><div class="css-snygwd"><a style="text-decoration:none;width:100%;color:inherit" href="/zh/tidb/stable/tidb-best-practices"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">TiDB 最佳实践</div></div></a></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" id="left-nav-treeview-0-11-4-1" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-snygwd"><a style="text-decoration:none;width:100%;color:inherit" href="/zh/tidb/stable/java-app-best-practices"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">Java 应用开发最佳实践</div></div></a></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" id="left-nav-treeview-0-11-4-2" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-snygwd"><a style="text-decoration:none;width:100%;color:inherit" href="/zh/tidb/stable/haproxy-best-practices"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">HAProxy 最佳实践</div></div></a></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" id="left-nav-treeview-0-11-4-3" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content Mui-expanded" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-snygwd"><a aria-current="page" style="text-decoration:none;width:100%;color:inherit" class="" href="/zh/tidb/stable/high-concurrency-best-practices"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">高并发写入场景最佳实践</div></div></a></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" id="left-nav-treeview-0-11-4-4" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-snygwd"><a style="text-decoration:none;width:100%;color:inherit" href="/zh/tidb/stable/grafana-monitor-best-practices"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">Grafana 监控最佳实践</div></div></a></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" id="left-nav-treeview-0-11-4-5" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-snygwd"><a style="text-decoration:none;width:100%;color:inherit" href="/zh/tidb/stable/pd-scheduling-best-practices"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">PD 调度策略最佳实践</div></div></a></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" id="left-nav-treeview-0-11-4-6" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-snygwd"><a style="text-decoration:none;width:100%;color:inherit" href="/zh/tidb/stable/massive-regions-best-practices"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">海量 Region 集群调优</div></div></a></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" id="left-nav-treeview-0-11-4-7" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-snygwd"><a style="text-decoration:none;width:100%;color:inherit" href="/zh/tidb/stable/three-nodes-hybrid-deployment"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">三节点混合部署最佳实践</div></div></a></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" id="left-nav-treeview-0-11-4-8" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-snygwd"><a style="text-decoration:none;width:100%;color:inherit" href="/zh/tidb/stable/three-dc-local-read"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">在三数据中心下就近读取数据</div></div></a></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" id="left-nav-treeview-0-11-4-9" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-snygwd"><a style="text-decoration:none;width:100%;color:inherit" href="/zh/tidb/stable/uuid"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">使用 UUID</div></div></a></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" id="left-nav-treeview-0-11-4-10" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-snygwd"><a style="text-decoration:none;width:100%;color:inherit" href="/zh/tidb/stable/readonly-nodes"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">只读存储节点最佳实践</div></div></a></div></div></div></li></div></div></ul></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" id="left-nav-treeview-0-11-5" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-kb2j4b"><a style="text-decoration:none;width:100%;color:inherit" href="/zh/tidb/stable/configure-placement-rules"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">Placement Rules 使用文档</div></div></a></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" id="left-nav-treeview-0-11-6" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-kb2j4b"><a style="text-decoration:none;width:100%;color:inherit" href="/zh/tidb/stable/configure-load-base-split"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">Load Base Split 使用文档</div></div></a></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" id="left-nav-treeview-0-11-7" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-kb2j4b"><a style="text-decoration:none;width:100%;color:inherit" href="/zh/tidb/stable/configure-store-limit"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">Store Limit 使用文档</div></div></a></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" id="left-nav-treeview-0-11-8" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-kb2j4b"><a style="text-decoration:none;width:100%;color:inherit" href="/zh/tidb/stable/ddl-introduction"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">DDL 执行原理及最佳实践</div></div></a></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" id="left-nav-treeview-0-11-9" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-kb2j4b"><a style="text-decoration:none;width:100%;color:inherit" href="/zh/tidb/stable/pd-microservices"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">PD 微服务使用文档</div></div></a></div></div></div></li></div></div></ul></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" aria-expanded="false" id="left-nav-treeview-0-12" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-znl8a3"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">TiDB 工具</div></div><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium MuiTreeItem-ChevronRightIcon css-xjq79n" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ChevronRightIcon"><path d="M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></svg></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" aria-expanded="false" id="left-nav-treeview-0-13" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-znl8a3"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">参考指南</div></div><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium MuiTreeItem-ChevronRightIcon css-xjq79n" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ChevronRightIcon"><path d="M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></svg></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" aria-expanded="false" id="left-nav-treeview-0-14" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-znl8a3"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">常见问题解答 (FAQ)</div></div><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium MuiTreeItem-ChevronRightIcon css-xjq79n" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ChevronRightIcon"><path d="M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></svg></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" aria-expanded="false" id="left-nav-treeview-0-15" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-znl8a3"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">版本发布历史</div></div><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeMedium MuiTreeItem-ChevronRightIcon css-xjq79n" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ChevronRightIcon"><path d="M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/></svg></div></div></div></li><li class="MuiTreeItem-root css-1oy5rnm" role="treeitem" id="left-nav-treeview-0-16" tabindex="-1" style="margin-top:0.1875rem;margin-bottom:0.1875rem"><div class="css-khel7y MuiTreeItem-content" style="width:inherit"><div class="MuiTreeItem-iconContainer"/><div class="MuiTreeItem-label"><div class="css-znl8a3"><a style="text-decoration:none;width:100%;color:inherit" href="/zh/tidb/stable/glossary"><div class="MuiBox-root css-8atqhb"><div class="MuiTypography-root MuiTypography-body1 css-1hwyipb">术语表</div></div></a></div></div></div></li></ul></div></aside><style data-emotion="css sb2sd0">.css-sb2sd0{width:100%;}@media (min-width:1200px){.css-sb2sd0{max-width:calc(100% - 18.75rem);}}</style><main class="MuiBox-root css-sb2sd0"><style data-emotion="css 1rnnmjb">.css-1rnnmjb{max-width:1340px;width:100%;margin-left:auto;margin-right:auto;display:block;box-sizing:border-box;}</style><div class="MuiBox-root css-1rnnmjb"><style data-emotion="css 90fn5w">.css-90fn5w{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}@media (min-width:0px){.css-90fn5w{-webkit-flex-direction:column-reverse;-ms-flex-direction:column-reverse;flex-direction:column-reverse;}}@media (min-width:600px){.css-90fn5w{-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;}}</style><div class="css-90fn5w"><style data-emotion="css vofosd">.css-vofosd{padding:1.5rem 0;}@media (min-width:0px){.css-vofosd{width:100%;}}@media (min-width:600px){.css-vofosd{width:calc(100% - 17.5rem);}}</style><div class="MuiBox-root css-vofosd"><style data-emotion="css 1ekb41w">.css-1ekb41w{width:100%;margin-left:auto;box-sizing:border-box;margin-right:auto;display:block;padding-left:16px;padding-right:16px;}@media (min-width:600px){.css-1ekb41w{padding-left:24px;padding-right:24px;}}@media (min-width:1536px){.css-1ekb41w{max-width:1536px;}}</style><div class="MuiContainer-root MuiContainer-maxWidthXl doc-content css-1ekb41w"><div class="markdown-body MuiBox-root css-0"><h1 id="tidb-高并发写入场景最佳实践" style="position:relative"><a href="#tidb-%E9%AB%98%E5%B9%B6%E5%8F%91%E5%86%99%E5%85%A5%E5%9C%BA%E6%99%AF%E6%9C%80%E4%BD%B3%E5%AE%9E%E8%B7%B5" aria-label="tidb 高并发写入场景最佳实践 permalink" class="anchor before"><svg aria-hidden="true" focusable="false" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"/></svg></a>TiDB 高并发写入场景最佳实践</h1><p>在 TiDB 的使用过程中,一个典型场景是高并发批量写入数据到 TiDB。本文阐述了该场景中的常见问题,旨在给出一个业务的最佳实践,帮助读者避免因使用 TiDB 不当而影响业务开发。</p><h2 id="目标读者" style="position:relative"><a href="#%E7%9B%AE%E6%A0%87%E8%AF%BB%E8%80%85" aria-label="目标读者 permalink" class="anchor before"><svg aria-hidden="true" focusable="false" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"/></svg></a>目标读者</h2><p>本文假设你已对 TiDB 有一定的了解,推荐先阅读 TiDB 原理相关的三篇文章(<a href="https://pingcap.com/blog-cn/tidb-internal-1/" target="_blank" referrerpolicy="no-referrer-when-downgrade">讲存储</a>,<a href="https://pingcap.com/blog-cn/tidb-internal-2/" target="_blank" referrerpolicy="no-referrer-when-downgrade">说计算</a>,<a href="https://pingcap.com/blog-cn/tidb-internal-3/" target="_blank" referrerpolicy="no-referrer-when-downgrade">谈调度</a>),以及 <a href="https://pingcap.com/blog-cn/tidb-best-practice/" target="_blank" referrerpolicy="no-referrer-when-downgrade">TiDB Best Practice</a>。</p><h2 id="高并发批量插入场景" style="position:relative"><a href="#%E9%AB%98%E5%B9%B6%E5%8F%91%E6%89%B9%E9%87%8F%E6%8F%92%E5%85%A5%E5%9C%BA%E6%99%AF" aria-label="高并发批量插入场景 permalink" class="anchor before"><svg aria-hidden="true" focusable="false" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"/></svg></a>高并发批量插入场景</h2><p>高并发批量插入的场景通常出现在业务系统的批量任务中,例如清算以及结算等业务。此类场景存在以下特点:</p><ul><li>数据量大</li><li>需要短时间内将历史数据入库</li><li>需要短时间内读取大量数据</li></ul><p>这就对 TiDB 提出了以下挑战:</p><ul><li>写入/读取能力是否可以线性水平扩展</li><li>随着数据持续大并发写入,数据库性能是否稳定不衰减</li></ul><p>对于分布式数据库来说,除了本身的基础性能外,最重要的就是充分利用所有节点能力,避免让单个节点成为瓶颈。</p><h2 id="tidb-数据分布原理" style="position:relative"><a href="#tidb-%E6%95%B0%E6%8D%AE%E5%88%86%E5%B8%83%E5%8E%9F%E7%90%86" aria-label="tidb 数据分布原理 permalink" class="anchor before"><svg aria-hidden="true" focusable="false" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"/></svg></a>TiDB 数据分布原理</h2><p>如果要解决以上挑战,需要从 TiDB 数据切分以及调度的原理开始讲起。这里只作简单说明,详情可参阅<a href="https://pingcap.com/blog-cn/tidb-internal-3/" target="_blank" referrerpolicy="no-referrer-when-downgrade">谈调度</a>。</p><p>TiDB 以 Region 为单位对数据进行切分,每个 Region 有大小限制(默认 96M)。Region 的切分方式是范围切分。每个 Region 会有多副本,每一组副本,称为一个 Raft Group。每个 Raft Group 中由 Leader 负责执行这块数据的读 & 写(TiDB 支持 <a href="/zh/tidb/stable/follower-read">Follower-Read</a>)。Leader 会自动地被 PD 组件均匀调度在不同的物理节点上,用以均分读写压力。</p><p><img src="https://download.pingcap.com/images/docs-cn/best-practices/tidb-data-overview.png" alt="TiDB 数据概览"/></p><p>从原理上来说,只要没有业务上的写入热点(即业务写入没有 <code>AUTO_INCREMENT</code> 的主键和单调递增的索引,更多细节可参阅 <a href="https://zhuanlan.zhihu.com/p/25574778" target="_blank" referrerpolicy="no-referrer-when-downgrade">TiDB 正确使用方式</a>),依靠这个架构,TiDB 不仅具备线性扩展的读写能力,也能够充分利用分布式资源。从这一点看,TiDB 尤其适合高并发批量写入场景的业务。</p><p>但理论场景和实际情况往往存在不同。以下实例说明了热点是如何产生的。</p><h2 id="热点产生的实例" style="position:relative"><a href="#%E7%83%AD%E7%82%B9%E4%BA%A7%E7%94%9F%E7%9A%84%E5%AE%9E%E4%BE%8B" aria-label="热点产生的实例 permalink" class="anchor before"><svg aria-hidden="true" focusable="false" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"/></svg></a>热点产生的实例</h2><p>以下为一张示例表:</p><pre><code class="hljs language-sql"><style data-emotion="css 1qhimia">.css-1qhimia{margin-right:3rem;overflow:auto;}</style><div class="MuiBox-root css-1qhimia"><span class="hljs-keyword">CREATE</span> <span class="hljs-keyword">TABLE</span> IF <span class="hljs-keyword">NOT</span> <span class="hljs-keyword">EXISTS</span> TEST_HOTSPOT( id <span class="hljs-type">BIGINT</span> <span class="hljs-keyword">PRIMARY</span> KEY, age <span class="hljs-type">INT</span>, user_name <span class="hljs-type">VARCHAR</span>(<span class="hljs-number">32</span>), email <span class="hljs-type">VARCHAR</span>(<span class="hljs-number">128</span>) </div><style data-emotion="css ux9q70">.css-ux9q70{text-align:center;-webkit-flex:0 0 auto;-ms-flex:0 0 auto;flex:0 0 auto;font-size:1.5rem;padding:8px;border-radius:50%;overflow:visible;color:rgba(0, 0, 0, 0.54);-webkit-transition:background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;padding:5px;font-size:1.125rem;top:0.625rem;right:2.4rem;background:transparent;border:unset;}.css-ux9q70:hover{background-color:rgba(0, 0, 0, 0.04);}@media (hover: none){.css-ux9q70:hover{background-color:transparent;}}.css-ux9q70.Mui-disabled{background-color:transparent;color:rgba(0, 0, 0, 0.26);}</style><style data-emotion="css 1rmx1rm">.css-1rmx1rm{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;position:relative;box-sizing:border-box;-webkit-tap-highlight-color:transparent;background-color:transparent;outline:0;border:0;margin:0;border-radius:0;padding:0;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;vertical-align:middle;-moz-appearance:none;-webkit-appearance:none;-webkit-text-decoration:none;text-decoration:none;color:inherit;text-align:center;-webkit-flex:0 0 auto;-ms-flex:0 0 auto;flex:0 0 auto;font-size:1.5rem;padding:8px;border-radius:50%;overflow:visible;color:rgba(0, 0, 0, 0.54);-webkit-transition:background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;padding:5px;font-size:1.125rem;top:0.625rem;right:2.4rem;background:transparent;border:unset;}.css-1rmx1rm::-moz-focus-inner{border-style:none;}.css-1rmx1rm.Mui-disabled{pointer-events:none;cursor:default;}@media print{.css-1rmx1rm{-webkit-print-color-adjust:exact;color-adjust:exact;}}.css-1rmx1rm:hover{background-color:rgba(0, 0, 0, 0.04);}@media (hover: none){.css-1rmx1rm:hover{background-color:transparent;}}.css-1rmx1rm.Mui-disabled{background-color:transparent;color:rgba(0, 0, 0, 0.26);}</style><button class="MuiButtonBase-root MuiIconButton-root MuiIconButton-sizeSmall css-1rmx1rm" tabindex="0" type="button" aria-label="Toggle code wrap"><style data-emotion="css 1cw4hi4">.css-1cw4hi4{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;width:1em;height:1em;display:inline-block;fill:currentColor;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;-webkit-transition:fill 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:fill 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;font-size:inherit;}</style><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeInherit css-1cw4hi4" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="WrapTextIcon"><path d="M4 19h6v-2H4v2zM20 5H4v2h16V5zm-3 6H4v2h13.25c1.1 0 2 .9 2 2s-.9 2-2 2H15v-2l-3 3 3 3v-2h2c2.21 0 4-1.79 4-4s-1.79-4-4-4z"/></svg></button><style data-emotion="css 1e2dcm1">.css-1e2dcm1{z-index:1500;pointer-events:none;}</style><style data-emotion="css okvapm">.css-okvapm{z-index:1500;pointer-events:none;}</style><style data-emotion="css rnn29l">.css-rnn29l{text-align:center;-webkit-flex:0 0 auto;-ms-flex:0 0 auto;flex:0 0 auto;font-size:1.5rem;padding:8px;border-radius:50%;overflow:visible;color:rgba(0, 0, 0, 0.54);-webkit-transition:background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;padding:5px;font-size:1.125rem;top:0.625rem;right:0.625rem;background:transparent;border:unset;}.css-rnn29l:hover{background-color:rgba(0, 0, 0, 0.04);}@media (hover: none){.css-rnn29l:hover{background-color:transparent;}}.css-rnn29l.Mui-disabled{background-color:transparent;color:rgba(0, 0, 0, 0.26);}</style><style data-emotion="css fxo539">.css-fxo539{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;position:relative;box-sizing:border-box;-webkit-tap-highlight-color:transparent;background-color:transparent;outline:0;border:0;margin:0;border-radius:0;padding:0;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;vertical-align:middle;-moz-appearance:none;-webkit-appearance:none;-webkit-text-decoration:none;text-decoration:none;color:inherit;text-align:center;-webkit-flex:0 0 auto;-ms-flex:0 0 auto;flex:0 0 auto;font-size:1.5rem;padding:8px;border-radius:50%;overflow:visible;color:rgba(0, 0, 0, 0.54);-webkit-transition:background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;transition:background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;padding:5px;font-size:1.125rem;top:0.625rem;right:0.625rem;background:transparent;border:unset;}.css-fxo539::-moz-focus-inner{border-style:none;}.css-fxo539.Mui-disabled{pointer-events:none;cursor:default;}@media print{.css-fxo539{-webkit-print-color-adjust:exact;color-adjust:exact;}}.css-fxo539:hover{background-color:rgba(0, 0, 0, 0.04);}@media (hover: none){.css-fxo539:hover{background-color:transparent;}}.css-fxo539.Mui-disabled{background-color:transparent;color:rgba(0, 0, 0, 0.26);}</style><button class="MuiButtonBase-root MuiIconButton-root MuiIconButton-sizeSmall css-fxo539" tabindex="0" type="button" aria-label="copy"><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeInherit css-1cw4hi4" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ContentCopyIcon"><path d="M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12V1zm3 4H8c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h11c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm0 16H8V7h11v14z"/></svg></button></code></pre><p>这个表的结构非常简单,除了 <code>id</code> 为主键以外,没有额外的二级索引。将数据写入该表的语句如下,<code>id</code> 通过随机数离散生成:</p><pre><code class="hljs language-sql"><div class="MuiBox-root css-1qhimia"><span class="hljs-keyword">SET</span> SESSION cte_max_recursion_depth <span class="hljs-operator">=</span> <span class="hljs-number">1000000</span>; <span class="hljs-keyword">INSERT</span> <span class="hljs-keyword">INTO</span> TEST_HOTSPOT <span class="hljs-keyword">SELECT</span> n, <span class="hljs-comment">-- ID</span> RAND()<span class="hljs-operator">*</span><span class="hljs-number">80</span>, <span class="hljs-comment">-- 0 到 80 之间的随机数</span> CONCAT(<span class="hljs-string">'user-'</span>,n), CONCAT( <span class="hljs-type">CHAR</span>(<span class="hljs-number">65</span> <span class="hljs-operator">+</span> (RAND() <span class="hljs-operator">*</span> <span class="hljs-number">25</span>) <span class="hljs-keyword">USING</span> ascii), <span class="hljs-comment">-- 65 到 65+25 之间的随机数,转换为一个 A-Z 字符</span> <span class="hljs-string">'-user-'</span>, <span class="hljs-string">'@example.com'</span> (<span class="hljs-keyword">WITH</span> <span class="hljs-keyword">RECURSIVE</span> nr(n) <span class="hljs-keyword">AS</span> (<span class="hljs-keyword">SELECT</span> <span class="hljs-number">1</span> <span class="hljs-comment">-- 从 1 开始 CTE</span> <span class="hljs-keyword">UNION</span> <span class="hljs-keyword">ALL</span> <span class="hljs-keyword">SELECT</span> n <span class="hljs-operator">+</span> <span class="hljs-number">1</span> <span class="hljs-comment">-- 每次循环 n 增加 1</span> <span class="hljs-keyword">FROM</span> nr <span class="hljs-keyword">WHERE</span> n <span class="hljs-operator"><</span> <span class="hljs-number">1000000</span> <span class="hljs-comment">-- 当 n 为 1_000_000 时停止循环</span> ) <span class="hljs-keyword">SELECT</span> n <span class="hljs-keyword">FROM</span> nr </div><button class="MuiButtonBase-root MuiIconButton-root MuiIconButton-sizeSmall css-1rmx1rm" tabindex="0" type="button" aria-label="Toggle code wrap"><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeInherit css-1cw4hi4" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="WrapTextIcon"><path d="M4 19h6v-2H4v2zM20 5H4v2h16V5zm-3 6H4v2h13.25c1.1 0 2 .9 2 2s-.9 2-2 2H15v-2l-3 3 3 3v-2h2c2.21 0 4-1.79 4-4s-1.79-4-4-4z"/></svg></button><button class="MuiButtonBase-root MuiIconButton-root MuiIconButton-sizeSmall css-fxo539" tabindex="0" type="button" aria-label="copy"><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeInherit css-1cw4hi4" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ContentCopyIcon"><path d="M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12V1zm3 4H8c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h11c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm0 16H8V7h11v14z"/></svg></button></code></pre><p>负载是短时间内密集地执行以上写入语句。</p><p>以上操作看似符合理论场景中的 TiDB 最佳实践,业务上没有热点产生。只要有足够的机器,就可以充分利用 TiDB 的分布式能力。要验证是否真的符合最佳实践,可以在实验环境中进行测试。</p><p>部署拓扑 2 个 TiDB 节点,3 个 PD 节点,6 个 TiKV 节点。请忽略 QPS,因为测试只是为了阐述原理,并非 benchmark。</p><p><img src="https://download.pingcap.com/images/docs-cn/best-practices/QPS1.png" alt="QPS1"/></p><p>客户端在短时间内发起了“密集”的写入,TiDB 收到的请求是 3K QPS。理论上,压力应该均摊给 6 个 TiKV 节点。但是从 TiKV 节点的 CPU 使用情况上看,存在明显的写入倾斜(tikv - 3 节点是写入热点):</p><p><img src="https://download.pingcap.com/images/docs-cn/best-practices/QPS2.png" alt="QPS2"/></p><p><img src="https://download.pingcap.com/images/docs-cn/best-practices/QPS3.png" alt="QPS3"/></p><p><a href="/zh/tidb/stable/grafana-tikv-dashboard">Raft store CPU</a> 为 <code>raftstore</code> 线程的 CPU 使用率,通常代表写入的负载。在这个场景下 tikv-3 为 Raft Leader,tikv-0 和 tikv-1 是 Raft 的 Follower,其他的 TiKV 节点的负载几乎为空。</p><p>从 PD 的监控中也可以证明热点的产生:</p><p><img src="https://download.pingcap.com/images/docs-cn/best-practices/QPS4.png" alt="QPS4"/></p><h2 id="热点问题产生的原因" style="position:relative"><a href="#%E7%83%AD%E7%82%B9%E9%97%AE%E9%A2%98%E4%BA%A7%E7%94%9F%E7%9A%84%E5%8E%9F%E5%9B%A0" aria-label="热点问题产生的原因 permalink" class="anchor before"><svg aria-hidden="true" focusable="false" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"/></svg></a>热点问题产生的原因</h2><p>以上测试并未达到理论场景中最佳实践,因为刚创建表的时候,这个表在 TiKV 中只会对应为一个 Region,范围是:</p><pre><code class="hljs language-plaintext"><div class="MuiBox-root css-1qhimia">[CommonPrefix + TableID, CommonPrefix + TableID + 1) </div><button class="MuiButtonBase-root MuiIconButton-root MuiIconButton-sizeSmall css-1rmx1rm" tabindex="0" type="button" aria-label="Toggle code wrap"><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeInherit css-1cw4hi4" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="WrapTextIcon"><path d="M4 19h6v-2H4v2zM20 5H4v2h16V5zm-3 6H4v2h13.25c1.1 0 2 .9 2 2s-.9 2-2 2H15v-2l-3 3 3 3v-2h2c2.21 0 4-1.79 4-4s-1.79-4-4-4z"/></svg></button><button class="MuiButtonBase-root MuiIconButton-root MuiIconButton-sizeSmall css-fxo539" tabindex="0" type="button" aria-label="copy"><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeInherit css-1cw4hi4" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ContentCopyIcon"><path d="M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12V1zm3 4H8c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h11c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm0 16H8V7h11v14z"/></svg></button></code></pre><p>短时间内大量数据会持续写入到同一个 Region 上。</p><p><img src="https://download.pingcap.com/images/docs-cn/best-practices/tikv-Region-split.png" alt="TiKV Region 分裂流程"/></p><p>上图简单描述了这个过程,随着数据持续写入,TiKV 会将一个 Region 切分为多个。但因为首先发起选举的是原 Leader 所在的 Store,所以新切分好的两个 Region 的 Leader 很可能还会在原 Store 上。新切分好的 Region 2,3 上,也会重复之前发生在 Region 1 上的过程。也就是压力会密集地集中在 TiKV-Node 1 上。</p><p>在持续写入的过程中,PD 发现 Node 1 中产生了热点,会将 Leader 均分到其他的 Node 上。如果 TiKV 的节点数多于副本数的话,TiKV 会尽可能将 Region 迁移到空闲的节点上。这两个操作在数据插入的过程中,也能在 PD 监控中得到印证:</p><p><img src="https://download.pingcap.com/images/docs-cn/best-practices/QPS5.png" alt="QPS5"/></p><p>在持续写入一段时间后,整个集群会被 PD 自动地调度成一个压力均匀的状态,到那个时候整个集群的能力才会真正被利用起来。在大多数情况下,以上热点产生的过程是没有问题的,这个阶段属于表 Region 的预热阶段。</p><p>但是对于高并发批量密集写入场景来说,应该避免这个阶段。</p><h2 id="热点问题的规避方法" style="position:relative"><a href="#%E7%83%AD%E7%82%B9%E9%97%AE%E9%A2%98%E7%9A%84%E8%A7%84%E9%81%BF%E6%96%B9%E6%B3%95" aria-label="热点问题的规避方法 permalink" class="anchor before"><svg aria-hidden="true" focusable="false" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"/></svg></a>热点问题的规避方法</h2><p>为了达到场景理论中的最佳性能,可跳过这个预热阶段,直接将 Region 切分为预期的数量,提前调度到集群的各个节点中。</p><p>TiDB 在 v3.0.x 以及 v2.1.13 后支持一个叫 <a href="/zh/tidb/stable/sql-statement-split-region">Split Region</a> 的新特性。这个特性提供了新的语法:</p><pre><code class="hljs language-sql"><div class="MuiBox-root css-1qhimia">SPLIT <span class="hljs-keyword">TABLE</span> table_name [INDEX index_name] <span class="hljs-keyword">BETWEEN</span> (lower_value) <span class="hljs-keyword">AND</span> (upper_value) REGIONS region_num </div><button class="MuiButtonBase-root MuiIconButton-root MuiIconButton-sizeSmall css-1rmx1rm" tabindex="0" type="button" aria-label="Toggle code wrap"><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeInherit css-1cw4hi4" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="WrapTextIcon"><path d="M4 19h6v-2H4v2zM20 5H4v2h16V5zm-3 6H4v2h13.25c1.1 0 2 .9 2 2s-.9 2-2 2H15v-2l-3 3 3 3v-2h2c2.21 0 4-1.79 4-4s-1.79-4-4-4z"/></svg></button><button class="MuiButtonBase-root MuiIconButton-root MuiIconButton-sizeSmall css-fxo539" tabindex="0" type="button" aria-label="copy"><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeInherit css-1cw4hi4" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ContentCopyIcon"><path d="M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12V1zm3 4H8c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h11c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm0 16H8V7h11v14z"/></svg></button></code></pre><pre><code class="hljs language-sql"><div class="MuiBox-root css-1qhimia">SPLIT <span class="hljs-keyword">TABLE</span> table_name [INDEX index_name] <span class="hljs-keyword">BY</span> (value_list) [, (value_list)] </div><button class="MuiButtonBase-root MuiIconButton-root MuiIconButton-sizeSmall css-1rmx1rm" tabindex="0" type="button" aria-label="Toggle code wrap"><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeInherit css-1cw4hi4" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="WrapTextIcon"><path d="M4 19h6v-2H4v2zM20 5H4v2h16V5zm-3 6H4v2h13.25c1.1 0 2 .9 2 2s-.9 2-2 2H15v-2l-3 3 3 3v-2h2c2.21 0 4-1.79 4-4s-1.79-4-4-4z"/></svg></button><button class="MuiButtonBase-root MuiIconButton-root MuiIconButton-sizeSmall css-fxo539" tabindex="0" type="button" aria-label="copy"><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeInherit css-1cw4hi4" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ContentCopyIcon"><path d="M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12V1zm3 4H8c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h11c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm0 16H8V7h11v14z"/></svg></button></code></pre><p>但是 TiDB 并不会自动提前完成这个切分操作。原因如下:</p><p><img src="https://download.pingcap.com/images/docs-cn/best-practices/table-Region-range.png" alt="Table Region Range"/></p><p>从上图可知,根据行数据 key 的编码规则,行 ID (rowID) 是行数据中唯一可变的部分。在 TiDB 中,rowID 是一个 Int64 整型。但是用户不一定能将 Int64 整型范围均匀切分成需要的份数,然后均匀分布在不同的节点上,还需要结合实际情况。</p><p>如果行 ID 的写入是完全离散的,那么上述方式是可行的。如果行 ID 或者索引有固定的范围或者前缀(例如,只在 <code>[2000w, 5000w)</code> 的范围内离散插入数据),这种写入依然在业务上不产生热点,但是如果按上面的方式进行切分,那么有可能一开始数据仍只写入到某个 Region 上。</p><p>作为一款通用数据库,TiDB 并不对数据的分布作假设,所以开始只用一个 Region 来对应一个表。等到真实数据插入进来以后,TiDB 自动根据数据的分布来作切分。这种方式是较通用的。</p><p>所以 TiDB 提供了 <code>Split Region</code> 语法,专门针对短时批量写入场景作优化。基于以上案例,下面尝试用 <code>Split Region</code> 语法提前切散 Region,再观察负载情况。</p><p>由于测试的写入数据在正数范围内完全离散,所以用以下语句,在 Int64 空间内提前将表切分为 128 个 Region:</p><pre><code class="hljs language-sql"><div class="MuiBox-root css-1qhimia">SPLIT <span class="hljs-keyword">TABLE</span> TEST_HOTSPOT <span class="hljs-keyword">BETWEEN</span> (<span class="hljs-number">0</span>) <span class="hljs-keyword">AND</span> (<span class="hljs-number">9223372036854775807</span>) REGIONS <span class="hljs-number">128</span>; </div><button class="MuiButtonBase-root MuiIconButton-root MuiIconButton-sizeSmall css-1rmx1rm" tabindex="0" type="button" aria-label="Toggle code wrap"><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeInherit css-1cw4hi4" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="WrapTextIcon"><path d="M4 19h6v-2H4v2zM20 5H4v2h16V5zm-3 6H4v2h13.25c1.1 0 2 .9 2 2s-.9 2-2 2H15v-2l-3 3 3 3v-2h2c2.21 0 4-1.79 4-4s-1.79-4-4-4z"/></svg></button><button class="MuiButtonBase-root MuiIconButton-root MuiIconButton-sizeSmall css-fxo539" tabindex="0" type="button" aria-label="copy"><svg class="MuiSvgIcon-root MuiSvgIcon-fontSizeInherit css-1cw4hi4" focusable="false" aria-hidden="true" viewbox="0 0 24 24" data-testid="ContentCopyIcon"><path d="M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12V1zm3 4H8c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h11c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm0 16H8V7h11v14z"/></svg></button></code></pre><p>切分完成以后,可以通过 <code>SHOW TABLE test_hotspot REGIONS;</code> 语句查看打散的情况。如果 <code>SCATTERING</code> 列值全部为 <code>0</code>,代表调度成功。</p><p>也可以通过以下 SQL 语句查看 Region 的分布。你需要将 <code>table_name</code> 替换为实际的表名。</p><pre><code class="hljs language-sql"><div class="MuiBox-root css-1qhimia"><span class="hljs-keyword">SELECT</span> p.STORE_ID, <span class="hljs-built_in">COUNT</span>(s.REGION_ID) PEER_COUNT INFORMATION_SCHEMA.TIKV_REGION_STATUS s <span class="hljs-keyword">JOIN</span> INFORMATION_SCHEMA.TIKV_REGION_PEERS p <span class="hljs-keyword">ON</span> s.REGION_ID <span class="hljs-operator">=</span> p.REGION_ID <span class="hljs-keyword">WHERE</span> TABLE_NAME <span class="hljs-operator">=</span> <span class="hljs-string">'table_name'</span> <span class="hljs-keyword">AND</span> p.is_leader <span class="hljs-operator">=</span> <span class="hljs-number">1</span> <span class="hljs-keyword">GROUP</span> <span class="hljs-keyword">BY</span> p.STORE_ID
推荐文章
果断的猴子
·
WPF MVVM框架 Prism 导航_xaml_App_com
3 月前
风度翩翩的山寨机
·
sql循环遍历查询 - 百度
8 月前
眼睛小的西装
·
ClickHouse 中的数据查询以及各种子句 - 古明地盆 - 博客园
1 年前
坏坏的黑框眼镜
·
在 Vue 中使用lodash对事件进行防抖和节流,防止用户重复点击按钮提交 - 他她 - 博客园
1 年前