Project-OSRM / osrm-backend

Open Source Routing Machine - C++ backend
http://map.project-osrm.org
BSD 2-Clause "Simplified" License
6.29k stars 3.32k forks source link

osrm::storage::Storage shouldn't contain shared memory logic #3312

Closed danpat closed 1 month ago

danpat commented 7 years ago

osrm-datastore calls ::Storage::Run() in order to allocate shared memory, and load data from files into it.

Because of https://github.com/Project-OSRM/osrm-backend/pull/3165, the Storage class is now used by non-shared-memory consumers as well.

The shared-memory specific logic should be refactored into a new class, and Storage should only be about loading data from disk into a pre-allocated memory block.

TheMarex commented 7 years ago

This follows the same pattern as osrm-extract -> Extractor::Run, osrm-contract -> Contractor::Run, osrm-datastore -> Storage::Run. Storage should contain the application specific code for osrm-datastore.

If we re-use some of that functionality somewhere else it should be split into an own class/function.

github-actions[bot] commented 2 months ago

This issue seems to be stale. It will be closed in 30 days if no further activity occurs.