Using RadCompression for http WCF?

4 posts, 0 answers
  1. Sunil
    Sunil avatar
    230 posts
    Member since:
    Jan 2004

    Posted 08 Feb 2011 Link to this post

    I have a situation where a http WCF service is hosted in IIS, and this service is called by a Winforms client based on Telerik's radcontrols for winforms.
    My question is, can I use RadCompression to compress the WCF service responses and if yes, then how would I implement it? I would think it should be possible since the http WCF is just another http website with a web.config file like any other ASP.Net website.

    Thanks
    Sunil
  2. Nikolay Rusev
    Admin
    Nikolay Rusev avatar
    2285 posts

    Posted 09 Feb 2011 Link to this post

    Hello Sunil,

    RadCompression is a HttpModule that must be enabled in the web.config for the web site where the service is hosted(namely IIS).

    Bellow is the related documentation on how to enable RadCompression:
    http://www.telerik.com/help/aspnet-ajax/radcompression.html

    Best wishes,
    Nikolay
    the Telerik team
    Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Sunil
    Sunil avatar
    230 posts
    Member since:
    Jan 2004

    Posted 10 Feb 2011 Link to this post

    Hi Nikolay,

    RadCompression does not work when used in a WCF. I tried the suggestions in link you provided but it doesn't do any compression on a large  6 MB response.
    In your link, you don't even explain how to enable it for  'Service.svc'  WCF file.
    If you still know something that wil make it work with WCF then let me know. Do you have any WCF sample, where RadCompression works?

    Thanks
    Sunil
  5. Nikolay Rusev
    Admin
    Nikolay Rusev avatar
    2285 posts

    Posted 16 Feb 2011 Link to this post

    Hello Sunil,

    As my colleague Radoslav mentioned, RadCompression will work if you have an asynchronous postback via ajax. By default the RadCompression module will compress AJAX requests only. If you could simulate such requests in WinForms application the compression will work as expected.

    Greetings,
    Nikolay
    the Telerik team
    Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
Back to Top