libfoedus-core
FOEDUS Core Library
|
Database engine object that holds all resources and provides APIs. More...
Database engine object that holds all resources and provides APIs.
Detailed description of this class.
Definition at line 109 of file engine.hpp.
#include <engine.hpp>
Public Member Functions | |
Engine (const EngineOptions &options) | |
Instantiates a master engine object which is NOT initialized yet. More... | |
Engine (EngineType type, soc::Upid master_upid, Eid master_eid, soc::SocId soc_id) | |
Instantiates a child engine object which is NOT initialized yet. More... | |
~Engine () | |
Do NOT rely on this destructor to release resources. More... | |
Engine ()=delete | |
Engine (const Engine &)=delete | |
Engine & | operator= (const Engine &)=delete |
std::string | describe_short () const |
ErrorStack | initialize () override |
Starts up the database engine. More... | |
bool | is_initialized () const override |
Returns whether the engine is currently running. More... | |
ErrorStack | uninitialize () override |
Terminates the database engine. More... | |
const EngineOptions & | get_options () const |
cache::CacheManager * | get_cache_manager () const |
See Snapshot Cache Manager. More... | |
debugging::DebuggingSupports * | get_debug () const |
See Debug-Support functionalities. More... | |
log::LogManager * | get_log_manager () const |
See Log Manager. More... | |
memory::EngineMemory * | get_memory_manager () const |
See Memory Manager. More... | |
proc::ProcManager * | get_proc_manager () const |
See System and User Procedures. More... | |
thread::ThreadPool * | get_thread_pool () const |
See Thread and Thread-Group. More... | |
savepoint::SavepointManager * | get_savepoint_manager () const |
See Savepoint Manager. More... | |
snapshot::SnapshotManager * | get_snapshot_manager () const |
See Snapshot Manager. More... | |
soc::SocManager * | get_soc_manager () const |
See SOC and IPC. More... | |
storage::StorageManager * | get_storage_manager () const |
See Storage Manager. More... | |
xct::XctManager * | get_xct_manager () const |
See Transaction Manager. More... | |
restart::RestartManager * | get_restart_manager () const |
See Restart Manager. More... | |
EngineType | get_type () const |
Returns the type of this engine object. More... | |
bool | is_master () const |
Returns if this engine object is a master instance. More... | |
bool | is_emulated_child () const |
Returns if this engine object is a child instance running just as a thread. More... | |
bool | is_forked_child () const |
Returns if this engine object is a child instance launched by fork. More... | |
bool | is_local_spawned_child () const |
Returns if this engine object is a child instance launched by spawn. More... | |
bool | is_remote_spawned_child () const |
Returns if this engine object is a child instance remotely launched by spawn. More... | |
soc::SocId | get_soc_id () const |
If this is a child instance, returns its SOC ID (NUMA node). More... | |
soc::SocId | get_soc_count () const |
Shorthand for get_options().thread_.group_count_. More... | |
soc::Upid | get_master_upid () const |
Returns Universal (or Unique) ID of the master process. More... | |
Eid | get_master_eid () const |
Returns Engine ID of the master engine. More... | |
Epoch | get_earliest_epoch () const |
Returns the Earliest-Epoch, the minimum epoch that is valid within this engine. More... | |
Epoch | get_current_global_epoch () const |
Returns the current global epoch, the epoch a newly started transaction will be in. More... | |
Epoch | get_current_grace_epoch () const |
Returns the current grace-period epoch (global epoch - 1), the epoch some transaction might be still in (though rare). More... | |
Epoch | get_durable_global_epoch () const |
Returns the durable epoch of the entire engine. More... | |
EngineOptions * | get_nonconst_options () |
Returns an updatable reference to options. More... | |
![]() | |
virtual | ~Initializable () |
|
explicit |
Instantiates a master engine object which is NOT initialized yet.
[in] | options | Configuration of the engine |
To start the engine, call initialize() afterwards. This constructor dose nothing but instantiation.
Definition at line 26 of file engine.cpp.
foedus::Engine::Engine | ( | EngineType | type, |
soc::Upid | master_upid, | ||
Eid | master_eid, | ||
soc::SocId | soc_id | ||
) |
Instantiates a child engine object which is NOT initialized yet.
[in] | type | Launch type of the child engine object |
[in] | master_upid | Universal (or Unique) ID of the master process. |
[in] | master_eid | Engine ID of the master engine. |
[in] | soc_id | SOC-ID (or NUMA-node) of the child engine. |
Use this constructor only when you modify your main() function to capture kChildLocalSpawned launch. Otherwise, this constructor is used only internally.
Definition at line 29 of file engine.cpp.
foedus::Engine::~Engine | ( | ) |
Do NOT rely on this destructor to release resources.
Call uninitialize() instead.
If this destructor is called before the call of uninitialize(), there was something wrong. So, this destructor complains about it in stderr if that's the case. Remember, destructor is not the best place to do complex things. Always use uninitialize() for better handling of unexpected errors.
Definition at line 33 of file engine.cpp.
|
delete |
|
delete |
std::string foedus::Engine::describe_short | ( | ) | const |
Definition at line 38 of file engine.cpp.
References foedus::EnginePimpl::describe_short().
Referenced by foedus::proc::ProcManagerPimpl::initialize_once(), and foedus::proc::ProcManagerPimpl::uninitialize_once().
cache::CacheManager * foedus::Engine::get_cache_manager | ( | ) | const |
Definition at line 47 of file engine.cpp.
References foedus::EnginePimpl::cache_manager_.
Referenced by foedus::xct::XctManagerPimpl::uninitialize_once().
Epoch foedus::Engine::get_current_global_epoch | ( | ) | const |
Returns the current global epoch, the epoch a newly started transaction will be in.
Equivalent to get_xct_manager()->get_current_global_epoch(). Implemented in engine_pimpl.cpp as this needs to know about XctManager.
Definition at line 282 of file engine_pimpl.cpp.
References foedus::xct::XctManager::get_current_global_epoch(), and foedus::EnginePimpl::xct_manager_.
Referenced by foedus::storage::sequential::SequentialStoragePimpl::truncate().
Epoch foedus::Engine::get_current_grace_epoch | ( | ) | const |
Returns the current grace-period epoch (global epoch - 1), the epoch some transaction might be still in (though rare).
Equivalent to get_xct_manager()->get_current_grace_epoch(). Implemented in engine_pimpl.cpp as this needs to know about XctManager.
Definition at line 285 of file engine_pimpl.cpp.
References foedus::xct::XctManager::get_current_grace_epoch(), and foedus::EnginePimpl::xct_manager_.
debugging::DebuggingSupports * foedus::Engine::get_debug | ( | ) | const |
See Debug-Support functionalities.
Definition at line 48 of file engine.cpp.
References foedus::EnginePimpl::debug_.
Referenced by foedus::memory::EngineMemory::initialize_once(), and foedus::memory::EngineMemory::uninitialize_once().
Epoch foedus::Engine::get_durable_global_epoch | ( | ) | const |
Returns the durable epoch of the entire engine.
Equivalent to get_log_manager()->get_durable_global_epoch(). Implemented in engine_pimpl.cpp as this needs to know about LogManager.
Definition at line 288 of file engine_pimpl.cpp.
References foedus::log::LogManager::get_durable_global_epoch(), and foedus::EnginePimpl::log_manager_.
Epoch foedus::Engine::get_earliest_epoch | ( | ) | const |
Returns the Earliest-Epoch, the minimum epoch that is valid within this engine.
Such an epoch is initially 1, then very occasionally (eg per month) bumped up to some number after the entire system makes sure that there are no existing epoch values before the epoch (eg after system-wide compaction). We use this value whenever we want some value that is "old-enough" but also safe regarding wrap-around of Epoch values (see Epoch for how wrap-around works).
Equivalent to get_savepoint_manager()->get_earliest_epoch(). Implemented in engine_pimpl.cpp as this needs to know about SavepointManager.
Definition at line 279 of file engine_pimpl.cpp.
References foedus::savepoint::SavepointManager::get_earliest_epoch(), and foedus::EnginePimpl::savepoint_manager_.
Referenced by foedus::storage::sequential::SequentialStoragePimpl::create(), foedus::storage::sequential::SequentialStoragePimpl::load(), and foedus::savepoint::SavepointManagerPimpl::savepoint_main().
log::LogManager * foedus::Engine::get_log_manager | ( | ) | const |
See Log Manager.
Definition at line 49 of file engine.cpp.
References foedus::EnginePimpl::log_manager_.
Referenced by foedus::log::EpochMarkerLogType::apply_engine(), foedus::storage::StorageManagerPimpl::create_storage_and_log(), foedus::storage::StorageManagerPimpl::drop_storage(), foedus::xct::XctManagerPimpl::handle_epoch_chime(), foedus::snapshot::LogMapper::handle_process(), foedus::snapshot::SnapshotManagerPimpl::handle_snapshot(), foedus::snapshot::SnapshotManagerPimpl::handle_snapshot_triggered(), foedus::storage::StorageManagerPimpl::initialize_once(), foedus::snapshot::SnapshotManagerPimpl::initialize_once(), foedus::xct::XctManagerPimpl::precommit_xct_verify_readonly(), foedus::restart::RestartManagerPimpl::recover(), foedus::savepoint::SavepointManagerPimpl::savepoint_main(), foedus::snapshot::SnapshotManagerPimpl::trigger_snapshot_immediate(), foedus::storage::sequential::SequentialStoragePimpl::truncate(), foedus::storage::StorageManagerPimpl::uninitialize_once(), foedus::snapshot::SnapshotManagerPimpl::uninitialize_once(), foedus::xct::XctManagerPimpl::wait_for_commit(), and foedus::log::ThreadLogBuffer::wait_for_space().
Eid foedus::Engine::get_master_eid | ( | ) | const |
Returns Engine ID of the master engine.
Definition at line 76 of file engine.cpp.
References foedus::EnginePimpl::master_eid_.
Referenced by foedus::soc::SocManagerPimpl::emulated_child_main(), foedus::soc::SocManagerPimpl::forked_child_main(), foedus::soc::SocManagerPimpl::initialize_child(), foedus::soc::SocManagerPimpl::initialize_master(), and foedus::soc::SocManagerPimpl::launch_spawned_children().
soc::Upid foedus::Engine::get_master_upid | ( | ) | const |
Returns Universal (or Unique) ID of the master process.
Definition at line 75 of file engine.cpp.
References foedus::EnginePimpl::master_upid_.
Referenced by foedus::soc::SocManagerPimpl::emulated_child_main(), foedus::soc::SocManagerPimpl::forked_child_main(), foedus::soc::SocManagerPimpl::initialize_child(), foedus::soc::SocManagerPimpl::initialize_master(), and foedus::soc::SocManagerPimpl::launch_spawned_children().
memory::EngineMemory * foedus::Engine::get_memory_manager | ( | ) | const |
See Memory Manager.
Definition at line 50 of file engine.cpp.
References foedus::EnginePimpl::memory_manager_.
Referenced by foedus::storage::hash::HashStoragePimpl::create(), foedus::storage::hash::HashStoragePimpl::debugout_single_thread(), foedus::storage::hash::HashStoragePimpl::debugout_single_thread_data(), foedus::storage::masstree::MasstreeStoragePimpl::debugout_single_thread_follow(), foedus::storage::hash::HashStoragePimpl::debugout_single_thread_intermediate(), foedus::storage::array::ArrayPartitioner::design_partition(), foedus::storage::masstree::MasstreePartitioner::design_partition(), foedus::storage::masstree::design_partition_first_parallel(), foedus::storage::hash::HashPartitioner::design_partition_task(), foedus::storage::array::ArrayStorage::drop(), foedus::storage::masstree::MasstreeStoragePimpl::drop(), foedus::storage::hash::HashStoragePimpl::drop(), foedus::storage::sequential::SequentialStoragePimpl::drop(), foedus::storage::Composer::DropVolatilesArguments::drop(), foedus::snapshot::SnapshotManagerPimpl::drop_volatile_pages_parallel(), foedus::storage::sequential::SequentialComposer::drop_volatiles(), foedus::thread::ThreadPimpl::flush_retired_volatile_page(), foedus::storage::sequential::SequentialStoragePimpl::for_every_page(), foedus::storage::sequential::SequentialStoragePimpl::get_head_pointer(), foedus::storage::sequential::SequentialStoragePimpl::get_tail_pointer(), foedus::memory::RoundRobinPageGrabBatch::grab(), foedus::memory::DivvyupPageGrabBatch::grab(), foedus::storage::hash::HashStoragePimpl::hcc_reset_all_temperature_stat_data(), foedus::storage::masstree::MasstreeStoragePimpl::hcc_reset_all_temperature_stat_follow(), foedus::storage::array::ArrayStoragePimpl::hcc_reset_all_temperature_stat_intermediate(), foedus::storage::hash::HashStoragePimpl::hcc_reset_all_temperature_stat_intermediate(), foedus::xct::Xct::initialize(), foedus::storage::sequential::SequentialStoragePimpl::initialize_head_tail_pages(), foedus::thread::ThreadGroup::initialize_once(), foedus::thread::ThreadPoolPimpl::initialize_once(), foedus::cache::CacheManagerPimpl::initialize_once(), foedus::thread::ThreadPimpl::initialize_once(), foedus::log::Logger::initialize_once(), foedus::log::ThreadLogBuffer::initialize_once(), foedus::storage::array::ArrayStoragePimpl::load(), foedus::storage::masstree::MasstreeStoragePimpl::load(), foedus::storage::hash::HashStoragePimpl::load(), foedus::storage::array::ArrayStoragePimpl::load_empty(), foedus::storage::masstree::MasstreeStoragePimpl::load_empty(), foedus::storage::masstree::MasstreeStoragePimpl::peek_volatile_page_boundaries(), foedus::storage::StorageManagerPimpl::reinitialize_for_recovered_snapshot(), foedus::memory::RoundRobinPageGrabBatch::release_all(), foedus::memory::DivvyupPageGrabBatch::release_all(), foedus::memory::PageReleaseBatch::release_chunk(), foedus::storage::hash::HashIntermediatePage::release_pages_recursive_parallel(), foedus::storage::masstree::MasstreeIntermediatePage::release_pages_recursive_parallel(), foedus::storage::masstree::release_parallel(), foedus::storage::hash::release_parallel(), foedus::storage::masstree::MasstreeBorderPage::track_moved_record(), foedus::storage::masstree::MasstreeBorderPage::track_moved_record_next_layer(), foedus::storage::hash::HashStoragePimpl::track_moved_record_search(), foedus::thread::ThreadPoolPimpl::uninitialize_once(), foedus::thread::ThreadPimpl::uninitialize_once(), foedus::storage::hash::HashStoragePimpl::verify_single_thread(), foedus::storage::hash::HashStoragePimpl::verify_single_thread_data(), and foedus::storage::hash::HashStoragePimpl::verify_single_thread_intermediate().
EngineOptions * foedus::Engine::get_nonconst_options | ( | ) |
Returns an updatable reference to options.
This must be used only by SocManager during initialization. Users must not call this method.
Definition at line 40 of file engine.cpp.
References ASSERT_ND, is_master(), and foedus::EnginePimpl::options_.
Referenced by foedus::soc::SocManagerPimpl::initialize_child().
const EngineOptions & foedus::Engine::get_options | ( | ) | const |
Definition at line 39 of file engine.cpp.
References foedus::EnginePimpl::options_.
Referenced by foedus::memory::NumaNodeMemory::allocate_numa_memory_general(), foedus::snapshot::LogReducerRef::append_log_chunk(), foedus::snapshot::calculate_logger_id(), foedus::storage::hash::HashStoragePimpl::create(), foedus::storage::array::ArrayPartitioner::design_partition(), foedus::storage::sequential::SequentialStoragePimpl::drop(), foedus::storage::sequential::SequentialComposer::drop_volatiles(), foedus::memory::EngineMemory::dump_free_memory_stat(), foedus::proc::ProcManagerPimpl::emulated_register(), foedus::thread::ThreadPimpl::find_or_read_a_snapshot_page(), foedus::thread::ThreadPimpl::find_or_read_snapshot_pages_batch(), foedus::storage::sequential::SequentialStoragePimpl::for_every_page(), foedus::snapshot::LogReducerRef::get_buffer_size(), foedus::storage::sequential::SequentialStoragePimpl::get_head_pointer(), foedus::storage::StorageManagerPimpl::get_max_storages(), foedus::snapshot::SnapshotManagerPimpl::get_option(), foedus::cache::SnapshotFileSet::get_or_open_file(), foedus::soc::SocManager::get_shared_user_memory_size(), foedus::storage::sequential::SequentialStoragePimpl::get_tail_pointer(), foedus::xct::XctManagerPimpl::handle_epoch_chime(), foedus::snapshot::LogMapper::handle_process(), foedus::thread::ThreadPimpl::handle_tasks(), foedus::thread::ThreadPoolPimpl::impersonate(), foedus::thread::ThreadPoolPimpl::impersonate_on_numa_node(), foedus::xct::Xct::initialize(), foedus::storage::sequential::SequentialStoragePimpl::initialize_head_tail_pages(), foedus::soc::SocManagerPimpl::initialize_master(), foedus::thread::ThreadGroup::initialize_once(), foedus::thread::ThreadPoolPimpl::initialize_once(), foedus::cache::CacheManagerPimpl::initialize_once(), foedus::log::MetaLogger::initialize_once(), foedus::memory::NumaNodeMemory::initialize_once(), foedus::memory::EngineMemory::initialize_once(), foedus::memory::NumaCoreMemory::initialize_once(), foedus::EnginePimpl::initialize_once(), foedus::snapshot::LogMapper::initialize_once(), foedus::proc::ProcManagerPimpl::initialize_once(), foedus::log::LogManagerPimpl::initialize_once(), foedus::savepoint::SavepointManagerPimpl::initialize_once(), foedus::thread::ThreadPimpl::initialize_once(), foedus::log::Logger::initialize_once(), foedus::snapshot::SnapshotManagerPimpl::initialize_once(), foedus::snapshot::LogReducer::initialize_once(), foedus::soc::SocManagerPimpl::launch_emulated_children(), foedus::soc::SocManagerPimpl::launch_forked_children(), foedus::soc::SocManagerPimpl::launch_spawned_children(), foedus::storage::PartitionerMetadata::locate_data(), foedus::snapshot::LogReducer::LogReducer(), foedus::memory::NumaNodeMemoryRef::NumaNodeMemoryRef(), foedus::snapshot::SnapshotWriter::open(), foedus::proc::ProcManagerPimpl::pre_register(), foedus::xct::XctManagerPimpl::precommit_xct_lock(), foedus::xct::XctManagerPimpl::precommit_xct_readwrite(), foedus::restart::RestartManagerPimpl::redo_meta_logs(), foedus::thread::ThreadPimpl::set_thread_schedule(), foedus::thread::ThreadGroupRef::ThreadGroupRef(), foedus::snapshot::SnapshotManagerPimpl::uninitialize_once(), foedus::savepoint::SavepointManagerPimpl::update_shared_savepoint(), foedus::soc::SocManagerPimpl::wait_for_child_attach(), foedus::soc::SocManagerPimpl::wait_for_child_terminate(), foedus::soc::SocManagerPimpl::wait_for_children_module(), and foedus::log::ThreadLogBuffer::wait_for_space().
proc::ProcManager * foedus::Engine::get_proc_manager | ( | ) | const |
See System and User Procedures.
Definition at line 51 of file engine.cpp.
References foedus::EnginePimpl::proc_manager_.
Referenced by foedus::soc::SocManagerPimpl::child_main_common(), foedus::soc::SocManagerPimpl::emulated_child_main(), foedus::soc::SocManagerPimpl::forked_child_main(), and foedus::thread::ThreadPimpl::handle_tasks().
restart::RestartManager* foedus::Engine::get_restart_manager | ( | ) | const |
See Restart Manager.
savepoint::SavepointManager * foedus::Engine::get_savepoint_manager | ( | ) | const |
See Savepoint Manager.
Definition at line 53 of file engine.cpp.
References foedus::EnginePimpl::savepoint_manager_.
Referenced by foedus::storage::array::array_volatile_page_init(), foedus::storage::array::ArrayComposer::construct_root(), foedus::xct::Xct::initialize(), foedus::log::MetaLogger::initialize_once(), foedus::log::LogManagerPimpl::initialize_once(), foedus::xct::XctManagerPimpl::initialize_once(), foedus::log::Logger::initialize_once(), foedus::snapshot::SnapshotManagerPimpl::initialize_once(), foedus::log::ThreadLogBuffer::initialize_once(), foedus::storage::StorageManagerPimpl::initialize_read_latest_snapshot(), foedus::storage::array::ArrayStoragePimpl::load_empty(), foedus::restart::RestartManagerPimpl::redo_meta_logs(), foedus::log::LogManagerPimpl::refresh_global_durable_epoch(), foedus::snapshot::SnapshotManagerPimpl::snapshot_savepoint(), and foedus::log::LogManagerPimpl::uninitialize_once().
snapshot::SnapshotManager * foedus::Engine::get_snapshot_manager | ( | ) | const |
See Snapshot Manager.
Definition at line 56 of file engine.cpp.
References foedus::EnginePimpl::snapshot_manager_.
Referenced by foedus::storage::StorageManagerPimpl::initialize_read_latest_snapshot(), foedus::restart::RestartManagerPimpl::recover(), and foedus::restart::RestartManagerPimpl::uninitialize_once().
soc::SocId foedus::Engine::get_soc_count | ( | ) | const |
Shorthand for get_options().thread_.group_count_.
Definition at line 74 of file engine.cpp.
References foedus::thread::ThreadOptions::group_count_, foedus::EnginePimpl::options_, and foedus::EngineOptions::thread_.
Referenced by foedus::storage::hash::HashComposer::construct_root(), foedus::storage::hash::HashPartitioner::design_partition(), foedus::storage::array::ArrayPartitioner::design_partition(), foedus::storage::masstree::MasstreePartitioner::design_partition(), foedus::snapshot::SnapshotManagerPimpl::drop_volatile_pages(), foedus::snapshot::SnapshotManagerPimpl::drop_volatile_pages_parallel(), foedus::xct::XctManagerPimpl::handle_epoch_chime_wait_grace_period(), foedus::snapshot::SnapshotManagerPimpl::initialize_once(), foedus::memory::NumaCoreMemory::uninitialize_once(), and foedus::thread::ThreadPimpl::uninitialize_once().
soc::SocId foedus::Engine::get_soc_id | ( | ) | const |
If this is a child instance, returns its SOC ID (NUMA node).
Otherwise always 0.
Definition at line 73 of file engine.cpp.
References foedus::EnginePimpl::soc_id_.
Referenced by foedus::snapshot::calculate_logger_id(), foedus::cache::CacheManagerPimpl::describe(), foedus::proc::ProcManagerPimpl::get_local_data(), foedus::proc::ProcManagerPimpl::get_proc(), foedus::snapshot::SnapshotManagerPimpl::handle_snapshot_child(), foedus::soc::SocManagerPimpl::initialize_child(), foedus::thread::ThreadPoolPimpl::initialize_once(), foedus::cache::CacheManagerPimpl::initialize_once(), foedus::memory::EngineMemory::initialize_once(), foedus::log::LogManagerPimpl::initialize_once(), foedus::snapshot::LogReducer::initialize_once(), foedus::soc::SocManagerPimpl::report_engine_fatal_error(), and foedus::memory::EngineMemory::uninitialize_once().
soc::SocManager * foedus::Engine::get_soc_manager | ( | ) | const |
See SOC and IPC.
Definition at line 59 of file engine.cpp.
References foedus::EnginePimpl::soc_manager_.
Referenced by foedus::soc::SocManagerPimpl::child_main_common(), foedus::snapshot::LogGleaner::execute(), foedus::snapshot::LogReducerRef::get_buffer(), foedus::snapshot::LogReducerRef::get_cur_snapshot(), foedus::storage::PartitionerMetadata::get_index0_metadata(), foedus::storage::PartitionerMetadata::get_metadata(), foedus::memory::EngineMemory::get_shared_user_memory(), foedus::memory::EngineMemory::get_shared_user_memory_size(), foedus::restart::RestartManagerPimpl::initialize_once(), foedus::log::MetaLogger::initialize_once(), foedus::memory::NumaNodeMemory::initialize_once(), foedus::storage::StorageManagerPimpl::initialize_once(), foedus::proc::ProcManagerPimpl::initialize_once(), foedus::log::LogManagerPimpl::initialize_once(), foedus::xct::XctManagerPimpl::initialize_once(), foedus::savepoint::SavepointManagerPimpl::initialize_once(), foedus::thread::ThreadPimpl::initialize_once(), foedus::snapshot::SnapshotManagerPimpl::initialize_once(), foedus::storage::PartitionerMetadata::locate_data(), foedus::snapshot::LogGleanerRef::LogGleanerRef(), foedus::snapshot::LogReducer::LogReducer(), foedus::snapshot::LogReducerRef::LogReducerRef(), foedus::memory::NumaNodeMemoryRef::NumaNodeMemoryRef(), foedus::savepoint::SavepointManagerPimpl::savepoint_main(), foedus::thread::ThreadRef::ThreadRef(), and foedus::snapshot::SnapshotManagerPimpl::uninitialize_once().
storage::StorageManager * foedus::Engine::get_storage_manager | ( | ) | const |
See Storage Manager.
Definition at line 60 of file engine.cpp.
References foedus::EnginePimpl::storage_manager_.
Referenced by foedus::storage::sequential::SequentialAppendLogType::apply_record(), foedus::storage::DropLogType::apply_storage(), foedus::storage::CreateLogType::apply_storage(), foedus::snapshot::SnapshotManagerPimpl::drop_volatile_pages_parallel(), foedus::storage::get_storage_control_block(), foedus::snapshot::SnapshotManagerPimpl::handle_snapshot_triggered(), foedus::xct::XctManagerPimpl::initialize_once(), foedus::storage::Partitioner::Partitioner(), foedus::xct::XctManagerPimpl::precommit_xct_apply(), foedus::xct::XctManagerPimpl::precommit_xct_lock_track_write(), foedus::xct::XctManagerPimpl::precommit_xct_verify_readonly(), foedus::xct::XctManagerPimpl::precommit_xct_verify_readwrite(), foedus::xct::XctManagerPimpl::precommit_xct_verify_track_read(), foedus::restart::RestartManagerPimpl::recover(), foedus::restart::RestartManagerPimpl::redo_meta_logs(), foedus::snapshot::SnapshotManagerPimpl::snapshot_metadata(), and foedus::xct::XctManagerPimpl::uninitialize_once().
thread::ThreadPool * foedus::Engine::get_thread_pool | ( | ) | const |
Definition at line 52 of file engine.cpp.
References foedus::EnginePimpl::thread_pool_.
Referenced by foedus::thread::ThreadPimpl::get_thread_ref(), foedus::xct::XctManagerPimpl::handle_epoch_chime_wait_grace_period(), foedus::storage::StorageManagerPimpl::initialize_once(), foedus::log::LogManagerPimpl::initialize_once(), foedus::log::Logger::initialize_once(), foedus::storage::StorageManagerPimpl::uninitialize_once(), and foedus::log::LogManagerPimpl::uninitialize_once().
EngineType foedus::Engine::get_type | ( | ) | const |
Returns the type of this engine object.
Definition at line 67 of file engine.cpp.
References foedus::EnginePimpl::type_.
xct::XctManager * foedus::Engine::get_xct_manager | ( | ) | const |
See Transaction Manager.
Definition at line 61 of file engine.cpp.
References foedus::EnginePimpl::xct_manager_.
Referenced by foedus::thread::ThreadPimpl::collect_retired_volatile_page(), foedus::log::MetaLogBuffer::commit(), foedus::snapshot::SnapshotManagerPimpl::drop_volatile_pages(), foedus::thread::ThreadPimpl::flush_retired_volatile_page(), foedus::cache::CacheManagerPimpl::handle_cleaner(), foedus::restart::RestartManagerPimpl::initialize_once(), foedus::xct::Xct::issue_next_id(), foedus::savepoint::SavepointManagerPimpl::savepoint_main(), foedus::storage::sequential::SequentialCursor::SequentialCursor(), and foedus::restart::RestartManagerPimpl::uninitialize_once().
|
overridevirtual |
Starts up the database engine.
This is the first method to call.
Implements foedus::Initializable.
Definition at line 64 of file engine.cpp.
References foedus::DefaultInitializable::initialize().
Referenced by foedus::soc::SocManagerPimpl::child_main_common().
bool foedus::Engine::is_emulated_child | ( | ) | const |
Returns if this engine object is a child instance running just as a thread.
Definition at line 69 of file engine.cpp.
References foedus::kChildEmulated, and foedus::EnginePimpl::type_.
Referenced by foedus::debugging::DebuggingSupports::initialize_once(), and foedus::debugging::DebuggingSupports::uninitialize_once().
bool foedus::Engine::is_forked_child | ( | ) | const |
Returns if this engine object is a child instance launched by fork.
Definition at line 70 of file engine.cpp.
References foedus::kChildForked, and foedus::EnginePimpl::type_.
|
overridevirtual |
Returns whether the engine is currently running.
Implements foedus::Initializable.
Definition at line 63 of file engine.cpp.
References foedus::DefaultInitializable::is_initialized().
Referenced by foedus::snapshot::SnapshotManagerPimpl::handle_snapshot().
bool foedus::Engine::is_local_spawned_child | ( | ) | const |
Returns if this engine object is a child instance launched by spawn.
Definition at line 71 of file engine.cpp.
References foedus::kChildLocalSpawned, and foedus::EnginePimpl::type_.
bool foedus::Engine::is_master | ( | ) | const |
Returns if this engine object is a master instance.
Definition at line 68 of file engine.cpp.
References foedus::kMaster, and foedus::EnginePimpl::type_.
Referenced by foedus::proc::ProcManagerPimpl::describe_registered_procs(), foedus::proc::ProcManagerPimpl::get_local_data(), get_nonconst_options(), foedus::xct::XctManagerPimpl::handle_epoch_chime(), foedus::xct::XctManagerPimpl::handle_epoch_chime_wait_grace_period(), foedus::snapshot::SnapshotManagerPimpl::handle_snapshot_triggered(), foedus::thread::ThreadPoolPimpl::initialize_once(), foedus::soc::SocManagerPimpl::initialize_once(), foedus::restart::RestartManagerPimpl::initialize_once(), foedus::cache::CacheManagerPimpl::initialize_once(), foedus::log::MetaLogger::initialize_once(), foedus::memory::EngineMemory::initialize_once(), foedus::storage::StorageManagerPimpl::initialize_once(), foedus::proc::ProcManagerPimpl::initialize_once(), foedus::log::LogManagerPimpl::initialize_once(), foedus::xct::XctManagerPimpl::initialize_once(), foedus::savepoint::SavepointManagerPimpl::initialize_once(), foedus::snapshot::SnapshotManagerPimpl::initialize_once(), foedus::storage::StorageManagerPimpl::initialize_read_latest_snapshot(), foedus::xct::XctManagerPimpl::is_stop_requested(), foedus::proc::ProcManagerPimpl::local_register(), foedus::proc::ProcManagerPimpl::pre_register(), foedus::soc::SocManagerPimpl::report_engine_fatal_error(), foedus::snapshot::SnapshotManagerPimpl::stop_snapshot_thread(), foedus::thread::ThreadPoolPimpl::uninitialize_once(), foedus::soc::SocManagerPimpl::uninitialize_once(), foedus::cache::CacheManagerPimpl::uninitialize_once(), foedus::restart::RestartManagerPimpl::uninitialize_once(), foedus::log::MetaLogger::uninitialize_once(), foedus::memory::EngineMemory::uninitialize_once(), foedus::storage::StorageManagerPimpl::uninitialize_once(), foedus::proc::ProcManagerPimpl::uninitialize_once(), foedus::log::LogManagerPimpl::uninitialize_once(), foedus::xct::XctManagerPimpl::uninitialize_once(), foedus::savepoint::SavepointManagerPimpl::uninitialize_once(), foedus::snapshot::SnapshotManagerPimpl::uninitialize_once(), and foedus::soc::SocManagerPimpl::wait_for_master_status().
bool foedus::Engine::is_remote_spawned_child | ( | ) | const |
Returns if this engine object is a child instance remotely launched by spawn.
Definition at line 72 of file engine.cpp.
References foedus::kChildRemoteSpawned, and foedus::EnginePimpl::type_.
|
overridevirtual |
Terminates the database engine.
This is the last method to call.
Implements foedus::Initializable.
Definition at line 65 of file engine.cpp.
References foedus::DefaultInitializable::uninitialize().
Referenced by foedus::soc::SocManagerPimpl::child_main_common().