#include "squid.h" #include "Module.h" #if defined(HAVE_FS_UFS) || defined(HAVE_FS_AUFS) || defined(HAVE_FS_DISKD) #include "fs/ufs/StoreFSufs.h" #include "fs/ufs/ufscommon.h" #endif #ifdef HAVE_FS_COSS #include "fs/coss/StoreFScoss.h" #endif #ifdef HAVE_FS_UFS static StoreFSufs *UfsInstance; #endif #ifdef HAVE_FS_AUFS static StoreFSufs *AufsInstance; #endif #ifdef HAVE_FS_DISKD static StoreFSufs *DiskdInstance; #endif /* TODO: Modify coss code to: * (a) remove the StoreFScoss::GetInstance method, * (b) declare the StoreFScoss::stats as static and * (c) merge the StoreFScoss::stat() method with the static * StoreFScoss::Stats() */ #ifdef HAVE_FS_COSS StoreFScoss &CossInstance = StoreFScoss::GetInstance(); #endif void Fs::Init() { #ifdef HAVE_FS_UFS UfsInstance = new StoreFSufs("Blocking", "ufs"); #endif #ifdef HAVE_FS_AUFS AufsInstance = new StoreFSufs("DiskThreads", "aufs");; #endif #ifdef HAVE_FS_DISKD DiskdInstance = new StoreFSufs("DiskDaemon", "diskd");; #endif } void Fs::Clean() { #ifdef HAVE_FS_UFS delete UfsInstance; #endif #ifdef HAVE_FS_AUFS delete AufsInstance; #endif #ifdef HAVE_FS_DISKD delete DiskdInstance; #endif }