ralf-buero(a)kruedewagen.de wrote:
On Friday 16 September 2005 11:28, Brion Vibber
wrote:
MediaWiki is designed for internet-facing wikis
which have a single
well-known URL location. There is no support for changing the URL
path depending on who's visiting (among other things the URLs are
embedded in cached data).
Okay. What happens if MediaWiki is running behind a load-balancer? I
guess that the servers at big sites like Wikipedia are not directly
connected with their interfaces to the internet. They are behind
load-balancers or something similar.
Now, they should face a similar problem than me. If mediawiki sends a
redirect with the URL of the local interface, the load-balancer must
handle that. The browser will never see this IP address, but the
address of the load-balancer.
There is a single public-facing canonical URL for a given wiki page,
which all users everywhere will use. There is no one anywhere who will
use a different URL.
A connection from a client will go like this:
* Url like
http://en.wikipedia.org/wiki/Sandbox
* Browser looks up 'en.wikipedia.org' and gets the IP address of one of
our proxies
* Browser sends HTTP request to the proxy
* Proxy forwards HTTP request to a load balancer
* Load balancer forwards HTTP request to a web server
* Web server does processing, sends back data which flows back up the
chain to the browser.
The same URL is passed to every point in this chain; it never changes as
such. There is a mod_rewrite inside the Apache to convert form
/wiki/Sandbox to /w/index.php?title=Sandbox but that's an artifact of
our configuration and is in fact unnecessary (there are other ways to do
the same thing without that rewrite). The hostname never changes, and
there is no changing of URLs related to the proxying.
-- brion vibber (brion @
pobox.com)