locked
Telerik AsyncUpload Error 500 RRS feed

  • Question

  • User1536465747 posted

    Hello,

    I have an AsyncUploadHandler that I assign to Telerik AsyncUpload control . It works fine in an older version 2019.1.215 but as soon as I upgrade to a newer version e.g. 2021.1.119 I start getting error 500

    I doubt that my handler is still referencing the old version but can't find where it happens and change it eventually. 

    Any ideas?

    Thank you very much

    Thursday, February 4, 2021 5:46 PM

Answers

All replies

  • User1535942433 posted

    Hi KulerMaster,

    According to your description,error 500 is a Server Error. What's the details of your errors? There are many factors cause this problems.

    1. RadAsyncUpload throws HTTP 500 with a red dot beside the uploaded file name - Make sure that the Telerik.Web.UI.WebResource.axd handler is registered in the web.config.

    2. Sys.WebForms.PageRequestManagerServerErrorException: An unknown error occurred while processing the request on the server. The status code returned from the server was: 500 - Usually such an error is thrown when multiple (or nested) AJAX requests are initiated in one and the same time or there is a server error thrown during an AJAX update. You can disable temporary the AJAX on the page in order to see what the actual error thrown on the page is and debug further the cause of it. You can see how to do this easily here: Get more descriptive errors by disabling AJAX. Also make sure that the handlers are registered properly inside the and section of the web.config file as explained at Mandatory Additions to the web.config. You can find other possible reason for the error on ASP.NET, The status code returned from the server was: 500 and Error: Sys.WebForms.PageRequestManagerServerErrorException. Another way to look for the cause of the problem is to remove the AJAX settings one by one unless you find the one leading to the error and, respectively, the controls which updatе is causing it.

    More details,you could refer to below article:

    https://docs.telerik.com/devtools/aspnet-ajax/general-information/troubleshooting/web-resources-troubleshooting

    Best regards,

    Yijing Sun

    Friday, February 5, 2021 2:33 AM
  • User1536465747 posted

    Thank you for the reply!

    I am sure that WebResource it's registered correctly because in Chrome I see the following error:

    RadAsyncUpload handler is registered successfully, however, it may not be accessed directly.

    2. I am not using AJAX manager at all. It's just a page with AsyncUpload control. 

    If I downgrade to 2019.x.xxx it works like a charm but as soon as I upgrade to 2020.x.xxx it stop working displaying that red dot. 

    P.S. this is the main reason why I need to upgrade:

    https://www.telerik.com/support/kb/aspnet-ajax/details/allows-javascriptserializer-deserialization

    Any ideas? Thank you so much in advance

    Friday, February 5, 2021 8:35 AM
  • User753101303 posted

    Hi,

    By default , most server side errors are written to the Wndows event log. If finding nothing I would check the IIS log to see the exact 500.x error and then  check that code against a list such as https://support.microsoft.com/en-us/topic/the-http-status-code-in-iis-7-and-later-versions-4d593f41-8688-9199-0be2-ac587ab25070#:~:text=The%20HTTP%20status%20code%20is,that%20a%20request%20is%20unsuccessful.

    At this point you should have a clear understanding about what happens and can move at solving a defined problem.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Friday, February 5, 2021 8:55 AM
  • User1536465747 posted

    Hi,

    By default , most server side errors are written to the Wndows event log. If finding nothing I would check the IIS log to see the exact 500.x error and then  check that code against a list such as https://support.microsoft.com/en-us/topic/the-http-status-code-in-iis-7-and-later-versions-4d593f41-8688-9199-0be2-ac587ab25070#:~:text=The%20HTTP%20status%20code%20is,that%20a%20request%20is%20unsuccessful.

    At this point you should have a clear understanding about what happens and can move at solving a defined problem.

    Hello Patrice,

    I found the following exception in the Event Viewer but I didn't find it helpful in my situation:

    Exception information: 
        Exception type: CryptographicException 
        Exception message: The cryptographic operation has failed!
       at Telerik.Web.UI.CryptoExceptionThrower.ThrowGenericCryptoException[T]()
       at Telerik.Web.UI.CryptoExceptionThrower.ThrowIfFails[T](Func`1 function)
       at Telerik.Web.UI.CryptoService.CheckWhitelistTypes(Type type, String allowedCustomMetaTypes, String uploadMetaDataFullName)
       at Telerik.Web.UI.AsyncUploadHandler.GetConfiguration(String rawData)
       at Telerik.Web.UI.AsyncUploadHandler.EnsureSetup()
       at Telerik.Web.UI.AsyncUploadHandler.ProcessRequest(HttpContext context)
       at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
       at System.Web.HttpApplication.ExecuteStepImpl(IExecutionStep step)
       at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    
     
     
    Request information: 
        Request URL: https://localhost:44389/Handler/AsyncUploader.ashx?type=rau 
        Request path: /Handler/AsyncUploader.ashx 

    Do you guys have any suggestions? I think that I need to add something in the web.config but I am not quite sure what is that :(

    Thank you

    Friday, February 5, 2021 10:16 AM
  • User1536465747 posted

    If anybody else has the same issue, I've found the solution:

    https://docs.telerik.com/devtools/aspnet-ajax/knowledge-base/asyncupload-the-cryptographic-operation-has-failed-error-after-upgrade

    Just enter the Your_Namespace + Name_Of_Your_AsyncUploadConfiguration and it will work e.g. 

    <add key="Telerik.Upload.AllowedCustomMetaDataTypes" value="YourNameSpace.YourAsyncUploadConfigurationClass" />

    HTH

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Friday, February 5, 2021 10:53 AM