Minimum Requirements To Achieve Streaming In KX Dashboards

Have sort of asked this before, but had to drop to complete other projects-- but we’re back…

So, I’m trying to achieve streaming data within Dashboards. I’ve gone through the docs (PDFs) and tutorials (videos etc) and still can’t seem to achieve success with this. 

I’ve got a run-of-the-mill TickerPlant that’s consuming data without issue. I’ve got a custom sub process listening to the TickerPlant, running some aggregations and then spitting the results into a final table called MasterTable – the schema for MasterTable is located in my sym.q file within the TP directories. 

Now, in reading through the Docs I very clearly get lost dealing with .u.snap and the .ringBuffer. stuff. Proper implementation. Coincidentally, figuring this part out is likely all it requires to get streaming up haha

To this point, I’ve managed to get Dashboards to do a static query and show all the results in MasterTable – but when I go to streaming it gives me a “MasterTable” error message in the view box with the last line of data in MasterTable (I’m hoping to get last row by sym but I’ll deal with that later)

Can someone dumb this down for me so I can move on with my life?! 

Hi,

I think that in order to get a streaming dashboard, you’re correct in that it does require the .u.snap function. The way it seems to be implemented is that the .u.snap function needs to be defined, in the most simple form, as the table you want to stream in. So in your case, it seems to need to be defined as MasterTable, i.e.

.u.snap:{MasterTable}

This needs to be defined within the tickerplant process.

To then stream the data, you need to create a data grid and select the data source. Connect to the tickerplant process in dashboards connection management, select stream and select your table and then select a column to use as a key. Streaming updates based on the key, so in your case it seems that using the sym column as the key would be what’s needed as this will just give you the last record for that sym essentially.

Hopefully this helps explain things a little bit, let us know if you need any more help.

Thanks,

James

I’ve defined the .u.snap in its most basic form, but to no avail. I notice that in the connection manager I don’t have any tables shown (compared to the demo tables showing) – I assume .u.snap is to blame?

Is there a pdf or something I should be referencing for this, lol?