Hi!
I have to transfer a couple of maps to a laptop without access to the geoserver.
Therefore i would like copy the arcgisserver cache of a MapService and read the date using TileCache.
(Using the url of the geoserver instead of the local file path works fine.)
Doc: The TileCache is persisted as either a tile cache folder or a tile package (*.TPK) file on the device's file system.
QString tiledBaseMapLayer = QLatin1String(".....arcgisServerCache/Guez_Topo_32632_guez_topo_32632/Guez Topographic");
Esri::ArcGISRuntime::TileCache *tpkCache = new Esri::ArcGISRuntime::TileCache(tiledBaseMapLayer, this);
Esri::ArcGISRuntime::ArcGISTiledLayer *tiledLayer = new Esri::ArcGISRuntime::ArcGISTiledLayer(tpkCache, this);
tiledLayer->load();
Unfortunately i get
loadError: Esri::ArcGISRuntime::Error: code=14, domain=0, extendedErrorType=-1, message='File not found', additionalMessage=''
The directory looks like this:
ctc@CTCAP15:~/arcgisServerCache/Guez_Topo_32632_guez_topo_32632>
./Guez Topographic
./Guez Topographic/conf.cdi
./Guez Topographic/conf.properties
./Guez Topographic/Conf.xml
./Guez Topographic/Status.gdb
./Guez Topographic/Status.gdb/a00000001.gdbindexes
./Guez Topographic/Status.gdb/a00000001.gdbtable
./Guez Topographic/Status.gdb/a00000001.gdbtablx
./Guez Topographic/Status.gdb/a00000001.TablesByName.atx...
../Guez Topographic/_alllayers
./Guez Topographic/_alllayers/L00
./Guez Topographic/_alllayers/L00/R0080C0100.bundle
./Guez Topographic/_alllayers/L01
./Guez Topographic/_alllayers/L01/R0180C0280.bundle
./Guez Topographic/_alllayers/L02
Is that a possible way? (copy directory and consume using TileCache and ArcGISTiledLayer?
On-Demand approaches are already considered....
Thx in advance!!!
Norbert
Hi Norbert-
This should work. I tested out the attached tile cache with the below code and it rendered ok for me
// tile cache creation
TileCache* tc = new TileCache("/Users/<username>/ArcGIS/Runtime/Data/tpk/USA_Cached/UnitedStates", this);
ArcGISTiledLayer* tileLayer = new ArcGISTiledLayer(tc, this);
// Create a map using the tile cache
m_map = new Map(new Basemap(tileLayer, this), this);
Hi Luke!
Thanks for your quick answer!
In the meantime recognized:
Maybe our cache of ArcGIS Server 10.5.0 does not match the requirements of V100.3?
I will compare the directory structure.
I will check your attachment tomorow and let you know.
Thanks a lot!
Norbert
Hi Luke!
I tried your map using linux and get the identical error message.
But then i ask my colleague: The same code works fine under windows.
Fortunately we have to use that code under windows and not linux...
From my point of view it´s a linux specific bug 😞
Thanks a lot
Norbert
Hi Norbert,
You're right, when I try this on Linux it strangely does not work. I will log a bug for this.
Thanks,
Lucas
Hi!
I like to add Case number and BugId:
BUG-000116279 : ArcGISTiledLayer created from TileCache fails to load in linux environment
Case #02166830 - Nutzung von ArcGIS Server Compact Caches in ArcGIS Ru
Thanks Norbert!
Norbert - we have fixed the issue and it will be available in the 100.5 release, which will be released around March of 2019.
Hi Luke!
Here Release notes for 100.4.0—ArcGIS Runtime SDK for Qt | ArcGIS for Developers i could read that the BUG-000116279 should be solved.
Unfortunately i could not confim 😞
From my point of view the issue is still valid. (Checked with 100.4.0 and the attached cache)
Additionally i have problems to load a tpk.
May just a part of the bug was fixed?
Greeting from Germany 🙂
Greetings, Norbert! Looks like it is a doc bug - we fixed it for our 100.5 branch but it slipped into the 100.4 release notes. I apologize for the confusion. 100.5 should be out in a few weeks and should contain the fix.