]> git.ipfire.org Git - thirdparty/squid.git/commit
Replaced ACLStrategised, enabling other ACL improvements (#1392)
authorAlex Rousskov <rousskov@measurement-factory.com>
Tue, 8 Aug 2023 13:36:09 +0000 (13:36 +0000)
committerSquid Anubis <squid-anubis@squid-cache.org>
Tue, 8 Aug 2023 13:46:06 +0000 (13:46 +0000)
commit8319d478be54a358aa11d7a134aababc81eb9285
treeabaa2a56ac8add5a2e352d303623706cb2336aea
parente7959b56a56634766df84324ef8383540ae36118
Replaced ACLStrategised, enabling other ACL improvements (#1392)

The ACLStrategised class stands in the way of several ACL bug fixes and
improvements because its design forces us to place ACL-like match()
methods inside non-ACL classes, creating two parallel matching
hierarchies: one rooted in the ACL class and one rooted in the Strategy
template. The two APIs have similar methods, but Strategy-based objects
lie outside the ACL hierarchy and cannot be treated as ACL objects.

ACLStrategised pairs an ACL-like matching algorithm (a Strategy-derived
class) with an ACLData-derived class. The need to combine the two is
genuine, but the same combination is best supported without creating a
parallel hierarchy of Strategy classes. The new ACL-derived
ParameterizedNode base class accomplishes that, addressing the old
ACLStrategised design XXX.

Strategy-derived classes were not pooled at all! With these changes, all
formerly ACLStrategised classes get individual memory pools, typically
one per acltype, with proper acltype-based naming in mgr:mem reports. No
other functionality changes intended.
73 files changed:
src/AclRegs.cc
src/acl/AdaptationService.cc
src/acl/AdaptationService.h
src/acl/AnnotateClient.cc
src/acl/AnnotateClient.h
src/acl/AnnotateTransaction.cc
src/acl/AnnotateTransaction.h
src/acl/Asn.cc
src/acl/AtStep.cc
src/acl/AtStep.h
src/acl/Certificate.cc
src/acl/Certificate.h
src/acl/DestinationAsn.h
src/acl/DestinationDomain.cc
src/acl/DestinationDomain.h
src/acl/Gadgets.cc
src/acl/HasComponent.cc
src/acl/HasComponent.h
src/acl/HierCode.cc
src/acl/HierCode.h
src/acl/HttpRepHeader.cc
src/acl/HttpRepHeader.h
src/acl/HttpReqHeader.cc
src/acl/HttpReqHeader.h
src/acl/LocalPort.cc
src/acl/LocalPort.h
src/acl/Makefile.am
src/acl/Method.cc
src/acl/Method.h
src/acl/MyPortName.cc
src/acl/MyPortName.h
src/acl/Note.cc
src/acl/Note.h
src/acl/ParameterizedNode.h [new file with mode: 0644]
src/acl/PeerName.cc
src/acl/PeerName.h
src/acl/Protocol.cc
src/acl/Protocol.h
src/acl/ReplyHeaderStrategy.h
src/acl/ReplyMimeType.h
src/acl/RequestHeaderStrategy.h
src/acl/RequestMimeType.h
src/acl/ServerCertificate.cc
src/acl/ServerCertificate.h
src/acl/ServerName.cc
src/acl/ServerName.h
src/acl/SourceAsn.h
src/acl/SourceDomain.cc
src/acl/SourceDomain.h
src/acl/SquidError.cc
src/acl/SquidError.h
src/acl/SslError.cc
src/acl/SslError.h
src/acl/Strategised.cc [deleted file]
src/acl/Strategised.h [deleted file]
src/acl/Strategy.h [deleted file]
src/acl/Tag.cc
src/acl/Tag.h
src/acl/Time.cc
src/acl/Time.h
src/acl/Url.cc
src/acl/Url.h
src/acl/UrlLogin.cc
src/acl/UrlLogin.h
src/acl/UrlPath.cc
src/acl/UrlPath.h
src/acl/UrlPort.cc
src/acl/UrlPort.h
src/mem/Allocator.h
src/mem/AllocatorProxy.cc
src/mem/AllocatorProxy.h
src/snmp_core.cc
src/snmp_core.h