Spreadsheet SAVE DATA CHANGES send fail - Status Code 502 error

2 Answers 45 Views
Spreadsheet
n/a
Top achievements
Rank 1
Iron
Iron
n/a asked on 14 Dec 2022, 07:40 AM

hello.

url:
https://demos.telerik.com/kendo-ui/spreadsheet/datasource
I developed a program by applying this page and I am using it well.

However, if there is a lot of transmission data when trying "SAVE DATA CHANGES", an error occurs. It is not an error that occurs in the target url, but an error that cannot reach the target url itself.

All the data from the above url
vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv
If I change it to , and save it, I get an error.

 

 

method : get

Because it is a get, an error will occur.
On my site, I get an error even though I tried to post.

 

 

It's not even that the size of the data to be transferred is large.
Moreover, an error occurs even though it is not a get but a post.
The number of data passed is not large.
This is not an error occurring in the target url, but the transmission itself has failed.

What are the countermeasures? What are the alternatives?
It's not big data, but I get an error at "SAVE DATA CHANGES".
What could be the workaround?


please solve it thank you


 

 

Neli
Telerik team
commented on 19 Dec 2022, 07:03 AM

Hi Won,

I tried to replicate the issue but to no avail. In the screencast linked here, you could see that the request is successfully sent by clicking the 'Submit' button in our demos. Could you please let me know if I am missing something? Is there something specific in the steps that should be followed to replicate the issue? Could you please try to use the Spreadsheet demo and save data in different browsers and let us know if the issue occurs on every browser?

Looking forward to your reply.

Regards,

Neli

Vincent
Top achievements
Rank 1
Iron
commented on 25 Dec 2022, 06:43 PM

After 2022R2SP1 version. there is a bug in spreadsheet datasoure. when dill down the cell, the datasource will not be changed. only input text can trigger the change event.
n/a
Top achievements
Rank 1
Iron
Iron
commented on 29 Dec 2022, 09:08 AM

This is the URL from your example site.

https://dojo.telerik.com/@kjvjung/UNITESEx

In order to explain the main problem

Added [ method: "POST", ]  in function onSubmit .

On my site, adding [ method: "POST", ]  sends it as POST .

However, in dojo.telerik.com, it is not POST and continues to be GET.

So, it's frustrating.

If dojo.telerik.com is also POSTed, I can pinpoint the problem more easily.
It's easy to explain what the problem is.

By the way, why is [ method: "POST", ]  not recognized in dojo.telerik.com?

On my site, POST works fine.

Neli
Telerik team
commented on 03 Jan 2023, 08:13 AM

Hi,

The observed issue is due to that the mentioned request sends jsonp requests to its endpoint. In that case, the request will always be of type GET. Below is some more general info on that topic:

- https://stackoverflow.com/questions/4508198/how-to-use-type-post-in-jsonp-ajax-call

If you could use instead JSON requests/responses, you can send data with a POST, which will automatically move data in the body:
   

 create: {
        dataType: "json",
        type: "post",
        url: "//endpoint url",
    },

I hope that the above helps.

Regards,

Neli

n/a
Top achievements
Rank 1
Iron
Iron
commented on 03 Jan 2023, 08:52 AM

We want to show you the results, not theories or explanations.
Code directly from the URL below and leave the result.
Even if you change it to POST, it will only be recognized as GET.
I wish you success.

 

https://dojo.telerik.com/@kjvjung/UNITESEx

 

Neli
Telerik team
commented on 06 Jan 2023, 07:06 AM

Hi Won,

Thank you for reaching out.

As mentioned previously the described behavior is not caused by the Dojo or by Kendo. If you try to send an jsonp ajax request from a standard html page and without using Kendo scripts the behavior will be the same.

Attached you will find two html files. The first has the same content as the Dojo sent previously and the second one does not use Kendo library. It reference only jQuery. However in both examples when sending the ajax jsonp request, the Request Method in the browser is GET. Let me know if I am missing something.

Regards,

Neli

2 Answers, 1 is accepted

Sort by
0
Vincent
Top achievements
Rank 1
Iron
answered on 25 Dec 2022, 06:39 PM | edited on 25 Dec 2022, 06:41 PM

After 2022R2SP1 version. there is a bug in spreadsheet datasoure. when dill down the cell, the datasource will not be changed. only input text can trigger the change event.

Peter Milchev
Telerik team
commented on 28 Dec 2022, 01:18 PM

Hi Vincent, We have logged the issue in our feedback portal where you can follow its progress:

In the future, please create new threads or bug reports/tickets when your question is not related to the original topic of the thread. This will ensure the threads are short and concise, address a single topic and make them easier to navigate in.

0
onplatform
Top achievements
Rank 1
Iron
answered on 24 Jan 2023, 02:37 AM
I fixed the problem by just changing the options.
Removing the option solved the problem.

contentType: "application/json", // BAD
I commented it out and it was resolved.
//contentType: "application/json", // Good

Commenting it out made it possible to send large amounts.
I don't know why.
But it's a very important point.
This is a point you must remember.

 

 

$.ajax({
                    url: "list_edit_save.php?RealPid=speedmis000314&MisJoinPid=&key_aliasName=idx",
                    data: { models: replaceAll(kendo.stringify(e.data), String.fromCharCode(12288), "") },
                    //contentType: "application/json",  
                    dataType: "jsonp",
                    method: "POST",

.....

Neli
Telerik team
commented on 26 Jan 2023, 12:31 PM

Thank you for sharing the solution that resolved the issue in your side. I am sure it will be helpful to the other users in the forum.

Regards,

Neli

Tags
Spreadsheet
Asked by
n/a
Top achievements
Rank 1
Iron
Iron
Answers by
Vincent
Top achievements
Rank 1
Iron
onplatform
Top achievements
Rank 1
Iron
Share this question
or