1
0
mirror of https://github.com/apache/httpd.git synced 2025-06-03 10:42:03 +03:00

52 Commits

Author SHA1 Message Date
Mladen Turk
7306af0a70 Return 503 only if the route matches some of the balancer members and nofailover=On is specified.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@556931 13f79535-47bb-0310-9956-ffa450edef68
2007-07-17 14:31:05 +00:00
Jean-Frederic Clere
e7a75e4f3e Fill notes "session-sticky" and subprocess_env "BALANCER_SESSION_STICKY"
correctly.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@554892 13f79535-47bb-0310-9956-ffa450edef68
2007-07-10 09:53:36 +00:00
Jean-Frederic Clere
3fe0224692 Don't display "PHPSESSIONID | PHPSESSIONID" but only
"PHPSESSIONID".


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@551126 13f79535-47bb-0310-9956-ffa450edef68
2007-06-27 11:39:03 +00:00
Jean-Frederic Clere
9e567f96de Remove the balancer modification logic of balancer-manager
because it can't work. And add the sticky_path to the
sticky display.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@551099 13f79535-47bb-0310-9956-ffa450edef68
2007-06-27 08:42:02 +00:00
Jean-Frederic Clere
4dee811cb9 Add sticky_path to solve PR41897.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@550519 13f79535-47bb-0310-9956-ffa450edef68
2007-06-25 14:42:25 +00:00
Ruediger Pluem
94743e8f7b * Preset the form fields for route and redirect with the values of the active
configuration in the scoreboard and not with the ones loaded from the
  configuration files.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@544930 13f79535-47bb-0310-9956-ffa450edef68
2007-06-06 20:02:56 +00:00
Jim Jagielski
bf5a6bc8e5 Fix compile warning:
mod_proxy_balancer.c:537: warning: unused variable 'rv'



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@484794 13f79535-47bb-0310-9956-ffa450edef68
2006-12-08 21:38:40 +00:00
Jim Jagielski
3b5d5bf319 Failure to unlock is very nasty, so log it to help
with troubleshooting.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@484792 13f79535-47bb-0310-9956-ffa450edef68
2006-12-08 21:37:08 +00:00
Jim Jagielski
ba2a767fe6 We are doing nothing here... but keep the stubs
in case we ever do.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@484789 13f79535-47bb-0310-9956-ffa450edef68
2006-12-08 21:29:20 +00:00
Jim Jagielski
792dfe200b Log when the lock fails.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@484787 13f79535-47bb-0310-9956-ffa450edef68
2006-12-08 21:26:40 +00:00
Jim Jagielski
83a044b23a No need for each ind lb method to increment the elected
element. Do so from the main calling func.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@484783 13f79535-47bb-0310-9956-ffa450edef68
2006-12-08 21:13:01 +00:00
Mladen Turk
f80b020c74 Add force recovery for balancer.
In case all balancer members were in error state 503
was returned until the recovery timeout expired.
The patch forces recovery in case all balancer members
are in error state regardless of recovery timeout
directive.
This fixes the time gap when 503 was returned and
backend was already up and running.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@451572 13f79535-47bb-0310-9956-ffa450edef68
2006-09-30 10:18:48 +00:00
Ruediger Pluem
483ddc121a * Set the new environment variable BALANCER_ROUTE_CHANGED if a worker with a
route different from the one supplied by the client had been chosen or if
  the client supplied no routing information for a balancer with sticky
  sessions.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@446929 13f79535-47bb-0310-9956-ffa450edef68
2006-09-16 19:49:41 +00:00
Jeff Trawick
743a621e8d Replace ap_get_server_version with ap_get_server_banner() and
ap_get_server_description().

High-level summary:

The full server version information is now included in the error log at
startup as well as server status reports, irrespective of the setting
of the ServerTokens directive.

Third-party modules must now use ap_get_server_banner() or 
ap_get_server_description() in place of ap_get_server_version().



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@440337 13f79535-47bb-0310-9956-ffa450edef68
2006-09-05 13:08:15 +00:00
Ruediger Pluem
3397848717 * Extract stickysession information correctly in the case that it is given
as parameter like in the following example:

  www.someplace.com/somewhere/?jsessionid=gggfgdufdfoef.server&parameter=value

  So far we were only able to handle stickysession information encoded in the
  following form:

  www.someplace.com/somewhere/;jsessionid=gggfgdufdfoef.server?parameter=value

PR: 40400


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@440160 13f79535-47bb-0310-9956-ffa450edef68
2006-09-04 19:51:52 +00:00
Jim Jagielski
3eeb5a123b Initialization change. Move to a different format
to force resets as well as a common technique, in case
_route is updated at some point.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@428361 13f79535-47bb-0310-9956-ffa450edef68
2006-08-03 11:41:14 +00:00
Jim Jagielski
585f146b66 Reset standby flags for each loop through the cluster sets
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@428352 13f79535-47bb-0310-9956-ffa450edef68
2006-08-03 11:30:11 +00:00
Jim Jagielski
dc9255aabe Good catch by Ruediger
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@427368 13f79535-47bb-0310-9956-ffa450edef68
2006-07-31 23:46:55 +00:00
Jim Jagielski
61a56451a3 Add in a very simple balancer "set" concept, which allows
for members to be assigned to a particular cluster set
such that members in lower-numbered sets are checked/used
before those in higher ones.

Also bundled in this are some HTML cleanups for the balancer
manager UI. Sorry for the mixins :)

Compiles/builds clean: passes test framework as well
as more normal usage tests ;)


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@427172 13f79535-47bb-0310-9956-ffa450edef68
2006-07-31 17:01:40 +00:00
Jim Jagielski
ae24222e23 The number of times elected as well as the i/o
of the workers is useful info to show in the
manager.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@421287 13f79535-47bb-0310-9956-ffa450edef68
2006-07-12 15:13:22 +00:00
Jim Jagielski
3e2c97f512 It never fails. I sit on a patch for awhile and
it's not until almost right after I commit it that
I think "hey, there's a better way to do that."
Anyway, I was never happy about the code
duplication of the primary/standby checks...
This fixes that.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@421283 13f79535-47bb-0310-9956-ffa450edef68
2006-07-12 15:01:15 +00:00
Jim Jagielski
0b80babf0b Add in hot-standby balancer member. If all other members
are disabled or not-usable, ONLY THEN will the hot
standby's be used.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@420986 13f79535-47bb-0310-9956-ffa450edef68
2006-07-11 20:39:38 +00:00
Roy T. Fielding
de659cbed0 update license header text
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@420983 13f79535-47bb-0310-9956-ffa450edef68
2006-07-11 20:33:53 +00:00
Jim Jagielski
92a185a104 Restructure the find_route_worker() function. Basically,
it should take care of knowing about usable and unusable
workers. By centralizing this logic, it will make it
easier and more streamlined to add in the forthcoming
hot-standby status workers.



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@420936 13f79535-47bb-0310-9956-ffa450edef68
2006-07-11 17:51:54 +00:00
Ruediger Pluem
c99bff74f3 * Retry worker chosen by client supplied route / redirect worker if it
is in error state before sending "Service Temporarily Unavailable".

PR: 38962
Submitted by: Christian Boitel <cboitel lfdj.com>
Reviewed by: rpluem


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@417443 13f79535-47bb-0310-9956-ffa450edef68
2006-06-27 12:05:43 +00:00
Ruediger Pluem
58f86ac058 * Add the following environment variables to expose the information
* about
  the route, the sticky session and the worker used during a request to
  other modules:

  BALANCER_SESSION_STICKY
  BALANCER_SESSION_ROUTE
  BALANCER_NAME
  BALANCER_WORKER_NAME
  BALANCER_WORKER_ROUTE

PR: 39806
Submitted by: Brian <brectanu gmail.com>
Reviewed by: rpluem


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@417238 13f79535-47bb-0310-9956-ffa450edef68
2006-06-26 16:59:38 +00:00
Garrett Rooney
ca55328af7 Merge the fcgi-proxy-dev branch to trunk, adding a FastCGI back end for
mod_proxy.  This log message is just a summary of the changes, for the
full original log messages see r357431:393955 in branches/fcgi-proxy-dev.

* modules/proxy/mod_proxy_fcgi.c: New file, holds the impementation of
  our new fcgi backend for mod_proxy.

* modules/proxy/fcgi_protocol.h: New file, holds constants and structures
  for the fcgi protocol.

* modules/proxy/mod_proxy_balancer.c
  (proxy_balancer_canon): Set up r->path_info, so the PATH_INFO env
   variable is correctly passed on to balancer workers.

* modules/proxy/config.m4: Build the new mod_proxy_fcgi module.

* support: Add fcgistarter to svn:ignore.

* support/Makefile.in: Build the new fcgistarter program.

* support/fcgistarter.c: New program, a helper for starting fcgi worker
  processes.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@396063 13f79535-47bb-0310-9956-ffa450edef68
2006-04-22 03:44:05 +00:00
Colm MacCarthaigh
dd95d7c37c Update the copyright year in all .c, .h and .xml files
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@395228 13f79535-47bb-0310-9956-ffa450edef68
2006-04-19 12:11:27 +00:00
Ruediger Pluem
4f88d90ea6 * Also initialize local data structures for workers of a balancer.
PR: 38227, 39267
Submitted by: James A. Robinson <jim.robinson stanford.edu>
Reviewed by: rpluem


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@394446 13f79535-47bb-0310-9956-ffa450edef68
2006-04-16 09:12:24 +00:00
Ruediger Pluem
9704233d80 * After r377780 the condition in the if clause never becomes true, because
ap_proxy_initialize_worker_share is always left with PROXY_WORKER_INITIALIZED
  set in workers->s->status. So remove this code to save cycles and avoid
  confusion.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@394065 13f79535-47bb-0310-9956-ffa450edef68
2006-04-14 11:30:04 +00:00
Joe Orton
b2e9ae5b1d * modules/proxy/mod_proxy_balancer.c: Include unistd.h to pick up
getpid() prototype.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@375310 13f79535-47bb-0310-9956-ffa450edef68
2006-02-06 16:35:20 +00:00
Ruediger Pluem
f6b46944d4 * Do not overwrite the status of initialized workers and respect the configured
status of uninitilized workers when creating a new child process.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@374929 13f79535-47bb-0310-9956-ffa450edef68
2006-02-04 21:25:48 +00:00
Ruediger Pluem
e708604555 * Fix PR37753. Off by one bug in get_path_param eats up too much of the string
such that session identifier for sticky sessions is never found in URL.

Submitted by: Kazuhiro Osawa <ko yappo.ne.jp>
Reviewed by: Ruediger Pluem


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@352010 13f79535-47bb-0310-9956-ffa450edef68
2005-12-03 20:17:11 +00:00
Jim Jagielski
5061d9fa92 No functional Change: Removing trailing whitespace. This also
means that "blank" lines consisting of just spaces or
tabs are now really blank lines


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@332306 13f79535-47bb-0310-9956-ffa450edef68
2005-11-10 15:11:44 +00:00
Jim Jagielski
be32e160ac mod_proxy_balancer: BalancerManager and proxies correctly handle
member workers with paths. PR36816. [Ruediger Pluem, Jim Jagielski]


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@312963 13f79535-47bb-0310-9956-ffa450edef68
2005-10-11 21:40:32 +00:00
Ruediger Pluem
13bceeee23 * Fix a declaration problem introduced in r195013 that is C99 but not ANSI C
compatible. Thus move declaration of *worker to the top of find_session_route
  to make it ANSI C compatible again.

Submitted by: NormW <normw bocnet.com.au>
Reviewed by: Ruediger Pluem


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@307389 13f79535-47bb-0310-9956-ffa450edef68
2005-10-09 10:59:06 +00:00
Ruediger Pluem
fc078f7336 * Fix PR36507 (mod_proxy_balancer does not handle sticky sessions with
tomcat correctly).


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@295013 13f79535-47bb-0310-9956-ffa450edef68
2005-10-05 07:59:36 +00:00
Joe Orton
8df46b6dd6 * modules/proxy/mod_proxy_balancer.c (balancer_handler): Fix gcc
warning; no functional change.

* modules/proxy/mod_proxy.c (set_balancer_param): Likewise.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@279973 13f79535-47bb-0310-9956-ffa450edef68
2005-09-10 09:10:27 +00:00
Jim Jagielski
22c5cb4728 Proxy balancer lbmethods are now registered as providers and not
via hooks. Move various find() functions back to mod_proxy_balancer
where they belong :)


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@279752 13f79535-47bb-0310-9956-ffa450edef68
2005-09-09 12:28:02 +00:00
Jim Jagielski
da3e833d30 Restruct of lbmethod find-best algo's, bypassing hook mechanism.
Looking into provider method, but until then... Prevent core dump
when balancer not in vhosts


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@279305 13f79535-47bb-0310-9956-ffa450edef68
2005-09-07 12:04:15 +00:00
Jim Jagielski
c208de0bcf Some simple debugging log entries
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@265505 13f79535-47bb-0310-9956-ffa450edef68
2005-08-31 15:19:27 +00:00
Mladen Turk
a75750ab89 Arghhh.... missed the version. Sorry for the noise.
Revert the hack for setting the lbmethod.
The problem is deeper inside caused by the
new hook to the balancer module that is never
called on WIN32.
Although the hack fixed core dump, the proxy is
still unusable because the configuration is failing
due to the empty lbmethod names array.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@233516 13f79535-47bb-0310-9956-ffa450edef68
2005-08-19 17:23:00 +00:00
Mladen Turk
f2b99c52c0 Revert the hack for setting the lbmethod.
The problem is deeper inside caused by the
new hook to the balancer module that is never
called on WIN32.
Although the hack fixed core dump, the proxy is
still unusable because the configuration is failing
due to the empty lbmethod names array.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@233514 13f79535-47bb-0310-9956-ffa450edef68
2005-08-19 17:19:54 +00:00
Mladen Turk
3b8fe8c738 Temporary make balancer working.
What is needed is a setup for the finder function
introduced, but never implemented.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@233468 13f79535-47bb-0310-9956-ffa450edef68
2005-08-19 11:58:36 +00:00
Jim Jagielski
487504d63b When using the LB Balancer manager, if you disabled
a member, then clicked on another member and/or
itself again, the member would be re-enabled. This
was due to the form being "submitted" and
'dw' being null (observed with Safari). Anyway,
moving to a radio makes it explicit.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@232314 13f79535-47bb-0310-9956-ffa450edef68
2005-08-12 15:31:03 +00:00
Jim Jagielski
a7d488a6d2 simple, functional interface to add additional balancer lb selection methods
without requiring code changes to mod_proxy/mod_proxy_balancer;
these can be implemented via sub-modules now.

Let the games begin...


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@232282 13f79535-47bb-0310-9956-ffa450edef68
2005-08-12 12:47:04 +00:00
Joe Orton
3169261900 * modules/proxy/mod_proxy_balancer.c (proxy_balancer_pre_request): Fix
another valid variable-may-be-used-uninitialized warning from GCC 4
(in the !balancer->sticky case, find_session_route returns NULL
without setting route).


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@193117 13f79535-47bb-0310-9956-ffa450edef68
2005-06-23 09:10:09 +00:00
Mladen Turk
e32503984e Set default number of maxattempts to the number of
balancer members.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@160847 13f79535-47bb-0310-9956-ffa450edef68
2005-04-11 08:42:33 +00:00
Mladen Turk
c4323f9615 Simplify canon_handler. Blancer can have only a single
scheme.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@160692 13f79535-47bb-0310-9956-ffa450edef68
2005-04-09 16:32:32 +00:00
Mladen Turk
76efadaa27 Add canon_handler for load balancer so that we have
query string passed to remote.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@160675 13f79535-47bb-0310-9956-ffa450edef68
2005-04-09 10:12:01 +00:00