Skip to content

ui: standardize the display of node names in node lists#45551

Merged
craig[bot] merged 1 commit intocockroachdb:masterfrom
petermattis:pmattis/ui-node-name
Mar 3, 2020
Merged

ui: standardize the display of node names in node lists#45551
craig[bot] merged 1 commit intocockroachdb:masterfrom
petermattis:pmattis/ui-node-name

Conversation

@petermattis
Copy link
Copy Markdown
Collaborator

Standardize the display of node names in node lists. The nodes overview
list was displaying nodes as N<id> <ip-address> while graphs display
<ip-address> (n<id>). Standardize on the latter format. A similar
problem existed on the statement details page which was displaying
N<id> <ip-address> (n<id>). The node id was being displayed twice!

Release note: None

Standardize the display of node names in node lists. The nodes overview
list was displaying nodes as `N<id> <ip-address>` while graphs display
`<ip-address> (n<id>)`. Standardize on the latter format. A similar
problem existed on the statement details page which was displaying
`N<id> <ip-address> (n<id>)`. The node id was being displayed twice!

Release note: None
@petermattis petermattis requested a review from a team February 29, 2020 21:06
@cockroach-teamcity
Copy link
Copy Markdown
Member

This change is Reviewable

Copy link
Copy Markdown
Collaborator Author

@petermattis petermattis 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


pkg/ui/src/views/cluster/containers/nodesOverview/index.tsx, line 131 at r1 (raw file):

  return (
    <Link className="nodes-table__link" to={`/node/${record.nodeId}`}>
      <Text>{record.nodeName}</Text>

Why does nodeName not include the (n<id>) suffix? Should we be using getDisplayName to populate nodeName?

@dhartunian
Copy link
Copy Markdown
Collaborator

Thanks for this @petermattis! I think I'll merge as-is for now. I agree something like getDisplayName should be explored to standardize the naming but it doesn't look like the types quite line up so I opened a ticket to explore later #45622

@Annebirzin see Peter's comment above for the changes he made to the node naming. Let me know if there's a strong reason to use the Nx prefix notation for nodes. Otherwise I think consistency is preferred for now.

cc @taroface hopefully if this is intersecting with any docs work it's making your life easier :)

@dhartunian
Copy link
Copy Markdown
Collaborator

bors r+

@craig
Copy link
Copy Markdown
Contributor

craig bot commented Mar 3, 2020

Build succeeded

@craig craig bot merged commit 5f9a71a into cockroachdb:master Mar 3, 2020
@petermattis petermattis deleted the pmattis/ui-node-name branch March 3, 2020 08:26
@Annebirzin
Copy link
Copy Markdown

@dhartunian 👍 makes sense, we can standardize to <ip-address> (n<id>)

@petermattis
Copy link
Copy Markdown
Collaborator Author

Let me know if there's a strong reason to use the Nx prefix notation for nodes.

I have a strong preference for n<id> notation because we use that notation throughout our debug logs. Sounds like @Annebirzin is on board with that, just wanted to make the reasoning for my preference clear.

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.

4 participants