FAQ
As I have explored CF for a few days, I found when visiting a running App,
my requests from browser is redirecting to App instances by some RANDOM
way. But I'm not very clear about this mechanism.

So, can anyone show me where can I see the part of code responsible for
requests processing in github, especially how does router find app
instances randomly. Are there any algorithms here or not?

I'm very interested in this part actually.

Search Discussions

  • Chunjie Zhu at Jul 2, 2012 at 5:46 am
    You may get the answer from this point.

    https://github.com/cloudfoundry/router/blob/master/lib/router/router_uls_server.rb#L31

    Regards,
    Chunjie

    ----- Original Message -----

    From: "磊张" <resouer@163.com>
    To: vcap-dev@cloudfoundry.org
    Sent: Monday, July 2, 2012 1:03:49 PM
    Subject: [vcap-dev] Question about Router and request redirecting mechanism in CF among app instances.

    As I have explored CF for a few days, I found when visiting a running App, my requests from browser is redirecting to App instances by some RANDOM way. But I'm not very clear about this mechanism.

    So, can anyone show me where can I see the part of code responsible for requests processing in github, especially how does router find app instances randomly. Are there any algorithms here or not?

    I'm very interested in this part actually.
  • 磊张 at Jul 2, 2012 at 6:14 am
    Thanks a lot. It save me a lot trouble to hack by myself.

    在 2012年7月2日星期一UTC+8下午1时03分49秒,磊张写道:
    As I have explored CF for a few days, I found when visiting a running App,
    my requests from browser is redirecting to App instances by some RANDOM
    way. But I'm not very clear about this mechanism.

    So, can anyone show me where can I see the part of code responsible for
    requests processing in github, especially how does router find app
    instances randomly. Are there any algorithms here or not?

    I'm very interested in this part actually.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupvcap-dev @
postedJul 2, '12 at 5:03a
activeJul 2, '12 at 6:14a
posts3
users2

2 users in discussion

磊张: 2 posts Chunjie Zhu: 1 post

People

Translate

site design / logo © 2022 Grokbase