mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Preload pods/events on nodes page (#2870)
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>
This commit is contained in:
parent
f3b3d15e50
commit
0466971a6c
@ -21,7 +21,7 @@
|
||||
|
||||
import "./nodes.scss";
|
||||
import React from "react";
|
||||
import { observer } from "mobx-react";
|
||||
import { disposeOnUnmount, observer } from "mobx-react";
|
||||
import type { RouteComponentProps } from "react-router";
|
||||
import { cssNames, interval } from "../../utils";
|
||||
import { TabLayout } from "../layout/tab-layout";
|
||||
@ -37,6 +37,8 @@ import kebabCase from "lodash/kebabCase";
|
||||
import upperFirst from "lodash/upperFirst";
|
||||
import { KubeObjectStatusIcon } from "../kube-object-status-icon";
|
||||
import { Badge } from "../badge/badge";
|
||||
import { kubeWatchApi } from "../../api/kube-watch-api";
|
||||
import { eventStore } from "../+events/event.store";
|
||||
|
||||
enum columnId {
|
||||
name = "name",
|
||||
@ -60,6 +62,11 @@ export class Nodes extends React.Component<Props> {
|
||||
|
||||
componentDidMount() {
|
||||
this.metricsWatcher.start(true);
|
||||
disposeOnUnmount(this, [
|
||||
kubeWatchApi.subscribeStores([nodesStore, podsStore, eventStore], {
|
||||
preload: true,
|
||||
})
|
||||
]);
|
||||
}
|
||||
|
||||
componentWillUnmount() {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user