Hi,
FYI: I will commit this tomorrow if there are still no objections.
Thanks,
Alex.
On Fri, 2008-04-04 at 23:53 -0600, Alex Rousskov wrote:
> Hello,
>
> I am done with the first part of eCAP work and would like to commit
> it to Squid3 trunk. The first part includes (a) initial support for
> loadable modules and (b) removing ICAP from main Squid sources, replaced
> with the adaptation API that does not depend on a specific adaptation
> mechanism.
>
> The patch does not contain significant changes to main Squid sources.
> Generic adaptation API should minimize significant core changes going
> forward. Details are below. For a low-level change log, see the eCAP bzr
> branch at https://code.launchpad.net/~rousskov/squid/ecap
>
> Configuration and features:
>
> Added adaptation_service_set squid.conf option, deprecating
> icap_class. The new option has more accurate documentation and does
> not depend on the adaptation protocol so one can group eCAP and ICAP
> services.
>
> Added adaptation_service_set squid.conf option, deprecating
> icap_access. The new option has more accurate documentation and does
> not depend on the adaptation protocol so one can mix-and-match eCAP
> and ICAP ACL rules.
>
> Added loadable_modules squid.conf option to specify what shared
> libraries to load dynamically. The support is based on libtool's ltdl
> convenience library and is enabled by default. It can be disabled
> using --disable-loadable-modules. Loadable modules are needed for
> eCAP, but loadable_modules code deals with generic module
> manipulation, independent from eCAP support. Squid does not yet
> communicate with the loaded modules. TODO: support cachemgr
> reporting and reconfiguration of modules.
>
>
> Internals:
>
> Squid core no longer knows about ICAP: General message adaptation code
> has been moved from src/ICAP to src/adaptation/. The only connection
> between main Squid code and ICAP is squid.conf parser and a few
> enabling lines in main.cc. USE_ADAPTATION is enabled if ICAP_CLIENT or
> USE_ECAP is enabled. TODO: Make adaptation comments, debug, and error
> messages in main Squid code ICAP-neutral. This has not been done yet
> to reduce VCS conflicts.
>
> The src/ICAP/ directory now has its own Makefile (so does the new
> src/adaptation). TODO: Should ICAP and eCAP directories be moved
> inside adaptation/?
>
> The eCAP directory and the --enable-ecap option have been added, but
> they should not be used yet.
>
> Added an adaptation service group API to support groups of services.
> Current code supports service sets and single-service groups. Sets
> provide a way to group interchangeable services together so that one
> (the "best" available) service is applied to the message. A
> single-service group is an internal feature to allow user to mix
> service and group names in squid.conf ACLs. TODO: support service
> chains (as a service group) and perhaps group of groups?
>
> Implemented delayed creation of adaptation services. We used to create
> ICAPServiceRep objects when parsing the configuration file.
> Create-as-you-parse is imperfect for several reasons, especially if
> the services are dynamically loaded as is the case with eCAP. We now
> remember the service configuration and then create the actual service
> object _after_ the configuration has been parsed and loadable modules,
> if any, have been loaded.
>
> The bootstrap.sh script has been updated to generate ltdl library
> using libtoolize and move it to lib/libLtdl (except for the standard
> copyright file). With libtool version 2, the move will be supported by
> libtoolize itself. The lib/libLtdl directory and libtool.m4 file are
> not in VCS.
>
> Thank you,
>
> Alex.
> bb:approve