1
0
mirror of https://github.com/apache/httpd.git synced 2025-11-05 05:30:39 +03:00
Commit Graph

32 Commits

Author SHA1 Message Date
Stefan Fritsch
92e366007c Add lots of unique tags to error log messages
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1209766 13f79535-47bb-0310-9956-ffa450edef68
2011-12-02 23:02:04 +00:00
Stefan Fritsch
5c005263d5 Fix a potential NULL pointer dereference found by clang.
Add a AP_DEBUG_ASSERT to quiet a clang false positive.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1180329 13f79535-47bb-0310-9956-ffa450edef68
2011-10-08 07:41:50 +00:00
Jim Jagielski
427c85bd23 Cleanup effort in prep for GA push:
Trim trailing whitespace... no func change



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1174751 13f79535-47bb-0310-9956-ffa450edef68
2011-09-23 13:39:32 +00:00
Stefan Fritsch
2014acf62f Improvements found by cppcheck:
remove some unused variables and dead assignments, reduce the scope of some
variables, add some parens to improve readability


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1103459 13f79535-47bb-0310-9956-ffa450edef68
2011-05-15 16:58:45 +00:00
Jeff Trawick
ddf06604b5 enable DEFAULT_REL_RUNTIMEDIR on NetWare and Windows
this commit is missing the Windows and NetWare build
logic to copy the appropriate file to include/ap_config_layout.h


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1086073 13f79535-47bb-0310-9956-ffa450edef68
2011-03-27 23:51:18 +00:00
Joe Orton
eb271f86eb * modules/cache/mod_socache_shmcb.c: Comment tweak.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1059354 13f79535-47bb-0310-9956-ffa450edef68
2011-01-15 15:17:13 +00:00
William A. Rowe Jr
661afad48c Clean shmcb iterator call syntax and return value
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@960073 13f79535-47bb-0310-9956-ffa450edef68
2010-07-02 18:00:26 +00:00
William A. Rowe Jr
5740b5cfd9 Introduce an socache iterator 'userctx' for the user to track the
context of their own callback.

Breaks API, but we probably wanted an mmn reset between .6 and .7
betas for unintentional/unnoticed ABI breaks.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@958157 13f79535-47bb-0310-9956-ffa450edef68
2010-06-26 00:26:01 +00:00
William A. Rowe Jr
7a6e700e43 Tally replacements seperately from new-stores. Of course the actual
replacement logic doesn't work terribly well right now, as discussed
on list.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@958092 13f79535-47bb-0310-9956-ffa450edef68
2010-06-25 19:21:30 +00:00
Nick Kew
f877509b61 Fix return values from socache modules when a key is not found in cache
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@957235 13f79535-47bb-0310-9956-ffa450edef68
2010-06-23 15:04:57 +00:00
Stefan Fritsch
ebb62867fb Use the new APLOG_USE_MODULE/AP_DECLARE_MODULE macros everywhere to take
advantage of per-module loglevels


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@951895 13f79535-47bb-0310-9956-ffa450edef68
2010-06-06 16:59:50 +00:00
Jim Jagielski
f90bc4f900 Align "hidden" function names with external... picky, but
less confusing


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@923791 13f79535-47bb-0310-9956-ffa450edef68
2010-03-16 15:01:55 +00:00
Jeff Trawick
2052575a36 fix these warnings (and presumably a similar one in mod_socache_dc.c):
mod_socache_shmcb.c:625: warning: no previous prototype for ‘socache_shmcb_iterate’
mod_socache_dbm.c:505: warning: no previous prototype for ‘socache_dbm_iterate’
mod_socache_memcache.c:290: warning: no previous prototype for ‘socache_mc_iterate’


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@918655 13f79535-47bb-0310-9956-ffa450edef68
2010-03-03 19:32:58 +00:00
Ruediger Pluem
d0b18c8e45 * Silence compiler warning
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@911528 13f79535-47bb-0310-9956-ffa450edef68
2010-02-18 18:59:26 +00:00
Jeff Trawick
7dea349012 fix additional use of "session" terminology, following r907917
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@908168 13f79535-47bb-0310-9956-ffa450edef68
2010-02-09 19:34:51 +00:00
Jeff Trawick
2ef6f99566 style tweaks
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@908042 13f79535-47bb-0310-9956-ffa450edef68
2010-02-09 14:17:46 +00:00
William A. Rowe Jr
4444e07d2d Illustrate an ->iterator() implementation for mod_socache_shmcb.
Clarify that the iterator aught will make the users' life easier
by appending trailing \0 null chars.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@907937 13f79535-47bb-0310-9956-ffa450edef68
2010-02-09 05:48:58 +00:00
William A. Rowe Jr
3d0fbbfd06 Fix inadvertent changes and be more verbose and correct in logging
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@907933 13f79535-47bb-0310-9956-ffa450edef68
2010-02-09 04:53:47 +00:00
William A. Rowe Jr
d633f7e8e9 Track time now for retrieve
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@907924 13f79535-47bb-0310-9956-ffa450edef68
2010-02-09 04:07:19 +00:00
William A. Rowe Jr
69de2ecbd2 Do not expire an entire subcache on ->retrieve (doh!); only expire a cache hit
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@907923 13f79535-47bb-0310-9956-ffa450edef68
2010-02-09 04:04:42 +00:00
William A. Rowe Jr
3cc4b9db61 distcache already demonstrates sub-second resolutions, but much more
importantly, let us not introduce more Y2k38 bugs?

Changes the ->store method to take expiry as an apr_time_t, and introduce
a placeholder to implement provider-specific iterators of the current
elements of an socache store.

Cleans up confusion where expiry might be confused with a timeout-period.

Finally clean up some hUngarian noteAtion.  Someones' hands need to be slapped.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@907917 13f79535-47bb-0310-9956-ffa450edef68
2010-02-09 03:43:18 +00:00
Stefan Fritsch
a67fd0c26d Only allow parens in filename if cachesize is given. Return error otherwise
to catch missing parens.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@829362 13f79535-47bb-0310-9956-ffa450edef68
2009-10-24 13:29:03 +00:00
Stefan Fritsch
af5398f427 Only parse cache size in parens at the end of the string. Fixes SSLSessionCache
directive mis-parsing parens in pathname.

PR: 47945


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@829185 13f79535-47bb-0310-9956-ffa450edef68
2009-10-23 19:27:32 +00:00
Joe Orton
e1286998c4 * modules/cache/mod_socache_memcache.c,
modules/cache/mod_socache_shmcb.c, modules/cache/mod_socache_dbm.c:
  Remove references to "SSL" throughout comments and code.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@757396 13f79535-47bb-0310-9956-ffa450edef68
2009-03-23 13:18:06 +00:00
William A. Rowe Jr
7266c515bb ditto hack from mpm_default.h
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@728787 13f79535-47bb-0310-9956-ffa450edef68
2008-12-22 21:34:59 +00:00
Joe Orton
aa062c60f3 socache API tweaks based on chrisd's review:
* include/ap_socache.h (ap_socache_provider_t::store): Take a pool.
  (ap_socache_provider_t::retrieve): Guarantee APR_NOTFOUND for a
  "not found" result.
  (ap_socache_provider_t::remove): Return an apr_status_t.

* modules/cache/mod_socache_dc.c, modules/cache/mod_socache_dbm.c,
  modules/cache/mod_socache_shmcb,
  modules/cache/mod_socache_memcache.c: Adjust accordingly.

* modules/ssl/ssl_scache.c (ssl_scache_store): Pass pool to
  sesscache->store.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@726059 13f79535-47bb-0310-9956-ffa450edef68
2008-12-12 15:56:15 +00:00
Joe Orton
b078f2374e * include/ap_socache.h: Define AP_SOCACHE_DEFAULT_PROVIDER as a
default provider name, to allow consumers to use a default provider
  if not configured otherwise.

* modules/cache/mod_socache_shmcb.c (register_hooks): Register shmcb
  as the default provider.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@724723 13f79535-47bb-0310-9956-ffa450edef68
2008-12-09 14:52:59 +00:00
Joe Orton
dce91079c1 Reduce config overhead for use of socache interface by allowing
default paths to be used if none are configured:

* include/ap_socache.h (ap_socache_provider_t::create):
  Allow arg to be NULL to force use of defaults.
  (ap_socache_provider_t::init): Rename 'namespace' parameter to
  'cname' and restrict to allow use in filesystem paths.
  
* modules/cache/mod_socache_dbm.c (socache_dbm_create, 
  socache_dbm_init),
  modules/cache/mod_socache_shmcb.c (socache_shmcb_create, 
  socache_shmcb_init): 
  Default to use of runtimedir-relative paths if no
  explicit path is configured.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@724682 13f79535-47bb-0310-9956-ffa450edef68
2008-12-09 13:11:45 +00:00
Chris Darroch
719bf72489 remove const on socache module declarations to avoid segfault in
ap_setup_prelinked_modules() when modules linked in at compile time


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@648499 13f79535-47bb-0310-9956-ffa450edef68
2008-04-16 04:02:57 +00:00
Joe Orton
2e2731f3f9 Adjust socache init interface to take sizing hints, and namespace tag
for memcache:

* modules/cache/ap_socache.h (struct ap_socache_hints): New structure.
  Change init callback to take namespace string and hints structure pointer.

* modules/cache/mod_socache_dc.c (socache_dc_init): Adjust accordingly.

* modules/cache/mod_socache_dbm.c (struct ap_socache_instance_t): Rename
  timeout field to expiry_interval.
  (socache_dbm_init, socache_dbm_create): Take expiry interval from
  hints rather than hard-code to 30.
  (socache_dbm_expire): Update for timeout field rename.

* modules/cache/mod_socache_shmcb.c (socache_shmcb_init): Adjust for
  hints and namespace; adjust subcache index sizing heuristics to use
  passed-in hints.

* modules/cache/mod_socache_memcache.c (struct ap_socache_instance_t):
  Add tag, taglen fields.
  (socache_mc_init): Store the passed-in namespace in instance
  structure.
  (mc_session_id2sz): Adjust to not take context, use configured
  tag as string prefix, and not use a return value.
  (socache_mc_store, socache_mc_retrieve, socache_mc_remove):
  Adjust for mc_session_id2sz interface changes.

* modules/ssl/ssl_scache.c (ssl_scache_init): Pass namespace and hints
  to socache provider init function.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@645978 13f79535-47bb-0310-9956-ffa450edef68
2008-04-08 15:47:48 +00:00
Joe Orton
39bb462ea8 * modules/cache/ap_socache.h: Add ap_socache_instance_t object type.
Adjust the provider interface to use this instance type throughout.

* modules/cache/mod_socache_dbm.c,
  modules/cache/mod_socache_memcache.c,
  modules/cache/mod_socache_shmcb.c,
  modules/cache/mod_socache_dc.c: Adjust all implementations to 
  define the instance object in place of the "struct context", and
  to take this object directly in the provider interface.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@645924 13f79535-47bb-0310-9956-ffa450edef68
2008-04-08 13:49:52 +00:00
Joe Orton
3279936028 Session cache interface redesign, Part 8:
Abstract out the mod_ssl session caching interface into a separate set
of modules, mod_socache_*.

* modules/cache/ap_socache.h: New file.

* modules/cache/config.m4: Copy CHECK_DISTCACHE from ../ssl/config.m4; 
  add new socache modules.

* modules/cache/mod_socache_dbm.c: Copied from ../ssl/ssl_scache_dbm.c.
  s/ssl_scache_/socache_/; add module structure and register_hooks.

* modules/cache/mod_socache_shmcb.c: Copied from ../ssl/ssl_scache_shmcb.c.
  s/ssl_scache_/socache_/; add module structure and register_hooks.
  Add SHMCB_MAX_SIZE definition, replacing APR_SHM_MAXSIZE.

* modules/cache/mod_socache_memcache.c: Copied from
  ../ssl/ssl_scache_memcache.c.
  s/ssl_scache_/socache_/; add module structure and register_hooks.
  Enable for APR-Util 1.3.x at compile-time, omitting configure-time
  checks.

* modules/cache/mod_socache_dc.c: Copied from ../ssl/ssl_scache_dc.c.
  s/ssl_scache_/socache_/; add module structure and register_hooks.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@645844 13f79535-47bb-0310-9956-ffa450edef68
2008-04-08 10:47:04 +00:00