After Ajax, how about Reverse Ajax

  1. #1

    After Ajax, how about Reverse Ajax

    I recently had a situation, where the client initiated a complex time-consuming operation on the server from the browser.

    During the time of the operation, I needed to continuously provide feedback in the browser on the progress of the overall operation and the exact thing that was being performed on the server.

    My goodness, thanx to [AjaxMethod]s, I was able to accomplish the entire task with little coding & inside an hour. The client clicked Submit, after which the button was disabled. Processing was initiated on the server, and a server-side [AjaxMethod] was polled per second to keep the client updated. It has all gone well. No page flickers, minimum traffic with light-weight Json.

    So, I was thinking if the process could be further improved. The only thing that came to mind was polling could have been avoided. A new technique is rising Reverse Ajax, that now enables javascript calls from server, through persistent Http connections. I haven't studied it in detail, nor have I used it.

    But, with Coolite providing the capability of calling server-side code from Javascript, how about doing the reverse, calling javascript from server-side code??

    I know this is ambitious. I believe this would take time to implement. But there is already atleast one library available for doing this from Java code. I am only suggesting the Coolite core team to look if it is a proposal worth considering.

    This would add teeth to the already powerful, ExtJs backed Coolite.
    ExtJs being a completely client-side library, it should NOT help in any way in this. So, I have not filed a similar request on ExtJs forums. Does anyone believe here ExtJs might help in any significant way in achieving Reverse Ajax??
  2. #2

    RE: After Ajax, how about Reverse Ajax

    Hi r_honey,

    We're actually working on solutions for both scenarios you describe: polling & open http connection.*


    The polling could be implemented today by using the TaskManager to and fireing an AjaxMethod during a given interval. That said, we are working on some helper functionality to wrap up those two jobs (TaskManager + AjaxMethod) into one handy class.*


    The open http connection option to provided true client-to-server and server-to-client communication is in the works. I don't have a time frame for when code will be available to test, but it is coming and it is a priority for us to implement.*




    Geoffrey McGill
    Founder
  3. #3

    RE: After Ajax, how about Reverse Ajax

    Good to know that Server to client communication using open Http connection is already in your to-do (or currently doing, whatever it is) list.

    I was not aware of the TaskManager class. Does it come from ExtJs, or is a pure Coolite creation??
    Right now, I am using setInterval() javascript function to manually invoke the [AjaxMethod].

    I agree with your time-frame point. You cannot provide a precise time-limit for these kindda things unless you already have the complete or majority of it ready.
  4. #4

    RE: After Ajax, how about Reverse Ajax

    Hi,

    TaskManager is ExtJS class with our changes which allow easly to call server-side handlers. Please see


    https://examples1.ext.net/#/Miscella...ager/Overview/




Similar Threads

  1. Ajax Post
    By adelaney in forum 2.x Help
    Replies: 1
    Last Post: Apr 16, 2012, 1:52 PM
  2. Help with Ajax Tabs
    By norphos in forum 1.x Help
    Replies: 0
    Last Post: May 11, 2011, 9:31 AM
  3. Page_ Ajax Load Complete BUG on Ajax Request
    By jeybonnet in forum 1.x Help
    Replies: 8
    Last Post: Jun 22, 2009, 11:19 AM
  4. Need help with Ajax Tab
    By lo230c in forum 1.x Help
    Replies: 3
    Last Post: Apr 07, 2009, 4:54 AM
  5. ASP.NET AJAX CallBack
    By tonymayoral in forum 1.x Help
    Replies: 2
    Last Post: Feb 07, 2009, 11:37 PM

Posting Permissions