OmniSciDB
a5dc49c757
|
Prevents simultaneous inserts into the same table. To allow concurrent Insert/Select queries, Insert queries only obtain a write lock on table data when checkpointing (flushing chunks to disk). Inserts/Data load will take an exclusive (write) lock to ensure only one insert proceeds on each table at a time. More...
#include <LockMgr.h>
Static Public Member Functions | |
static InsertDataLockMgr & | instance () |
Static Public Member Functions inherited from lockmgr::TableLockMgrImpl< T > | |
static T & | instance () |
static WriteLock | getWriteLockForTable (const Catalog_Namespace::Catalog &cat, const std::string &table_name) |
static WriteLock | getWriteLockForTable (const ChunkKey &table_key) |
static ReadLock | getReadLockForTable (Catalog_Namespace::Catalog &cat, const std::string &table_name) |
static ReadLock | getReadLockForTable (const ChunkKey &table_key) |
Static Protected Attributes | |
static constexpr std::string_view | kind = "insert" |
Friends | |
class | TableLockMgrImpl< InsertDataLockMgr > |
Additional Inherited Members | |
Public Member Functions inherited from lockmgr::TableLockMgrImpl< T > | |
virtual | ~TableLockMgrImpl ()=default |
virtual MutexTracker * | getTableMutex (const ChunkKey &table_key) |
std::set< ChunkKey > | getLockedTables () const |
Protected Member Functions inherited from lockmgr::TableLockMgrImpl< T > | |
TableLockMgrImpl () | |
virtual std::unique_ptr < heavyai::DistributedSharedMutex > | getClusterTableMutex (const ChunkKey &table_key) const |
Protected Attributes inherited from lockmgr::TableLockMgrImpl< T > | |
std::mutex | map_mutex_ |
std::map< ChunkKey, std::unique_ptr< MutexTracker > > | table_mutex_map_ |
Prevents simultaneous inserts into the same table. To allow concurrent Insert/Select queries, Insert queries only obtain a write lock on table data when checkpointing (flushing chunks to disk). Inserts/Data load will take an exclusive (write) lock to ensure only one insert proceeds on each table at a time.
|
inlinestatic |
|
friend |
|
inlinestaticprotected |
Definition at line 65 of file LockMgr.h.
Referenced by TableFunctionsFactory_linker.BaseGenerateFiles::_get_filename(), heavydb.serialized_result_set.ttypes.TTargetInfo::read(), and heavydb.serialized_result_set.ttypes.TTargetInfo::write().