Fix formating
This commit is contained in:
parent
c4b90f52c0
commit
4610fd9ff1
@ -46,8 +46,8 @@ class DataWatchdogImpl<AlgorithmT, datafacade::ContiguousInternalMemoryDataFacad
|
|||||||
auto region_id = shared_register.Find(dataset_name + "/data");
|
auto region_id = shared_register.Find(dataset_name + "/data");
|
||||||
if (region_id == storage::SharedRegionRegister::INVALID_REGION_ID)
|
if (region_id == storage::SharedRegionRegister::INVALID_REGION_ID)
|
||||||
{
|
{
|
||||||
throw util::exception(
|
throw util::exception("Could not find shared memory region for \"" + dataset_name +
|
||||||
"Could not find shared memory region for \"" + dataset_name +"/data\". Did you run osrm-datastore?");
|
"/data\". Did you run osrm-datastore?");
|
||||||
}
|
}
|
||||||
shared_region = &shared_register.GetRegion(region_id);
|
shared_region = &shared_register.GetRegion(region_id);
|
||||||
region = *shared_region;
|
region = *shared_region;
|
||||||
@ -94,8 +94,8 @@ class DataWatchdogImpl<AlgorithmT, datafacade::ContiguousInternalMemoryDataFacad
|
|||||||
facade_factory =
|
facade_factory =
|
||||||
DataFacadeFactory<datafacade::ContiguousInternalMemoryDataFacade, AlgorithmT>(
|
DataFacadeFactory<datafacade::ContiguousInternalMemoryDataFacade, AlgorithmT>(
|
||||||
std::make_shared<datafacade::SharedMemoryAllocator>(region.shm_key));
|
std::make_shared<datafacade::SharedMemoryAllocator>(region.shm_key));
|
||||||
util::Log() << "updated facade to region " << (int) region.shm_key << " with timestamp "
|
util::Log() << "updated facade to region " << (int)region.shm_key
|
||||||
<< region.timestamp;
|
<< " with timestamp " << region.timestamp;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -59,8 +59,8 @@ template <typename Algorithm> class Engine final : public EngineInterface
|
|||||||
{
|
{
|
||||||
if (config.use_shared_memory)
|
if (config.use_shared_memory)
|
||||||
{
|
{
|
||||||
util::Log(logDEBUG) << "Using shared memory with name \"" << config.dataset_name << "\" with algorithm "
|
util::Log(logDEBUG) << "Using shared memory with name \"" << config.dataset_name
|
||||||
<< routing_algorithms::name<Algorithm>();
|
<< "\" with algorithm " << routing_algorithms::name<Algorithm>();
|
||||||
facade_provider = std::make_unique<WatchingProvider<Algorithm>>(config.dataset_name);
|
facade_provider = std::make_unique<WatchingProvider<Algorithm>>(config.dataset_name);
|
||||||
}
|
}
|
||||||
else if (!config.memory_file.empty())
|
else if (!config.memory_file.empty())
|
||||||
|
@ -142,7 +142,8 @@ inline engine_config_ptr argumentsToEngineConfig(const Nan::FunctionCallbackInfo
|
|||||||
{
|
{
|
||||||
if (dataset_name->IsString())
|
if (dataset_name->IsString())
|
||||||
{
|
{
|
||||||
engine_config->dataset_name = *v8::String::Utf8Value(Nan::To<v8::String>(dataset_name).ToLocalChecked());
|
engine_config->dataset_name =
|
||||||
|
*v8::String::Utf8Value(Nan::To<v8::String>(dataset_name).ToLocalChecked());
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -221,8 +221,7 @@ struct SharedRegionRegister
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
template<typename OutIter>
|
template <typename OutIter> void List(OutIter out) const
|
||||||
void List(OutIter out) const
|
|
||||||
{
|
{
|
||||||
for (const auto ®ion : regions)
|
for (const auto ®ion : regions)
|
||||||
{
|
{
|
||||||
|
@ -37,8 +37,7 @@ void listRegions()
|
|||||||
{
|
{
|
||||||
auto id = shared_register.Find(name);
|
auto id = shared_register.Find(name);
|
||||||
auto region = shared_register.GetRegion(id);
|
auto region = shared_register.GetRegion(id);
|
||||||
osrm::util::Log() << name << "\t"
|
osrm::util::Log() << name << "\t" << (int)region.shm_key << "\t" << region.timestamp;
|
||||||
<< (int) region.shm_key << "\t" << region.timestamp;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -98,7 +97,9 @@ bool generateDataStoreOptions(const int argc,
|
|||||||
"Name of the dataset to load into memory. This allows having multiple datasets in memory "
|
"Name of the dataset to load into memory. This allows having multiple datasets in memory "
|
||||||
"at the same time.") //
|
"at the same time.") //
|
||||||
("list",
|
("list",
|
||||||
boost::program_options::value<bool>(&list_datasets)->default_value(false)->implicit_value(true),
|
boost::program_options::value<bool>(&list_datasets)
|
||||||
|
->default_value(false)
|
||||||
|
->implicit_value(true),
|
||||||
"Name of the dataset to load into memory. This allows having multiple datasets in memory "
|
"Name of the dataset to load into memory. This allows having multiple datasets in memory "
|
||||||
"at the same time.");
|
"at the same time.");
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user