-
Notifications
You must be signed in to change notification settings - Fork 82
KxDashboards - Debugging .kxdash.exec #651
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
base: master
Are you sure you want to change the base?
Conversation
|
FYI @jonnypress |
.gw.asyncexecjpt now only returning 1 result (not 1 from each hdb)
|
Additionally, the sublist'ing segment is still in place |
| // Reset format response | ||
| .gw.formatresponse:formatresponse; | ||
| // incorporate dashps into the .z.ps definition | ||
| .dotz.set[`.z.ps;{x@y;.kxdash.dashps y}@[value;.dotz.getcommand[`.z.ps];{{value x}}]]; |
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.
.kxdash.dashps is executed after the original .z.ps definition - are we actually using dashparams anywhere after this change? or the dashremote and dashjoin functions? Seems like most of this script is possibly redundant if we're just using the original .z.ps?
| syncexecjpre36:{[query;servertype;joinfunction] | ||
| // Check correct function called | ||
| if[(.z.w<>0)&(.z.w in key .gw.call)¬ .gw.call .z.w; | ||
| if[(.z.w<>0)&(.z.w in key .gw.call)&(not .gw.call .z.w)& not @[value;`.kxdash.enabled;0b]; |
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 will allow syncexec to be called via async request as long as .kxdash.enabled is true i.e. it'd allow a non-kx dashboard client to send async request to syncexec, which I don't think is what we want?
it also seems strange to me that we are using syncexecjpre36 for async requests from kx dashboards, is this definitely the correct approach? (I guess this is because kx dashboards is essentially doing a defferred sync request with it's own wrapper, so it's simpler on our side to treat it as a sync request, so this probably does make sense)
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.
@davidbuckley123 couple of points to pick up here if you get a chance
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.
non-kx dashboard client to send async request to syncexec
Fair enough - theif[]statement could be tightened up a bit.
I am only trying to enabled syncexec calls from a negative handle from kx dashboards.
Honestly, I am not 100% satisfied with this as a solution.
I'll take some time and see if I can come up with something more elegant.


It looks like we'll have to use a sync response.
Dashboards are config'd to send down a negative handle, but the wrapper that the dashboards add looks like the below:
The
x[0] sublist value x 1always gives a(::)result on async methods. This causes dashboards to recognise no result has been returned. Due to this, I have converted to sync.Additionally, TorQ has a condition checking for negative handles vs sync/async. I have had to add a condition to ignore this if .kxdash.enabled is set to
1b.As below, this is tested and working through the front-end.
