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

mgr: dashboard code cleanup #15577

Merged
merged 4 commits into from Jun 8, 2017

Conversation

Projects
None yet
3 participants
@jcsp
Contributor

jcsp commented Jun 8, 2017

No description provided.

// into "1.2.3-g9asdasd"
return /ceph version (.+) \(.+\)$/.exec(version)[1];
// Expect "ceph version 1.2.3-g9asdasd (as98d7a0s8d7)"
result = /ceph version (.+) \(.+\)/.exec(version);

This comment has been minimized.

@dillaman

dillaman Jun 8, 2017

Contributor

Nit: you should use /ceph version ([^ ]+) \(.+\)/

This comment has been minimized.

@liewegas

liewegas Jun 8, 2017

Member

can we make a structured ceph version thing? i was considering changing the format of this string a couple weeks ago and didn't out of fear of things like this. but we have 2 new fields added at the end now (release name, e.g. 'luminous') and release type ('dev', 'rc', 'stable').

This comment has been minimized.

@liewegas

liewegas Jun 8, 2017

Member

(that can come later, doesn't need to hold up this pr)

This comment has been minimized.

@jcsp

jcsp Jun 8, 2017

Contributor

The places we pass it around (e.g. daemon metadata) we only have a string.

We could improve the format of the string though -- prefixing with "ceph version" seems redundant. Once that's removed we could guide people to take everything up to the first space as the short version and treat everything else as detail, perhaps.

@dillaman regex updated

@@ -577,6 +577,9 @@ def servers(self):
)
def _servers(self):
log.info("Listing servers...")

This comment has been minimized.

@dillaman

dillaman Jun 8, 2017

Contributor

Nit: debug?

This comment has been minimized.

@jcsp

jcsp Jun 8, 2017

Contributor

fixed.

John Spray added some commits Jun 7, 2017

John Spray
mgr/dashboard: keep a global librados instance
...so that classes that need one aren't creating
their own all the time.

Signed-off-by: John Spray <john.spray@redhat.com>
John Spray
mgr/dashboard: fix error handling in remote_view_cache
Signed-off-by: John Spray <john.spray@redhat.com>
John Spray
mgr/dashboard: fix server view on funny version format
Signed-off-by: John Spray <john.spray@redhat.com>
John Spray
mgr/dashboard: remove confusing SyncObject stuff
This was a hangover from when these wrapper classes
were borrowed from Calamari, which used these
versions/equality functions to work out when
to go fetch data from the ceph cluster.

Signed-off-by: John Spray <john.spray@redhat.com>

@dillaman dillaman merged commit 108b38e into ceph:master Jun 8, 2017

2 of 3 checks passed

default Build finished.
Details
Signed-off-by all commits in this PR are signed
Details
Unmodifed Submodules submodules for project are unmodified
Details

@jcsp jcsp deleted the jcsp:wip-dashboard-cleanup branch Nov 7, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment