This is a migrated thread and some comments may be shown as answers.

requestEnd, when is it fired?

5 Answers 1143 Views
Data Source
This is a migrated thread and some comments may be shown as answers.
Bilal
Top achievements
Rank 2
Bilal asked on 08 Jun 2015, 10:23 AM

Hi,

From what I've read, requestEnd fires at the end of the request to signal that the operation is completed.

First, in case the error event of DataSource is fired, will the requestEnd also fire?

Also, in case there are records created and others updated, DataSource will fire two requests to server (batch mode), one for creation and another for updating. requestEnd fires twice in this case? Or just once, after both requests have been updated? 

 

Regards

Bilal

5 Answers, 1 is accepted

Sort by
0
Kiril Nikolov
Telerik team
answered on 09 Jun 2015, 01:21 PM

Hello Bilal,

The requestEnd event will be fired when the error event is fired, the thing is that it will be fired for every single dataSource request, just to indicate the request is no longer in process and it is completed either with error or with success.

Regards,
Kiril Nikolov
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
0
Bilal
Top achievements
Rank 2
answered on 10 Jun 2015, 06:17 AM

Thanks for the reply. Just an inquiry, requestEnd will be fired when error event is fired? Didn't get well that statement.

 

Best regards

Bilal Haidar

 

0
Kiril Nikolov
Telerik team
answered on 10 Jun 2015, 12:06 PM

Hello Bilal,

It will be fired when the error is fired as well. But you can easily test that in your project as well.

Regards,
Kiril Nikolov
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
0
n/a
Top achievements
Rank 1
answered on 01 Jun 2018, 03:32 PM

My test indicate that requestStart and requestEnd also fire when a grid filter or a sort is executed (even if serverFiltering and serverSorting is set to false)

When these events fire the requestStart or requestEnd event, the resulting parameter object "type" attribute is set to "read", but there is no network action. I can test for an e.response with requestEnd, but there appears to be no way to determine the true nature of the event using requestStart.

This seems to me to be a bug.

0
Ivan Danchev
Telerik team
answered on 05 Jun 2018, 07:27 AM
Hello James,

The requestStart and requestEnd events firing in this scenario is expected and by design. For more details see Konstantin's reply in the following forum thread.

Regards,
Ivan Danchev
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Tags
Data Source
Asked by
Bilal
Top achievements
Rank 2
Answers by
Kiril Nikolov
Telerik team
Bilal
Top achievements
Rank 2
n/a
Top achievements
Rank 1
Ivan Danchev
Telerik team
Share this question
or