Skip to content

ui: add KeyedCachedDataReducer selector factory util, refactor jobs page props to use RequestState#101481

Merged
craig[bot] merged 2 commits intocockroachdb:masterfrom
xinhaoz:jobs-page-props-update
Apr 19, 2023
Merged

ui: add KeyedCachedDataReducer selector factory util, refactor jobs page props to use RequestState#101481
craig[bot] merged 2 commits intocockroachdb:masterfrom
xinhaoz:jobs-page-props-update

Conversation

@xinhaoz
Copy link
Copy Markdown
Contributor

@xinhaoz xinhaoz commented Apr 13, 2023

See individual commits.

Release note: None

Epic: CRDB-25476

@cockroach-teamcity
Copy link
Copy Markdown
Member

This change is Reviewable

@xinhaoz xinhaoz force-pushed the jobs-page-props-update branch 3 times, most recently from 2e21858 to f3c5305 Compare April 17, 2023 14:27
@xinhaoz xinhaoz changed the title ui: add KeyedCachedDataReducer selector factory util ui: add KeyedCachedDataReducer selector factory util, refactor jobs page props to use RequestState Apr 17, 2023
This commit adds the `createSelectorForKeyedCachedDataField`
utility to help create selector functions that will transform
the data of type `KeyedCachedDataReducer` into `RequestState<T>`
expected by components in cluster-ui.

Epic: none

Release note: None
@xinhaoz xinhaoz force-pushed the jobs-page-props-update branch from f3c5305 to a7dd422 Compare April 17, 2023 14:56
@xinhaoz xinhaoz marked this pull request as ready for review April 17, 2023 14:56
@xinhaoz xinhaoz requested review from a team April 17, 2023 14:56
Copy link
Copy Markdown
Contributor

@maryliag maryliag left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed 2 of 2 files at r1, 8 of 8 files at r2, all commit messages.
Reviewable status: :shipit: complete! 0 of 0 LGTMs obtained (waiting on @xinhaoz)


pkg/ui/workspaces/cluster-ui/src/store/jobs/jobs.reducer.ts line 14 at r2 (raw file):

import { JobsRequest, JobsResponse } from "src/api/jobsApi";
import { DOMAIN_NAME } from "../utils";
import moment from "moment-timezone";

I think it needs to be imported from moment-timezone, related to the work of adding timezone to console pages

Refactor the jobs page components to use `RequestState`
to read the jobs response parts.

Epic: none

Release note: None
Copy link
Copy Markdown
Contributor Author

@xinhaoz xinhaoz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewable status: :shipit: complete! 0 of 0 LGTMs obtained (waiting on @maryliag)


pkg/ui/workspaces/cluster-ui/src/store/jobs/jobs.reducer.ts line 14 at r2 (raw file):

Previously, maryliag (Marylia Gutierrez) wrote…

I think it needs to be imported from moment-timezone, related to the work of adding timezone to console pages

Done.

@xinhaoz xinhaoz force-pushed the jobs-page-props-update branch from a7dd422 to d6d6615 Compare April 18, 2023 19:34
Copy link
Copy Markdown
Contributor

@maryliag maryliag left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:lgtm:

Reviewed 1 of 1 files at r3, all commit messages.
Reviewable status: :shipit: complete! 1 of 0 LGTMs obtained (waiting on @xinhaoz)

@xinhaoz
Copy link
Copy Markdown
Contributor Author

xinhaoz commented Apr 19, 2023

TFTR!
bors r+

@craig
Copy link
Copy Markdown
Contributor

craig bot commented Apr 19, 2023

Build failed (retrying...):

@craig
Copy link
Copy Markdown
Contributor

craig bot commented Apr 19, 2023

Build failed:

@xinhaoz
Copy link
Copy Markdown
Contributor Author

xinhaoz commented Apr 19, 2023

bors r+

@craig
Copy link
Copy Markdown
Contributor

craig bot commented Apr 19, 2023

Build succeeded:

@craig craig bot merged commit 50bc51e into cockroachdb:master Apr 19, 2023
@xinhaoz xinhaoz deleted the jobs-page-props-update branch June 5, 2023 17:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants