I created graph-data.osm.gh following the usual way. If I embed that graph in the app bundle it works perfectly.
Then I put that graph on my web site and I downloaded it from the app, storing it in the document folder but graphhopper is unable to load that graph.
I got loaded is false;
I went in debug inside graphopper and I see that it fails when it tries to load "properties" file in MMapDataAccess.m, in loadExisting function:
Application IDs are different!!!
This is why Graphhopper cannot find the file.
Why? the app is the same, but in graphhopper core the absolute path is different.
I created graph-data.osm.gh following the usual way. If I embed that graph in the app bundle it works perfectly. Then I put that graph on my web site and I downloaded it from the app, storing it in the document folder but graphhopper is unable to load that graph.
This is the document directory:
I check if the file "properties" exists:
this is the result:
exists /var/mobile/Containers/Data/Application/ADF41477-E25E-4173-B896-75AE8F491603/Documents/graph-data.osm-gh/properties, 1
the file "properties" exists!
Then I try to load the graph in graphhopper:
I got loaded is false; I went in debug inside graphopper and I see that it fails when it tries to load "properties" file in MMapDataAccess.m, in loadExisting function:
The log is:
2016-09-09 18:26:23.076 UcciNav[1539:118823] file /var/mobile/Containers/Data/Application/9204D3BE-5AFB-4908-B784-04CA959A2DCA/Documents/graph-data.osm-gh/properties exists 0, 0
"properties" file doesn't exists. Pay attention, the first log says:
exists /var/mobile/Containers/Data/Application/ADF41477-E25E-4173-B896-75AE8F491603/Documents/graph-data.osm-gh/properties, 1
the last one says:
2016-09-09 18:26:23.076 UcciNav[1539:118823] file /var/mobile/Containers/Data/Application/9204D3BE-5AFB-4908-B784-04CA959A2DCA/Documents/graph-data.osm-gh/properties exists 0, 0l
Application IDs are different!!! This is why Graphhopper cannot find the file. Why? the app is the same, but in graphhopper core the absolute path is different.
Any suggestion?