Re: [squid-users] I want to add an object

From: Henrik Nordstrom <hno@dont-contact.us>
Date: Fri, 06 Apr 2001 04:24:27 +0200

globals.c does not have anything to do with objects. It is global C
variables inside the Squid process.

To have a squid-internal-periodic object available you must generate it
via an time based event, much like how digest.c does it.

There is also a squid-internal-dynamic class of internal objects that
are generated when requested (currently only one such object:
squid-internal-dynamic/netdb). See internal.c:internalStart().

Note: squid-internal-periodic or squid-internal-static objects are
handler very differently from squid-internal-dynamic. Do not be confused
by the store_digest code in internalStart(), this code is only reached
before the digest has been created the first time.

Most times the cachemgr interface is more appropriate for adding stuff.
The squid-internal-xxx family of objects is for when browsers or cache
peers needs to retreive the object, not for statistics or diagnostics.

--
Henrik Nordstrom
Squid hacker
林英超 wrote:
> 
> Dear all
>   I can get my store_digest.c by the URL
> 
>      http://140.112.30.139:3128/squid-internal-periodic/store_digest
> 
>   And I am trying to add a global variable "store_digest2"
> 
>   in globals.c and globals.h , then I am trying to get store_digest2
> 
>        http://140.112.30.139:3128/squid-internal-periodic/store_digest2
> 
>   it tell me " Access Denied" , I don't know why ? Can anyone tell me ?
> 
>   Thanks in Advance.
> 
> ******************globals.c*******************
> CacheDigest *store_digest2  = NULL;
> 
> *******************globals.h*******************
> extern CacheDigest *store_digest2 ; /* NULL by_iclin */
Received on Thu Apr 05 2001 - 20:34:49 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:59:10 MST