NCBI C++ ToolKit
Classes | Macros | Functions | Variables
reader_cache.cpp File Reference
#include <ncbi_pch.hpp>
#include <objtools/data_loaders/genbank/cache/reader_cache.hpp>
#include <objtools/data_loaders/genbank/cache/reader_cache_entry.hpp>
#include <objtools/data_loaders/genbank/cache/reader_cache_params.h>
#include <objtools/data_loaders/genbank/readers.hpp>
#include <objtools/data_loaders/genbank/impl/dispatcher.hpp>
#include <objtools/data_loaders/genbank/impl/processors.hpp>
#include <objtools/data_loaders/genbank/impl/request_result.hpp>
#include <objtools/data_loaders/genbank/gbloader.hpp>
#include <corelib/ncbitime.hpp>
#include <corelib/rwstream.hpp>
#include <corelib/plugin_manager_store.hpp>
#include <util/cache/icache.hpp>
#include <connect/ncbi_conn_stream.hpp>
#include <objmgr/objmgr_exception.hpp>
#include <objmgr/impl/tse_split_info.hpp>
#include <objmgr/impl/tse_chunk_info.hpp>
#include <objmgr/annot_selector.hpp>
#include <serial/objistrasnb.hpp>
#include <serial/serial.hpp>
#include <objects/seqloc/Seq_id.hpp>
+ Include dependency graph for reader_cache.cpp:

Go to the source code of this file.

Go to the SVN repository for this file.

Classes

struct  SCacheEntryAccessCount
 
struct  SPluginParams
 
struct  SPluginParams::SDefaultValue
 
class  CCacheReaderCF
 

Macros

#define FIX_BAD_ID2S_REPLY_DATA   1
 

Functions

 NCBI_PARAM_DECL (int, GENBANK, CACHE_DEBUG)
 
 NCBI_PARAM_DEF_EX (int, GENBANK, CACHE_DEBUG, 0, eParam_NoThread, GENBANK_CACHE_DEBUG)
 
static bool IsDisabledCache (const SCacheInfo::TParams *params)
 
static SCacheInfo::TParamsGetDriverParams (SCacheInfo::TParams *params)
 
static SCacheInfo::TParamsGetCacheParamsCopy (const SCacheInfo::TParams *src_params, const char *section_name)
 
SCacheInfo::TParamsGetCacheParams (const SCacheInfo::TParams *src_params, SCacheInfo::EReaderOrWriter reader_or_writer, SCacheInfo::EIdOrBlob id_or_blob)
 
void NCBI_EntryPoint_CacheReader (CPluginManager< CReader >::TDriverInfoList &info_list, CPluginManager< CReader >::EEntryPointRequest method)
 
void NCBI_EntryPoint_xreader_cache (CPluginManager< CReader >::TDriverInfoList &info_list, CPluginManager< CReader >::EEntryPointRequest method)
 
void GenBankReaders_Register_Cache (void)
 

Variables

static const size_t kHashLimit = 100
 
static SCacheEntryAccessCount s_CacheEntryAccessCounts [CCacheReader::eCacheEntry_Count]
 
static const SPluginParams::SDefaultValue s_DefaultParams []
 
static const SPluginParams::SDefaultValue s_DefaultIdParams []
 
static const SPluginParams::SDefaultValue s_DefaultBlobParams []
 
static const SPluginParams::SDefaultValue s_DefaultReaderParams []
 
static const SPluginParams::SDefaultValue s_DefaultWriterParams []
 

Macro Definition Documentation

◆ FIX_BAD_ID2S_REPLY_DATA

#define FIX_BAD_ID2S_REPLY_DATA   1

Definition at line 56 of file reader_cache.cpp.

Function Documentation

◆ GenBankReaders_Register_Cache()

void GenBankReaders_Register_Cache ( void  )

◆ GetCacheParams()

SCacheInfo::TParams* GetCacheParams ( const SCacheInfo::TParams src_params,
SCacheInfo::EReaderOrWriter  reader_or_writer,
SCacheInfo::EIdOrBlob  id_or_blob 
)

◆ GetCacheParamsCopy()

static SCacheInfo::TParams* GetCacheParamsCopy ( const SCacheInfo::TParams src_params,
const char *  section_name 
)
static

Definition at line 1548 of file reader_cache.cpp.

References SPluginParams::FindSubNode(), and IsDisabledCache().

Referenced by GetCacheParams().

◆ GetDriverParams()

static SCacheInfo::TParams* GetDriverParams ( SCacheInfo::TParams params)
static

◆ IsDisabledCache()

static bool IsDisabledCache ( const SCacheInfo::TParams params)
static

◆ NCBI_EntryPoint_CacheReader()

void NCBI_EntryPoint_CacheReader ( CPluginManager< CReader >::TDriverInfoList &  info_list,
CPluginManager< CReader >::EEntryPointRequest  method 
)

◆ NCBI_EntryPoint_xreader_cache()

void NCBI_EntryPoint_xreader_cache ( CPluginManager< CReader >::TDriverInfoList &  info_list,
CPluginManager< CReader >::EEntryPointRequest  method 
)

Definition at line 1788 of file reader_cache.cpp.

References NCBI_EntryPoint_CacheReader().

◆ NCBI_PARAM_DECL()

NCBI_PARAM_DECL ( int  ,
GENBANK  ,
CACHE_DEBUG   
)

◆ NCBI_PARAM_DEF_EX()

NCBI_PARAM_DEF_EX ( int  ,
GENBANK  ,
CACHE_DEBUG  ,
,
eParam_NoThread  ,
GENBANK_CACHE_DEBUG   
)

Variable Documentation

◆ kHashLimit

const size_t kHashLimit = 100
static

Definition at line 105 of file reader_cache.cpp.

Referenced by SCacheInfo::GetBlob_idsSubkey().

◆ s_CacheEntryAccessCounts

SCacheEntryAccessCount s_CacheEntryAccessCounts[CCacheReader::eCacheEntry_Count]
static

Definition at line 1165 of file reader_cache.cpp.

Referenced by CCacheReader::GoingToLoad(), and CCacheReader::NoNeedToSave().

◆ s_DefaultBlobParams

const SPluginParams::SDefaultValue s_DefaultBlobParams[]
static
Initial value:
= {
{ "name", "blobs" },
{ "timeout", "432000" },
{ "timestamp", "onread expire_not_used" },
{ 0, 0 }
}

Definition at line 1598 of file reader_cache.cpp.

Referenced by GetCacheParams().

◆ s_DefaultIdParams

const SPluginParams::SDefaultValue s_DefaultIdParams[]
static
Initial value:
= {
{ "name", "ids" },
{ "timeout", "172800" },
{ "timestamp", "subkey check_expiration" },
{ "page_size", "small" },
{ 0, 0 }
}

Definition at line 1588 of file reader_cache.cpp.

Referenced by GetCacheParams().

◆ s_DefaultParams

const SPluginParams::SDefaultValue s_DefaultParams[]
static
Initial value:
= {
{ "keep_versions", "all" },
{ "write_sync", "no" },
{ "path", ".genbank_cache" },
{ "mem_size", "20M" },
{ "log_file_max", "20M" },
{ "purge_batch_sleep", "500" },
{ "purge_thread_delay", "3600" },
{ "purge_clean_log", "16" },
{ "connection_max_retries", "0" },
{ "connection_timeout", "0.3" },
{ "communication_timeout", "0.1" },
{ "max_connection_pool_size", "30" },
{ "max_find_lbname_retries", "2" },
{ "retry_delay", "0.001" },
{ 0, 0 }
}

Definition at line 1567 of file reader_cache.cpp.

Referenced by GetCacheParams().

◆ s_DefaultReaderParams

const SPluginParams::SDefaultValue s_DefaultReaderParams[]
static
Initial value:
= {
{ "purge_thread", "yes" },
{ 0, 0 }
}

Definition at line 1606 of file reader_cache.cpp.

Referenced by GetCacheParams().

◆ s_DefaultWriterParams

const SPluginParams::SDefaultValue s_DefaultWriterParams[]
static
Initial value:
= {
{ "purge_thread", "no" },
{ 0, 0 }
}

Definition at line 1612 of file reader_cache.cpp.

Referenced by GetCacheParams().

Modified on Fri Sep 20 14:58:12 2024 by modify_doxy.py rev. 669887