OmniSciDB
a5dc49c757
|
Namespaces | |
anonymous_namespace{Catalog.cpp} | |
anonymous_namespace{SysCatalog.cpp} | |
Classes | |
struct | TableEpochInfo |
struct | TableNotFoundException |
class | Catalog |
class for a per-database catalog. also includes metadata for the current database and the current user. More... | |
struct | CustomExpression |
class | read_lock |
class | sqlite_lock |
class | write_lock |
class | SessionInfo |
class | SessionsStore |
struct | UserMetadata |
struct | UserAlterations |
struct | DBMetadata |
struct | DBSummary |
class | CommonFileOperations |
class | SysCatalog |
Enumerations | |
enum | DataSourceType { DataSourceType::TABLE = 0 } |
Functions | |
dsqliteMutex_ (std::make_unique< heavyai::DistributedSharedMutex >(std::filesystem::path(basePath_)/shared::kLockfilesDirectoryName/shared::kCatalogDirectoryName/(currentDB_.dbName+".sqlite.lockfile"))) | |
sqliteMutex_ () | |
sharedMutex_ () | |
thread_holding_sqlite_lock () | |
thread_holding_write_lock () | |
bool | contains_spaces (std::string_view str) |
returns true if the string contains one or more spaces More... | |
bool | contains_sql_reserved_chars (std::string_view str, std::string_view chars="`~!@#$%^&*()-=+[{]}\\|;:'\",<.>/?") |
returns true if the string contains one or more OmniSci SQL reserved characters More... | |
bool | is_reserved_sql_keyword (std::string_view str) |
returns true if the string equals an OmniSci SQL reserved keyword More... | |
std::ostream & | operator<< (std::ostream &os, const SessionInfo &session_info) |
static bool | parseUserMetadataFromSQLite (const std::unique_ptr< SqliteConnector > &conn, UserMetadata &user, int row) |
const TableDescriptor * | get_metadata_for_table (const ::shared::TableKey &table_key, bool populate_fragmenter) |
const ColumnDescriptor * | get_metadata_for_column (const ::shared::ColumnKey &column_key) |
Variables | |
const int | DEFAULT_INITIAL_VERSION = 1 |
const int | MAPD_TEMP_TABLE_START_ID |
const int | MAPD_TEMP_DICT_START_ID |
static constexpr const char * | USERS_SYS_TABLE_NAME {"users"} |
static constexpr const char * | TABLES_SYS_TABLE_NAME {"tables"} |
static constexpr const char * | DASHBOARDS_SYS_TABLE_NAME {"dashboards"} |
static constexpr const char * | DATABASES_SYS_TABLE_NAME {"databases"} |
static constexpr const char * | PERMISSIONS_SYS_TABLE_NAME {"permissions"} |
static constexpr const char * | ROLES_SYS_TABLE_NAME {"roles"} |
static constexpr const char * | ROLE_ASSIGNMENTS_SYS_TABLE_NAME {"role_assignments"} |
static constexpr const char * | MEMORY_SUMMARY_SYS_TABLE_NAME {"memory_summary"} |
static constexpr const char * | MEMORY_DETAILS_SYS_TABLE_NAME {"memory_details"} |
static constexpr const char * | STORAGE_DETAILS_SYS_TABLE_NAME {"storage_details"} |
static constexpr const char * | EXECUTOR_RESOURCE_POOL_SUMMARY_SYS_TABLE_NAME |
static constexpr const char * | ML_MODEL_METADATA_SYS_TABLE_NAME {"ml_models"} |
static constexpr const char * | SERVER_LOGS_SYS_TABLE_NAME {"server_logs"} |
static constexpr const char * | REQUEST_LOGS_SYS_TABLE_NAME {"request_logs"} |
static constexpr const char * | WS_SERVER_LOGS_SYS_TABLE_NAME {"web_server_logs"} |
static constexpr const char * | WS_SERVER_ACCESS_LOGS_SYS_TABLE_NAME |
static const std::array < std::string, 4 > | kAggregatorOnlySystemTables |
const size_t | CALCITE_SESSION_ID_LENGTH = 64 |
const size_t | SESSION_ID_LENGTH = 32 |
bool | g_log_user_id {false} |
using Catalog_Namespace::cat_read_lock = typedef read_lock<Catalog> |
Definition at line 124 of file Catalog.cpp.
using Catalog_Namespace::cat_sqlite_lock = typedef sqlite_lock<Catalog> |
Definition at line 126 of file Catalog.cpp.
using Catalog_Namespace::cat_write_lock = typedef write_lock<Catalog> |
Definition at line 125 of file Catalog.cpp.
using Catalog_Namespace::ColumnDescriptorMap = typedef std::map<ColumnKey, ColumnDescriptor*> |
using Catalog_Namespace::ColumnDescriptorMapById = typedef std::map<ColumnIdKey, ColumnDescriptor*> |
using Catalog_Namespace::ColumnIdKey = typedef std::tuple<int, int> |
using Catalog_Namespace::ColumnKey = typedef std::tuple<int, std::string> |
using Catalog_Namespace::CustomExpressionMapById = typedef std::map<int, std::unique_ptr<CustomExpression>> |
using Catalog_Namespace::DashboardDescriptorMap = typedef std::map<std::string, std::shared_ptr<DashboardDescriptor>> |
using Catalog_Namespace::DBSummaryList = typedef std::list<DBSummary> |
Definition at line 145 of file SysCatalog.h.
using Catalog_Namespace::DeletedColumnPerTableMap = typedef std::unordered_map<const TableDescriptor*, const ColumnDescriptor*> |
using Catalog_Namespace::DictDescriptorMapById = typedef std::map<DictRef, std::unique_ptr<DictDescriptor>> |
using Catalog_Namespace::DisconnectCallback = typedef std::function<void(SessionInfoPtr& session)> |
Definition at line 29 of file SessionsStore.h.
using Catalog_Namespace::ForeignServerMap = typedef std::map<std::string, std::shared_ptr<foreign_storage::ForeignServer>> |
using Catalog_Namespace::ForeignServerMapById = typedef std::map<int, std::shared_ptr<foreign_storage::ForeignServer>> |
using Catalog_Namespace::LinkDescriptorMap = typedef std::map<std::string, LinkDescriptor*> |
using Catalog_Namespace::LinkDescriptorMapById = typedef std::map<int, LinkDescriptor*> |
using Catalog_Namespace::LogicalToPhysicalTableMapById = typedef std::map<int32_t, std::vector<int32_t>> |
using Catalog_Namespace::SessionInfoPtr = typedef std::shared_ptr<SessionInfo> |
Definition at line 27 of file SessionsStore.h.
typedef read_lock< SysCatalog > Catalog_Namespace::sys_read_lock |
Definition at line 123 of file Catalog.cpp.
using Catalog_Namespace::sys_sqlite_lock = typedef sqlite_lock<SysCatalog> |
Definition at line 154 of file SysCatalog.cpp.
using Catalog_Namespace::sys_write_lock = typedef write_lock<SysCatalog> |
Definition at line 153 of file SysCatalog.cpp.
using Catalog_Namespace::TableDescriptorMap = typedef std::map<std::string, TableDescriptor*> |
using Catalog_Namespace::TableDescriptorMapById = typedef std::map<int, TableDescriptor*> |
using Catalog_Namespace::TableDictColumnsMap = typedef std::map<int32_t, std::set<const ColumnDescriptor*>> |
|
strong |
|
inline |
returns true if the string contains one or more spaces
Definition at line 5558 of file Catalog.cpp.
Referenced by Catalog_Namespace::Catalog::quoteIfRequired().
|
inline |
returns true if the string contains one or more OmniSci SQL reserved characters
Definition at line 5565 of file Catalog.cpp.
Referenced by Catalog_Namespace::Catalog::quoteIfRequired().
Catalog_Namespace::dsqliteMutex_ | ( | std::make_unique< heavyai::DistributedSharedMutex > | std::filesystem::path(basePath_)/shared::kLockfilesDirectoryName/shared::kCatalogDirectoryName/(currentDB_.dbName+".sqlite.lockfile") | ) |
const ColumnDescriptor * Catalog_Namespace::get_metadata_for_column | ( | const ::shared::ColumnKey & | column_key | ) |
Definition at line 3234 of file SysCatalog.cpp.
References CHECK, Catalog_Namespace::SysCatalog::getCatalog(), and Catalog_Namespace::SysCatalog::instance().
Referenced by CodeGenerator::codegenBoundingBoxIntersect(), RangeJoinHashTable::codegenKey(), BoundingBoxIntersectJoinHashTable::codegenKey(), BoundingBoxIntersectJoinHashTable::codegenManyKey(), Executor::computeColRangesCache(), anonymous_namespace{Execute.cpp}::get_col_byte_width(), get_column_descriptor(), and RangeJoinHashTable::getInstance().
const TableDescriptor * Catalog_Namespace::get_metadata_for_table | ( | const ::shared::TableKey & | table_key, |
bool | populate_fragmenter | ||
) |
Definition at line 3227 of file SysCatalog.cpp.
References CHECK, Catalog_Namespace::SysCatalog::getCatalog(), and Catalog_Namespace::SysCatalog::instance().
Referenced by QueryFragmentDescriptor::buildFragmentPerKernelMapForUnion(), HashJoin::checkHashJoinReplicationConstraint(), anonymous_namespace{RelAlgExecutor.cpp}::do_table_reordering(), RelAlgExecutor::executeWorkUnit(), get_shard_count(), get_table_cardinality(), anonymous_namespace{Execute.cpp}::get_table_name(), getSyntheticInputTableInfo(), and GroupByAndAggregate::shard_count_for_top_groups().
|
inline |
returns true if the string equals an OmniSci SQL reserved keyword
Definition at line 5572 of file Catalog.cpp.
References reserved_keywords, and to_upper().
Referenced by Catalog_Namespace::Catalog::quoteIfRequired().
std::ostream & Catalog_Namespace::operator<< | ( | std::ostream & | os, |
const SessionInfo & | session_info | ||
) |
Definition at line 57 of file SessionInfo.cpp.
References Catalog_Namespace::SessionInfo::get_public_session_id().
|
static |
Definition at line 1667 of file SysCatalog.cpp.
References Catalog_Namespace::UserMetadata::can_login, Catalog_Namespace::UserMetadata::defaultDbId, g_log_user_id, Catalog_Namespace::UserMetadata::isSuper, LOG, Catalog_Namespace::UserMetadata::passwd_hash, Catalog_Namespace::UserMetadata::userId, Catalog_Namespace::UserMetadata::userLoggable(), Catalog_Namespace::UserMetadata::userName, and logger::WARNING.
Referenced by Catalog_Namespace::anonymous_namespace{SysCatalog.cpp}::get_users(), Catalog_Namespace::SysCatalog::getMetadataForUser(), and Catalog_Namespace::SysCatalog::getMetadataForUserById().
Catalog_Namespace::sharedMutex_ | ( | ) |
Catalog_Namespace::sqliteMutex_ | ( | ) |
Catalog_Namespace::thread_holding_sqlite_lock | ( | ) |
Catalog_Namespace::thread_holding_write_lock | ( | ) |
Definition at line 208 of file Catalog.cpp.
References CHECK, g_enable_fsi, g_enable_s3_fsi, g_enable_system_tables, g_serialize_temp_tables, and Catalog_Namespace::anonymous_namespace{Catalog.cpp}::table_json_filepath().
const size_t Catalog_Namespace::CALCITE_SESSION_ID_LENGTH = 64 |
Definition at line 126 of file SessionInfo.h.
Referenced by DBHandler::createInMemoryCalciteSession(), DBHandler::get_session_copy(), and DBHandler::get_session_ptr().
|
static |
|
static |
const int Catalog_Namespace::DEFAULT_INITIAL_VERSION = 1 |
Definition at line 113 of file Catalog.cpp.
Referenced by Catalog_Namespace::Catalog::updateDeletedColumnIndicator(), Catalog_Namespace::Catalog::updateDictionaryNames(), and Catalog_Namespace::Catalog::updatePageSize().
|
static |
Definition at line 122 of file Catalog.h.
Referenced by Catalog_Namespace::Catalog::initializeExecutorResourcePoolSummarySystemTable(), foreign_storage::InternalExecutorStatsDataWrapper::initializeObjectsForTable(), and foreign_storage::InternalExecutorStatsDataWrapper::populateChunkBuffersForTable().
bool Catalog_Namespace::g_log_user_id {false} |
Definition at line 156 of file SysCatalog.cpp.
Referenced by Catalog_Namespace::SysCatalog::alterUser(), Catalog_Namespace::SysCatalog::checkPrivileges(), Catalog_Namespace::SysCatalog::createUser(), Catalog_Namespace::SysCatalog::dropUser(), CommandLineOptions::fillOptions(), Catalog_Namespace::SysCatalog::getMetadataWithDefaultDB(), parseUserMetadataFromSQLite(), Catalog_Namespace::SysCatalog::renameUser(), Catalog_Namespace::UserMetadata::userLoggable(), and CommandLineOptions::validate().
|
static |
Definition at line 131 of file Catalog.h.
Referenced by foreign_storage::refresh_foreign_table().
const int Catalog_Namespace::MAPD_TEMP_DICT_START_ID |
Definition at line 116 of file Catalog.cpp.
const int Catalog_Namespace::MAPD_TEMP_TABLE_START_ID |
Definition at line 114 of file Catalog.cpp.
|
static |
|
static |
|
static |
|
static |
|
static |
Definition at line 126 of file Catalog.h.
Referenced by RefreshForeignTablesCommand::execute(), Catalog_Namespace::Catalog::initializeRequestLogsSystemTables(), and Catalog_Namespace::Catalog::initializeSystemTables().
|
static |
|
static |
|
static |
Definition at line 125 of file Catalog.h.
Referenced by RefreshForeignTablesCommand::execute(), Catalog_Namespace::Catalog::initializeServerLogsSystemTables(), and Catalog_Namespace::Catalog::initializeSystemTables().
const size_t Catalog_Namespace::SESSION_ID_LENGTH = 32 |
Definition at line 127 of file SessionInfo.h.
Referenced by CachedSessionStore::add().
|
static |
|
static |
|
static |
|
static |
Definition at line 128 of file Catalog.h.
Referenced by RefreshForeignTablesCommand::execute(), Catalog_Namespace::Catalog::initializeSystemTables(), and Catalog_Namespace::Catalog::initializeWebServerAccessLogsSystemTables().
|
static |
Definition at line 127 of file Catalog.h.
Referenced by RefreshForeignTablesCommand::execute(), Catalog_Namespace::Catalog::initializeSystemTables(), and Catalog_Namespace::Catalog::initializeWebServerLogsSystemTables().