-
Notifications
You must be signed in to change notification settings - Fork 134
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refine ClusterInfo & Instance #591
Conversation
Signed-off-by: Breezewish <me@breeswish.org>
Signed-off-by: Breezewish <me@breeswish.org>
Signed-off-by: Breezewish <me@breeswish.org>
[LogLevel.Warn]: 'WARN', | ||
[LogLevel.Trace]: 'TRACE', | ||
[LogLevel.Critical]: 'CRITICAL', | ||
[LogLevel.Error]: 'ERROR', | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems ok to define the LogLevelText as an Array, likes:
export const LogLevelText = ['UNKNOWN', 'DEBUG' ...]
But this is not a big deal, just simplify the code slightly.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It relies on the value of log levels to work, might not be very ideal.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM for frontend part.
@baurine Good catch! Let me take a look |
Signed-off-by: Breezewish <me@breeswish.org>
Add
manualTestEnv
for easier testing. You can use Vagrant to establish the environment. See README in each directory for details.Refined cluster info from getTopology to getTiDB, getStores, getPD, ...
Introduce
pd.Client
to backend, which gracefully handles context.Share TiKV & TiFlash cluster info logic
Remove animations from sider menu to be efficient
Add a DebugPlayground App (TODO: Use Storybook instead @baurine )
Introduce
<BaseSelect>
, which is a<Select>
like component with customization support for the drop content or displayed valueIntroduce
<InstanceSelect>
based on<BaseSelect>
to provide a nice UI for selecting multiple instancesIt is compatible with Antd form validation:
Now Overview is composed by self-managed components (except for Statement & Slow Query -- TODO: Refine them @baurine) instead of sharing some states.
This makes it possible to allow user customizing the Overview page in future.
Update Overview page UI:
Introduce
utils/instanceTable
to contain everything common about instances (like instance names and variants)Add more time slots to
<TimeRangeSelector>
Remove unused
<CardTable>
(TODO: Rename<CardTableV2>
to<CardTable>
@baurine)Update
<CardTableV2>
to have a correct Checkbox display when there are group headers. (TODO: Drop implementation after DetailsList onRenderCheckbox is not effective for group headers microsoft/fluentui#13144 is merged)Slightly refine
<TimeRangeSelector>
Refine LogSearch to use
<InstanceSelect>
andutils/instanceTable
(and usetreeData
in<Tree>
component)Add
useCallback
,useMemo
,usePersistFn
to several places to reduce unnecessary re-render.TODO:
Call for help: