2021.07.22 08:26 AM - edited 2021.07.22 08:28 AM
Hello KX Community,
Is it possible to spot a deadlock with a viewstate (or several viewstates) by observing the Document Graph of a Dashboard? Are there hidden connections not shown in the Document Graph?
I am currently working on a superbly complex Dashboard with several queries, viewstates, virtual queries and everything in between. I have connections between them which are not necessarily one-to-one or one-to-many and their type can vary based on other conditions or other viewstates.
As you can assume the document graph can get very complicated very quickly if there is a significant amount of connections.
Reason/Background for Problem:
My problem at the moment, is that I have some sort of deadlock somewhere in my viewstate connections. A viewstate is populated from a dropdown selection, but can also be populated from a Data Grid selection. In order to generate a table from which a user can select an entry and thus populate that viewstate from the Data Grid, that same viewstate needs to not be empty (which will never be as its initially populated by a forced selected value from that dropdown).
The only way of fixing it I thought would be to observe the document graph, see exactly what goes in/out of the data sources responsible for altering that viewstate and what goes in/out of that viewstate itself so I can backtrack it from there.
As you can see in the screenshot attached, there is absolutely no way of distinguishing between the different connections in a clear way, simply because of how many things there are.
I hope this is not too much to read through. I would appreciate it if someone could shine some light on this as I cannot see any other way to do this right now.
2021.07.22 09:20 AM - edited 2021.07.22 09:21 AM
1. You can drag to reposition the different sets of connections; I (mouse wheel) zoom out and then drag from the central viewstate or data source away from the cluster - in non-hierarchical mode - so it's separate from the group and not overlapping. It will drift back to the central cluster but it may help isolate the problem.
2. There isn't a search functionality for view states / data sources in the Document Graph. There is a search in the Data Editor for queries and view state dialog for View States.
3. Given the complexity of your relationships - do you know which of your components is returning the deadlock? If so, copy that component, and paste it into a new Dashboard (ctrl+c / ctrl+v). Then, look at the Document Graph. Only the data sources and connections for that component will show in the Document graph, which hopefully will make it easier to find your blocker.
2021.07.22 09:38 AM - edited 2021.07.23 03:31 AM
2021.07.23 03:31 AM
Unfortunately I have not been able to identify the connections... Also as a quick reply to your points above:
1. Dragging to reposition makes sense, but that's under the assumption that you know what element/or area of elements you want to observe, not when looking for an element. So dragging individually 200+ elements can be a bit of a slow process.
2. Would it be possible to raise this as a potential feature request? I know a few people asking if this is possible or if it will be in the future? Being able to search for something in the document graph means you can immediately spot it and see all the relevant connections.
3. I do know which components they are yes. Haven't had the time to do that yet, I am trying to backtrack it first and if that isnt a solution I will do exactly that ^.
Tel: +44 (0)28 3025 2242
Tel: +1 (212) 447 6700
Tel: +61 (0)2 9236 5700
KX. All Rights Reserved.
KX and kdb+ are registered trademarks of KX Systems, Inc., a subsidiary of FD Technologies plc.