Project-OSRM / osrm-backend

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

is osrm data files compatible between versions? #5379

Closed morruth closed 5 years ago

morruth commented 5 years ago

f.e if i have osrm-backend v 5.18 and want to ugrade on latest version .should i repeat osrm-extract/partition/customize with new binaries or enough just compile new version and run osrm-routed with existing data files?

wangyoucao577 commented 5 years ago

I think so. I met this issue before when startup osrm-routed.

[error] File is incompatible with this version of OSRM: /data/test_osm.osrm.cells prepared with OSRM 5.18.0 but this is v5.20.0 (at include/storage/tar.hpp:204)

danpat commented 5 years ago

Between 5.18.0 and 5.20.0 we added pre-calculated distance values to the data. In OSRM 5.21 we added a new flag to edges in the RTree to allow map-matching to ferries and service roads.

Both of these changes caused modifications to the datafile format. Unfortunately, we don't have an extensible format that can support backward-compatible changes, so both of these changes will break the 5.18 files being loaded by 5.21.

While we try to stick to SemVer for versioning, we made a call a while back to only cover the API surface area for SemVer versioning rules, not the datafiles.

You'll need to re-generate your files to upgrade to the latest version.