How to notify pivotgrid about an exception when streaming data

Answered
mstrukov asked on July 11, 2016

5 answers

Public
mstrukov July 11, 2016

Sorry, posted the question before specifying the details. Please download a sample project here.  It streams half of the data to the grid and then throws an exception. The exception is then catched and handled. Any way to notify the grid about the exception so it displays an error alert instead of just displaying half of the data.

Public
Ian Sadovy Ian Sadovy Flexmonster July 12, 2016

Hello Maxim,
 
Thank you for the request.
Unfortunately, there is no way to handle error while streaming the data.
With regular response (not streaming) it is possible to simply change the response status code if an error occurred.
Could you please specify in what cases exception is thrown?
Also, we have improved our Compressor library to support variety of SQL databases and streaming out of the box, please find more information in the documentation.
 
Regards,
Ian

Public
mstrukov July 13, 2016

Hi Ian,
 
The most common case is a timeout issue here, when pulling large data sets part of the data might have already be sent. Another common case for us is cancellation functionality. We have a cancel button on UI which allows to cancel report query if it takes too long, a user has changed his mind or noticed a typo in the report filters. In this case part of the data might have already been sent as well when the query is cancelled.
 
Thank you for the compressor update, I will take a look.

Public
Ian Sadovy Ian Sadovy Flexmonster July 14, 2016

Hi!
The idea with cancellation looks really reasonable and we'll add this feature to the roadmap.
Anyway, try the updated compressor it will help you to resolve timeout issue.

Public
Tanya Gryshko Tanya Gryshko Flexmonster December 5, 2016

Hello Maxim and all Flexmonster users,
Starting from version 2.3, event list was greatly extended. For instance, dataerror event is triggered when some error occurred during the loading of data. Find more details here: http://www.flexmonster.com/api/dataerror/
Regards,
Tanya

Please login or Register to Submit Answer