cockroachdb / cockroach

CockroachDB — the cloud native, distributed SQL database designed for high availability, effortless scale, and control over data placement.
https://www.cockroachlabs.com
Other
29.88k stars 3.77k forks source link

Regions/Nodes columns not showing up on Dedicated #85249

Open maryliag opened 2 years ago

maryliag commented 2 years ago

The column for Node/Regions are not being displayed on Statement Page. The filter of nodes is being displayed so the value must be correct, but some other check must be wrong, since it's not showing the column itself or on the column selector list.

To be clear, this column should not be displayed on Serverless

Jira issue: CRDB-18136

Epic CRDB-32130

matthewtodd commented 2 years ago

@maryliag it looks like it's the logic to hide the Regions/Nodes column when the cluster's only running in one region that's causing this behavior. When I run the following command, I see the column as expected:

./cockroach demo \
  --insecure \
  --multitenant=false \
  --nodes=3 \
  --demo-locality=region=us-east1,az=1:region=us-central1,az=2:region=us-west1,az=3

So, this feature appears to be behaving as designed, unless I'm missing something?

maryliag commented 2 years ago

on local it was working, but on cloud on our staging cluster it wasn't. Maybe it's related to it being busted, if you can confirm with another cluster on cloud that has multiple regions that this is working, you can go ahead and close this.

matthewtodd commented 2 years ago

I'm looking around for a multi-region dedicated cluster in staging, but I haven't found one yet...

matthewtodd commented 2 years ago

Found one, adwit-wi-aws1, with 3 regions / 3 machines.

The feature seems to be working as intended!

Screen Shot 2022-09-07 at 4 04 42 PM
maryliag commented 2 years ago

@matthewtodd I see you're pointing to localhost, so maybe the master has the fix for it? If I go on the staging cluster that you pointed out, I don't see the column or the filter option

Screen Shot 2022-09-07 at 5 15 31 PM
matthewtodd commented 2 years ago

Oof, thanks for the catch, @maryliag. Must be a difference with master, then? I'll see if there's something we need to backport to 22.1.

matthewtodd commented 1 year ago

Back on this today, and strangely I'm no longer seeing the column on master either. Digging back in now.

maryliag commented 1 year ago

Back on this today, and strangely I'm no longer seeing the column on master either. Digging back in now.

the column won't show if you have only one node/region, so make sure you're testing with multiple node/regions

matthewtodd commented 1 year ago

I think I found it, it looks like the page is assuming state.adminUI.nodes has been populated, but it hasn't. So we just need to dispatch the right action.