-
Notifications
You must be signed in to change notification settings - Fork 351
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
Fixes mapping issue when using :sysinfo with HA #599
Conversation
Could you add a test that shows that this error is gone, or is this component hard to run enzyme-compat tests on? |
This is will require some refactoring I was trying to defer until later because on |
ed45a1a
to
002059e
Compare
002059e
to
913631a
Compare
@oskarhane added both component tests and tests around the extracted out logic to support this fix |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very nice and the :sysinfo seems to work well!
You broke the :queries frame in a CC environment so I'd suggest you leave out that part from this PR.
canListQueries () { | ||
return this.props.availableProcedures.includes('dbms.listQueries') | ||
} | ||
|
||
getRunningQueries (suppressQuerySuccessMessage = false) { | ||
this.props.bus.self( | ||
(this.isCC()) ? CLUSTER_CYPHER_REQUEST : CYPHER_REQUEST, | ||
(this.props.isACausalCluster) ? CLUSTER_CYPHER_REQUEST : CYPHER_REQUEST, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How does this get passed to the :queries frame?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also, you'd need to change the line in killQueries
below as well, where a check for this.isCC()
is made.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change was by mistake. I didn't plan on changing anything outside of things that affect sysinfo.
} | ||
|
||
clusterResponseHandler () { | ||
return (res) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why return function rather than just handle the response directly?
It looks a bit unusual.
} | ||
} | ||
responseHandler () { | ||
return (res) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same as in clusterResponseHandler
.
It looks a bit unusual.
@oskarhane updated |
Very nice changes, lgtm. |
Fixes #586