P1 修复内容: - F7: health handler 连接池容量检查 (80%阈值返回503 degraded) - F9: SSE spawned task 并发限制 (Semaphore 16 permits) - F10: Key Pool 单次 JOIN 查询优化 (消除 N+1) - F12: CORS panic → 配置错误 - F14: 连接池使用率计算修正 (ratio = used*100/total) - F15: SQL 迁移解析器替换为状态机 (支持 $$, DO $body$, 存储过程) - Worker 重试机制: 失败任务通过 mpsc channel 重新入队 - DOMPurify XSS 防护 (PipelineResultPreview) - Admin V2: ErrorBoundary + SWR全局配置 + 请求优化
30 lines
826 B
TypeScript
30 lines
826 B
TypeScript
import { createRoot } from 'react-dom/client'
|
|
import { QueryClient, QueryClientProvider } from '@tanstack/react-query'
|
|
import { RouterProvider } from 'react-router-dom'
|
|
import { ConfigProvider, App as AntApp } from 'antd'
|
|
import zhCN from 'antd/locale/zh_CN'
|
|
import { router } from './router'
|
|
import { ErrorBoundary } from './components/ErrorBoundary'
|
|
|
|
const queryClient = new QueryClient({
|
|
defaultOptions: {
|
|
queries: {
|
|
retry: 1,
|
|
refetchOnWindowFocus: false,
|
|
staleTime: 30_000,
|
|
},
|
|
},
|
|
})
|
|
|
|
createRoot(document.getElementById('root')!).render(
|
|
<ErrorBoundary>
|
|
<ConfigProvider locale={zhCN}>
|
|
<AntApp>
|
|
<QueryClientProvider client={queryClient}>
|
|
<RouterProvider router={router} />
|
|
</QueryClientProvider>
|
|
</AntApp>
|
|
</ConfigProvider>
|
|
</ErrorBoundary>,
|
|
)
|