Forum Discussion

tim_beynart's avatar
tim_beynart
Channel Surfer
10 years ago

HTTP Requests repeat forever, hammer server

Is there a known issue where roUrlTransfer can generate an endless flood of requests?
A few weeks ago, we had a report from a vendor that our application hammered their server with thousands of repeat requests. I figured it was a fluke, or they were somehow mistaken, but then I was testing and the same thing happened in my dev environment. I happened to have Charles proxy running and saw repeated requests going out, multiple times a second, over and over, until I exited the app. The requests failed, too, with empty responses (no headers).
Needless to say this is not cool.

3 Replies

  • Perhaps it's an error in your brightscript code, where you're checking the result before the request is finished, and then reissuing the request? If you post your code someone may be able to spot the problem.

    --Mark
  • I was mistaken, it is not a problem in roUrlTransfer. It happens when I pass an HLS maifest URL to an instance of roVideoPlayer
    There's a few layers of abstraction, but the implementation is nothing more than this:

    m.screen.contentList[0].Stream.url = url
    m.screen.Play()

    If the URL fails to respond (at least I think that's what triggers this), I get a flood of OnHttpError callbacks from the video player.