Skip to content

Commit 3cc8bba

Browse files
Merge branch 'release/4.4.8'
2 parents 8f3e537 + 71f89d8 commit 3cc8bba

File tree

7 files changed

+85
-17
lines changed

7 files changed

+85
-17
lines changed

docs/release-notes/index.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ Release Notes
55
.. toctree::
66
:maxdepth: 2
77

8+
version-4.4.8.rst
89
version-4.4.7.rst
910
version-4.4.6.rst
1011
version-4.4.5.rst

docs/release-notes/version-4.4.8.rst

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
=============
2+
Version 4.4.8
3+
=============
4+
5+
Version 4.4.8 of mod_wsgi can be obtained from:
6+
7+
https://codeload.github.com/GrahamDumpleton/mod_wsgi/tar.gz/4.4.8
8+
9+
For details on the availability of Windows binaries see:
10+
11+
https://github.com/GrahamDumpleton/mod_wsgi/tree/master/win32
12+
13+
Bugs Fixed
14+
----------
15+
16+
1. The eviction timeout was not being correctly applied when request timeout
17+
wasn't being applied at the same time. It may have partly worked if any of
18+
inactivity or graceful timeout were also specified, but the application of
19+
the timeout may still have been delayed.
20+
21+
New Features
22+
------------
23+
24+
1. Added the ``--error-log-name`` option to ``mod_wsgi-express`` to allow
25+
the name of the file used for the error log, when being written to the log
26+
directory, to be overridden.
27+
28+
2. Added the ``--access-log-name`` option to ``mod_wsgi-express`` to allow
29+
the name of the file used for the access log, when being written to the log
30+
directory, to be overridden.
31+
32+
3. Added the ``--startup-log-name`` option to ``mod_wsgi-express`` to allow
33+
the name of the file used for the startup log, when being written to the log
34+
directory, to be overridden.

setup.py

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -237,21 +237,21 @@ def get_apxs_config(query):
237237
WITH_HTTPD_PACKAGE = %(WITH_HTTPD_PACKAGE)r
238238
239239
if WITH_HTTPD_PACKAGE:
240-
import mod_wsgi.httpd
241-
PACKAGES = os.path.join(os.path.dirname(mod_wsgi.httpd.__file__))
242-
BINDIR = os.path.join(PACKAGES, 'bin')
240+
from mod_wsgi_packages.httpd import __file__ as PACKAGES_ROOTDIR
241+
PACKAGES_ROOTDIR = os.path.dirname(PACKAGES_ROOTDIR)
242+
BINDIR = os.path.join(PACKAGES_ROOTDIR, 'bin')
243243
SBINDIR = BINDIR
244-
LIBEXECDIR = os.path.join(PACKAGES, 'modules')
245-
SHLIBPATH = os.path.join(PACKAGES, 'lib')
244+
LIBEXECDIR = os.path.join(PACKAGES_ROOTDIR, 'modules')
245+
SHLIBPATH = os.path.join(PACKAGES_ROOTDIR, 'lib')
246246
elif WITH_TARBALL_PACKAGE:
247-
import mod_wsgi.packages
248-
PACKAGES = os.path.join(os.path.dirname(mod_wsgi.packages.__file__))
249-
BINDIR = os.path.join(PACKAGES, 'apache', 'bin')
247+
from mod_wsgi.packages import __file__ as PACKAGES_ROOTDIR
248+
PACKAGES_ROOTDIR = os.path.dirname(PACKAGES_ROOTDIR)
249+
BINDIR = os.path.join(PACKAGES_ROOTDIR, 'apache', 'bin')
250250
SBINDIR = BINDIR
251-
LIBEXECDIR = os.path.join(PACKAGES, 'apache', 'modules')
251+
LIBEXECDIR = os.path.join(PACKAGES_ROOTDIR, 'apache', 'modules')
252252
SHLIBPATH = []
253-
SHLIBPATH.append(os.path.join(PACKAGES, 'apr-util', 'lib'))
254-
SHLIBPATH.append(os.path.join(PACKAGES, 'apr', 'lib'))
253+
SHLIBPATH.append(os.path.join(PACKAGES_ROOTDIR, 'apr-util', 'lib'))
254+
SHLIBPATH.append(os.path.join(PACKAGES_ROOTDIR, 'apr', 'lib'))
255255
SHLIBPATH = ':'.join(SHLIBPATH)
256256
else:
257257
BINDIR = '%(BINDIR)s'

src/server/__init__.py

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1912,6 +1912,16 @@ def check_percentage(option, opt_str, value, parser):
19121912
optparse.make_option('--access-log-format', metavar='FORMAT',
19131913
help='Specify the format of the access log records.'),
19141914

1915+
optparse.make_option('--error-log-name', metavar='FILE-NAME',
1916+
default='error_log', help='Specify the name of the error '
1917+
'log file when it is being written to the log directory.'),
1918+
optparse.make_option('--access-log-name', metavar='FILE-NAME',
1919+
default='access_log', help='Specify the name of the access '
1920+
'log file when it is being written to the log directory.'),
1921+
optparse.make_option('--startup-log-name', metavar='FILE-NAME',
1922+
default='startup_log', help='Specify the name of the startup '
1923+
'log file when it is being written to the log directory.'),
1924+
19151925
optparse.make_option('--rotate-logs', action='store_true', default=False,
19161926
help='Flag indicating whether log rotation should be performed.'),
19171927
optparse.make_option('--max-log-size', default=5, type='int',
@@ -2215,7 +2225,7 @@ def _cmd_setup_server(command, args, options):
22152225

22162226
if not options['log_to_terminal']:
22172227
options['error_log_file'] = os.path.join(options['log_directory'],
2218-
'error_log')
2228+
options['error_log_name'])
22192229
else:
22202230
try:
22212231
with open('/dev/stderr', 'w'):
@@ -2228,7 +2238,7 @@ def _cmd_setup_server(command, args, options):
22282238

22292239
if not options['log_to_terminal']:
22302240
options['access_log_file'] = os.path.join(
2231-
options['log_directory'], 'access_log')
2241+
options['log_directory'], options['access_log_name'])
22322242
else:
22332243
try:
22342244
with open('/dev/stdout', 'w'):
@@ -2456,7 +2466,7 @@ def _cmd_setup_server(command, args, options):
24562466
if options['startup_log']:
24572467
if not options['log_to_terminal']:
24582468
options['startup_log_file'] = os.path.join(
2459-
options['log_directory'], 'startup_log')
2469+
options['log_directory'], options['startup_log_name'])
24602470
else:
24612471
try:
24622472
with open('/dev/stderr', 'w'):

src/server/mod_wsgi.c

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8421,6 +8421,29 @@ static void *wsgi_monitor_thread(apr_thread_t *thd, void *data)
84218421
}
84228422
}
84238423

8424+
if (!restart && wsgi_eviction_timeout) {
8425+
if (graceful_time) {
8426+
if (graceful_time <= now) {
8427+
ap_log_error(APLOG_MARK, APLOG_INFO, 0, wsgi_server,
8428+
"mod_wsgi (pid=%d): Daemon process "
8429+
"graceful timer expired '%s'.", getpid(),
8430+
group->name);
8431+
8432+
restart = 1;
8433+
}
8434+
else {
8435+
if (!period || ((graceful_time - now) < period))
8436+
period = graceful_time - now;
8437+
else if (wsgi_eviction_timeout < period)
8438+
period = wsgi_eviction_timeout;
8439+
}
8440+
}
8441+
else {
8442+
if (!period || (wsgi_eviction_timeout < period))
8443+
period = wsgi_eviction_timeout;
8444+
}
8445+
}
8446+
84248447
if (restart) {
84258448
wsgi_daemon_shutdown++;
84268449
kill(getpid(), SIGINT);

src/server/wsgi_version.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@
2525

2626
#define MOD_WSGI_MAJORVERSION_NUMBER 4
2727
#define MOD_WSGI_MINORVERSION_NUMBER 4
28-
#define MOD_WSGI_MICROVERSION_NUMBER 7
29-
#define MOD_WSGI_VERSION_STRING "4.4.7"
28+
#define MOD_WSGI_MICROVERSION_NUMBER 8
29+
#define MOD_WSGI_VERSION_STRING "4.4.8"
3030

3131
/* ------------------------------------------------------------------------- */
3232

win32/README.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ version of the Microsoft C/C++ compiler as the version of Python you are
2121
using.
2222

2323
4. That you are using a mod_wsgi binary built with the same version of
24-
the Microsoft C/++ compiler as the version of Python you are using.
24+
the Microsoft C/C++ compiler as the version of Python you are using.
2525

2626
The Microsoft C/C++ compiler versions which were used for various Python
2727
versions are:

0 commit comments

Comments
 (0)