Select to view content in your preferred language

OfflineMapTask - Some layer could not be taken offline. Illegal state

1674
4
09-05-2019 02:27 AM
NorbertThoden
Occasional Contributor III

Hi!

After a couple of time, i restarted playing with the OfflineMapTask 🙂

I started with the GenerateOfflineMap  (GitHub-ExamplesV100.6)

After setting networkproxy the example was not working, i had to set loginRequired to false.

Additionally, the option "Allow clients to export cache tiles" seems to be unset 😞

But then i switch to my own Enterprise (Portal and Server 10.5), create my very first webmap and add a single Url from the arcGIS Server (of Type MapServer) as basemap.

And finally, that works - great 🙂

But:

I add a second basemap to the webmap. Both can be displayed by the example - fine.

After some percent of downloading i get:

Some layer could not be taken offline. Illegal state

Both layers are basemaps ; both can be downloaded (Allow clients to export cache tiles -> yes)

I zoomed out as much as possible, so the upper basemap disappears (due to minScale/maxScale).

But the visiblityByScale shouldn´t be relevant, correct?

I started with an extent of only ~2km^2 and got a mmpk (60MB).

Finally that workflow should work with 20*30km. I expect and mmpk of a couple of GBs...

So, i am not very optimistic...

Any hints?

0 Kudos
4 Replies
LukeSmallwood
Esri Contributor

Hi Norbert - thanks for reporting the issue.

One thing that can help track down the problem is to write the Job out to JSON. This should include all of the sub-job messages which provides more details about what is going on. Esri Tiled services set a maximum number of tiles which can be exported - but it sounds as though both basemaps are for your own tiled services?

Luke

NorbertThoden
Occasional Contributor III

Hi!

After adding  generateJob->toJson(); is download again, got the Illegal State for both layer and toJson:

generateJob->toJson() "{\"generateOfflineMapJob\":{\"continueOnErrors\":true,\"createdContent\":true,\"createdPackageDirectory\":true,\"dataPath\":\"/tmp/GenerateOfflineMap - C++-Beclpw/offlinemap.mmpk/p13\",\"jobParameters\":{\"areaOfInterest\":{\"xmin\":960847.19020702457,\"ymin\":6974008.6958564036,\"xmax\":1018215.3919124544,\"ymax\":7010452.618752744,\"spatialReference\":{\"wkid\":102100,\"latestWkid\":3857}},\"attachmentSyncDirection\":\"bidirectional\",\"continueOnErrors\":true,\"destinationTableRowFilter\":\"relatedOnly\",\"includeBasemap\":true,\"isDefinitionExpressionFilterEnabled\":true,\"itemInfo\":{\"snippet\":\"Hemelingen32632WebMap\",\"tags\":[\"Hemelingen 32632 WebMap\"],\"thumbnail\":\"iVBORw0KGgoAAAANSUhEUgAAAMgAAACFCAYAAAAenrcsAAAABHNCSVQICAgIfAhkiAAAIABJREFUeJx0umeM5Il55vf7x/pXzlVd1dW5p+P05LAzuzsbZ8nd5YpckqIs0Qqnk3ASJMD2AWdLhxOwB8uXYAOSTgdDlE9nBci+I6UluVxSy81hcp7p6emcQ3XlXPXP/iDjjDPs58v76fn2/oDnxfMKf/JvvuNGoypB0cS0ZYamRqiWdbDarDx5wtkTEySmvQhum3v6MPU+jW4iTeqPfoDrjdKshghsb9GYX2RfrjD70ssMHJMR71xhSZogOp5FVj14fEGqu0uYVQOl+APMly5g50PQizIxOcju4mOykycozi+zUS4zMtZPCpeH3QMWK4ewcUA1M8+Z5Jf58vFvsVtc4+HqI4rKFg+3y4xJF/CM1Ols9EgnEgznZU49/1/zReRfMPpRnb9Kl9HbEl8

...

HxkisfMLHC41079pDvLae315+hVWrwAvqFn5Q+ge/7HmOttoWcG2am8NcPDtKMZdl3bdEObqK5vh4bs9POGE9T5v+EE0rh/gXa9uKpih3msAAAAAASUVORK5CYII=\",\"title\":\"Hemelingen32632WebMap\"},\"maxScale\":0,\"minScale\":0,\"returnLayerAttachmentOption\":\"allLayers\",\"returnSchemaOnlyForEditableLayers\":false},\"layerErrors\":[{\"error\":{\"code\":6,\"description\":\"Illegal state\"},\"url\":\"http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Bremen/Hemelingen_TIF_32632/MapServer\"},{\"error\":{\"code\":6,\"description\":\"Illegal state\"},\"url\":\"http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Norddeutschland/Norddeutschland_32632/MapServer\"}],\"onlineMap\":{\"baseMap\":{\"baseMapLayers\":[{\"id\":\"Norddeutschland_32632_2136\",\"layerType\":\"ArcGISTiledMapServiceLayer\",\"opacity\":1,\"showLegend\":true,\"title\":\"Norddeutschland_32632\",\"url\":\"http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Norddeutschland/Norddeutschland_32632/MapServer\",\"visibility\":true},{\"id\":\"Hemelingen_TIF_32632_3414\",\"layerType\":\"ArcGISTiledMapServiceLayer\",\"opacity\":1,\"title\":\"Hemelingen_TIF_32632\",\"url\":\"http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Bremen/Hemelingen_TIF_32632/MapServer\",\"visibility\":true}],\"title\":\"Hemelingen_TIF_32632\"},\"referenceScale\":0,\"spatialReference\":{\"wkid\":32632},\"version\":\"2.9\",\"authoringApp\":\"RuntimeSDK\",\"authoringAppVersion\":\"100.6.0.2513\"},\"packagePath\":\"/tmp/GenerateOfflineMap - C++-Beclpw/offlinemap.mmpk\",\"portalItem\":{\"access\":\"public\",\"avgRating\":0,\"commentsEnabled\":false,\"created\":1567516021319,\"culture\":\"en-us\",\"extent\":[[8.8430999999999997,53.037799999999997],[8.9330999999999996,53.074100000000001]],\"id\":\"dd8c598c434041b3ad096c424cb0464b\",\"modified\":1567673917230,\"numComments\":0,\"numRatings\":0,\"numViews\":43,\"owner\":\"portaladmin\",\"size\":721,\"snippet\":\"Hemelingen32632WebMap\",\"tags\":[\"Hemelingen 32632 WebMap\"],\"thumbnail\":\"thumbnail/ago_downloaded.png\",\"title\":\"Hemelingen32632WebMap\",\"type\":\"Web Map\",\"typeKeywords\":[\"ArcGIS Online\",\"Explorer Web Map\",\"Map\",\"Online Map\",\"Web Map\"]},\"portalUrl\":\"http://excgeo20.sl.defence-elec.de/arcgis\",\"subJobs\":[{\"exportTileCacheParameters\":{\"areaOfInterest\":{\"xmin\":475237.87850777223,\"ymin\":5866861.4344202308,\"xmax\":509861.82226250961,\"ymax\":5888816.9199876273,\"spatialReference\":{\"wkid\":32632}},\"levelIds\":[0,1,2,3,4,5,6,7,8,9]},\"job\":{\"exportTileCacheJob\":{\"downloadFilePath\":\"/tmp/GenerateOfflineMap - C++-Beclpw/offlinemap.mmpk/p13/3a592b52-085d-4f78-87fa-ddbf1f808668.tpk\",\"mapServiceUrl\":\"http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Norddeutschland/Norddeutschland_32632/MapServer\",\"parameters\":{\"areaOfInterest\":{\"xmin\":475237.87850777223,\"ymin\":5866861.4344202308,\"xmax\":509861.82226250961,\"ymax\":5888816.9199876273,\"spatialReference\":{\"wkid\":32632}},\"levelIds\":[0,1,2,3,4,5,6,7,8,9]}},\"jobType\":\"exportTileCacheJob\",\"messages\":[{\"isServerMessage\":false,\"message\":\"Job started.\",\"severity\":\"info\",\"timestamp\":1567768885875},{\"isServerMessage\":false,\"message\":\"Creating server job.\",\"severity\":\"info\",\"timestamp\":1567768885875},{\"isServerMessage\":false,\"message\":\"Sending request create server job exportTiles.\",\"severity\":\"info\",\"timestamp\":1567768885875},{\"isServerMessage\":false,\"message\":\"Received response for create server job exportTiles.\",\"severity\":\"info\",\"timestamp\":1567768888411},{\"isServerMessage\":false,\"message\":\"Delaying job status for 1 second.\",\"severity\":\"info\",\"timestamp\":1567768888411},{\"isServerMessage\":false,\"message\":\"Sending request server job status.\",\"severity\":\"info\",\"timestamp\":1567768889411},{\"isServerMessage\":false,\"message\":\"Received response for server job status.\",\"severity\":\"info\",\"timestamp\":1567768889469},{\"isServerMessage\":false,\"message\":\"Delaying job status for 5 seconds.\",\"severity\":\"info\",\"timestamp\":1567768889469},{\"isServerMessage\":false,\"message\":\"Sending request server job status.\",\"severity\":\"info\",\"timestamp\":1567768894469},{\"isServerMessage\":false,\"message\":\"Received response for server job status.\",\"severity\":\"info\",\"timestamp\":1567768894526},{\"isServerMessage\":false,\"message\":\"Delaying job status for 5 seconds.\",\"severity\":\"info\",\"timestamp\":1567768894526},{\"isServerMessage\":false,\"message\":\"Sending request server job status.\",\"severity\":\"info\",\"timestamp\":1567768899527},{\"isServerMessage\":false,\"message\":\"Received response for server job status.\",\"severity\":\"info\",\"timestamp\":1567768899575},{\"isServerMessage\":false,\"message\":\"Delaying job status for 5 seconds.\",\"severity\":\"info\",\"timestamp\":1567768899576},{\"isServerMessage\":false,\"message\":\"Sending request server job status.\",\"severity\":\"info\",\"timestamp\":1567768904577},{\"isServerMessage\":false,\"message\":\"Received response for server job status.\",\"severity\":\"info\",\"timestamp\":1567768904644},{\"isServerMessage\":true,\"message\":\"Submitted.\",\"severity\":\"info\",\"timestamp\":1567768904644},{\"isServerMessage\":true,\"message\":\"Executing...\",\"severity\":\"info\",\"timestamp\":1567768904644},{\"isServerMessage\":false,\"message\":\"Delaying job status for 5 seconds.\",\"severity\":\"info\",\"timestamp\":1567768904644},{\"isServerMessage\":false,\"message\":\"Sending request server job status.\",\"severity\":\"info\",\"timestamp\":1567768909644},{\"isServerMessage\":false,\"message\":\"Received response for server job status.\",\"severity\":\"info\",\"timestamp\":1567768909701},{\"isServerMessage\":true,\"message\":\"Executing (Export Cache): ExportCache Norddeutschland/Norddeutschland_32632:MapServer # COMPACT TRUE 1 TRUE \\\"475237,878507772 5866861,43442023 509861,82226251 5888816,91998763\\\" 0,1,2,3,4,5,6,7,8,9 FALSE \\\"Feature Set\\\" # {\\\"requestMode\\\":\\\"REST\\\",\\\"exportBy\\\":\\\"LevelID\\\",\\\"recompress\\\":false,\\\"recompressQuality\\\":75}\",\"severity\":\"info\",\"timestamp\":1567768909701},{\"isServerMessage\":true,\"message\":\"Start Time: Fri Sep 06 13:21:45 2019\",\"severity\":\"info\",\"timestamp\":1567768909701},{\"isServerMessage\":true,\"message\":\"ERROR 001564: Requested tile count(888541) exceeds the maximum allowed number of tiles(100000) to be exported for service Norddeutschland/Norddeutschland_32632:MapServer.\",\"severity\":\"error\",\"timestamp\":1567768909701},{\"isServerMessage\":true,\"message\":\"Failed to execute (Export Cache).\",\"severity\":\"error\",\"timestamp\":1567768909701},{\"isServerMessage\":true,\"message\":\"Failed at Fri Sep 06 13:21:45 2019 (Elapsed Time: 0,04 seconds)\",\"severity\":\"info\",\"timestamp\":1567768909701},{\"isServerMessage\":true,\"message\":\"Failed.\",\"severity\":\"error\",\"timestamp\":1567768909701},{\"isServerMessage\":false,\"message\":\"Job failed. Job error 6 Illegal state. Server job has failed. ERROR 001564: Requested tile count(888541) exceeds the maximum allowed number of tiles(100000) to be exported for service Norddeutschland/Norddeutschland_32632:MapServer.\",\"severity\":\"error\",\"timestamp\":1567768909701}],\"serverJobId\":\"j784cd2c3b4744eefbc4ee39d9dd8379c_et\",\"status\":\"failed\",\"timeSetServerJobId\":1567768888411},\"outputFilePath\":\"/tmp/GenerateOfflineMap - C++-Beclpw/offlinemap.mmpk/p13/3a592b52-085d-4f78-87fa-ddbf1f808668.tpk\",\"serviceUrl\":\"http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Norddeutschland/Norddeutschland_32632/MapServer\",\"subJobType\":\"exportTileCacheJob\"},{\"exportTileCacheParameters\":{\"areaOfInterest\":{\"xmin\":475237.87850777223,\"ymin\":5866861.4344202308,\"xmax\":509861.82226250961,\"ymax\":5888816.9199876273,\"spatialReference\":{\"wkid\":32632}},\"levelIds\":[0,1,2,3,4,5,6]},\"job\":{\"exportTileCacheJob\":{\"downloadFilePath\":\"/tmp/GenerateOfflineMap - C++-Beclpw/offlinemap.mmpk/p13/d2857dda-c450-4eaf-a3ee-ef98c3dfe543.tpk\",\"mapServiceUrl\":\"http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Bremen/Hemelingen_TIF_32632/MapServer\",\"parameters\":{\"areaOfInterest\":{\"xmin\":475237.87850777223,\"ymin\":5866861.4344202308,\"xmax\":509861.82226250961,\"ymax\":5888816.9199876273,\"spatialReference\":{\"wkid\":32632}},\"levelIds\":[0,1,2,3,4,5,6]}},\"jobType\":\"exportTileCacheJob\",\"messages\":[{\"isServerMessage\":false,\"message\":\"Job started.\",\"severity\":\"info\",\"timestamp\":1567768885875},{\"isServerMessage\":false,\"message\":\"Creating server job.\",\"severity\":\"info\",\"timestamp\":1567768885875},{\"isServerMessage\":false,\"message\":\"Sending request create server job exportTiles.\",\"severity\":\"info\",\"timestamp\":1567768885875},{\"isServerMessage\":false,\"message\":\"Received response for create server job exportTiles.\",\"severity\":\"info\",\"timestamp\":1567768887668},{\"isServerMessage\":false,\"message\":\"Delaying job status for 1 second.\",\"severity\":\"info\",\"timestamp\":1567768887669},{\"isServerMessage\":false,\"message\":\"Sending request server job status.\",\"severity\":\"info\",\"timestamp\":1567768888669},{\"isServerMessage\":false,\"message\":\"Received response for server job status.\",\"severity\":\"info\",\"timestamp\":1567768888795},{\"isServerMessage\":false,\"message\":\"Delaying job status for 5 seconds.\",\"severity\":\"info\",\"timestamp\":1567768888795},{\"isServerMessage\":false,\"message\":\"Sending request server job status.\",\"severity\":\"info\",\"timestamp\":1567768893796},{\"isServerMessage\":false,\"message\":\"Received response for server job status.\",\"severity\":\"info\",\"timestamp\":1567768893853},{\"isServerMessage\":false,\"message\":\"Delaying job status for 5 seconds.\",\"severity\":\"info\",\"timestamp\":1567768893853},{\"isServerMessage\":false,\"message\":\"Sending request server job status.\",\"severity\":\"info\",\"timestamp\":1567768898854},{\"isServerMessage\":false,\"message\":\"Received response for server job status.\",\"severity\":\"info\",\"timestamp\":1567768898910},{\"isServerMessage\":false,\"message\":\"Delaying job status for 5 seconds.\",\"severity\":\"info\",\"timestamp\":1567768898910},{\"isServerMessage\":false,\"message\":\"Sending request server job status.\",\"severity\":\"info\",\"timestamp\":1567768903911},{\"isServerMessage\":false,\"message\":\"Received response for server job status.\",\"severity\":\"info\",\"timestamp\":1567768903968},{\"isServerMessage\":false,\"message\":\"Delaying job status for 5 seconds.\",\"severity\":\"info\",\"timestamp\":1567768903968},{\"isServerMessage\":false,\"message\":\"Sending request server job status.\",\"severity\":\"info\",\"timestamp\":1567768908969},{\"isServerMessage\":false,\"message\":\"Received response for server job status.\",\"severity\":\"info\",\"timestamp\":1567768909027},{\"isServerMessage\":true,\"message\":\"Submitted.\",\"severity\":\"info\",\"timestamp\":1567768909027},{\"isServerMessage\":true,\"message\":\"Executing...\",\"severity\":\"info\",\"timestamp\":1567768909027},{\"isServerMessage\":true,\"message\":\"Executing (Export Cache): ExportCache Bremen/Hemelingen_TIF_32632:MapServer # COMPACT TRUE 1 TRUE \\\"475237,878507772 5866861,43442023 509861,82226251 5888816,91998763\\\" 0,1,2,3,4,5,6 FALSE \\\"Feature Set\\\" # {\\\"requestMode\\\":\\\"REST\\\",\\\"exportBy\\\":\\\"LevelID\\\",\\\"recompress\\\":false,\\\"recompressQuality\\\":75}\",\"severity\":\"info\",\"timestamp\":1567768909027},{\"isServerMessage\":true,\"message\":\"Start Time: Fri Sep 06 13:21:45 2019\",\"severity\":\"info\",\"timestamp\":1567768909027},{\"isServerMessage\":true,\"message\":\"ERROR 001564: Requested tile count(888454) exceeds the maximum allowed number of tiles(100000) to be exported for service Bremen/Hemelingen_TIF_32632:MapServer.\",\"severity\":\"error\",\"timestamp\":1567768909027},{\"isServerMessage\":true,\"message\":\"Failed to execute (Export Cache).\",\"severity\":\"error\",\"timestamp\":1567768909027},{\"isServerMessage\":true,\"message\":\"Failed at Fri Sep 06 13:21:45 2019 (Elapsed Time: 0,05 seconds)\",\"severity\":\"info\",\"timestamp\":1567768909027},{\"isServerMessage\":true,\"message\":\"Failed.\",\"severity\":\"error\",\"timestamp\":1567768909027},{\"isServerMessage\":false,\"message\":\"Job failed. Job error 6 Illegal state. Server job has failed. ERROR 001564: Requested tile count(888454) exceeds the maximum allowed number of tiles(100000) to be exported for service Bremen/Hemelingen_TIF_32632:MapServer.\",\"severity\":\"error\",\"timestamp\":1567768909027}],\"serverJobId\":\"j394c73e6458e433480c121d550a23b69_et\",\"status\":\"failed\",\"timeSetServerJobId\":1567768887668},\"outputFilePath\":\"/tmp/GenerateOfflineMap - C++-Beclpw/offlinemap.mmpk/p13/d2857dda-c450-4eaf-a3ee-ef98c3dfe543.tpk\",\"serviceUrl\":\"http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Bremen/Hemelingen_TIF_32632/MapServer\",\"subJobType\":\"exportTileCacheJob\"}]},\"jobType\":\"generateOfflineMapJob\",\"messages\":[{\"isServerMessage\":false,\"message\":\"Job started.\",\"severity\":\"info\",\"timestamp\":1567768885867},{\"isServerMessage\":false,\"message\":\"Loading offline map task.\",\"severity\":\"info\",\"timestamp\":1567768885867},{\"isServerMessage\":false,\"message\":\"Loading online map.\",\"severity\":\"info\",\"timestamp\":1567768885867},{\"isServerMessage\":false,\"message\":\"Loading online layers.\",\"severity\":\"info\",\"timestamp\":1567768885867},{\"isServerMessage\":false,\"message\":\"Creating output directories.\",\"severity\":\"info\",\"timestamp\":1567768885873},{\"isServerMessage\":false,\"message\":\"Prepare layer for offline: Name: Norddeutschland_32632 URL: http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Norddeutschland/Norddeutschland_32632/MapServer Message: Min scale for tile package has been overridden by layer setting: changed from 0 to 250000\",\"severity\":\"info\",\"timestamp\":1567768885875},{\"isServerMessage\":false,\"message\":\"Prepare layer for offline: Name: Norddeutschland_32632 URL: http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Norddeutschland/Norddeutschland_32632/MapServer Message: Max scale for tile package has been overridden by layer setting: changed from 0 to 500\",\"severity\":\"info\",\"timestamp\":1567768885875},{\"isServerMessage\":false,\"message\":\"Prepare layer for offline: Name: Hemelingen_TIF_32632 URL: http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Bremen/Hemelingen_TIF_32632/MapServer Message: Min scale for tile package has been overridden by layer setting: changed from 0 to 32000\",\"severity\":\"info\",\"timestamp\":1567768885875},{\"isServerMessage\":false,\"message\":\"Prepare layer for offline: Name: Hemelingen_TIF_32632 URL: http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Bremen/Hemelingen_TIF_32632/MapServer Message: Max scale for tile package has been overridden by layer setting: changed from 0 to 500\",\"severity\":\"info\",\"timestamp\":1567768885875},{\"isServerMessage\":false,\"message\":\"Starting 2 sub-jobs.\",\"severity\":\"info\",\"timestamp\":1567768885875},{\"isServerMessage\":false,\"message\":\"Export tile cache: Job started. URL: http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Norddeutschland/Norddeutschland_32632/MapServer\",\"severity\":\"info\",\"timestamp\":1567768885875},{\"isServerMessage\":false,\"message\":\"Export tile cache: Creating server job. URL: http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Norddeutschland/Norddeutschland_32632/MapServer\",\"severity\":\"info\",\"timestamp\":1567768885875},{\"isServerMessage\":false,\"message\":\"Export tile cache: Job started. URL: http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Bremen/Hemelingen_TIF_32632/MapServer\",\"severity\":\"info\",\"timestamp\":1567768885875},{\"isServerMessage\":false,\"message\":\"Export tile cache: Creating server job. URL: http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Bremen/Hemelingen_TIF_32632/MapServer\",\"severity\":\"info\",\"timestamp\":1567768885875},{\"isServerMessage\":false,\"message\":\"Export tile cache: Failed: \\\"Job error 6 Illegal state. Server job has failed. ERROR 001564: Requested tile count(888454) exceeds the maximum allowed number of tiles(100000) to be exported for service Bremen/Hemelingen_TIF_32632:MapServer.\\\"\",\"severity\":\"warning\",\"timestamp\":1567768909027},{\"isServerMessage\":false,\"message\":\"Export tile cache: Failed: \\\"Job error 6 Illegal state. Server job has failed. ERROR 001564: Requested tile count(888541) exceeds the maximum allowed number of tiles(100000) to be exported for service Norddeutschland/Norddeutschland_32632:MapServer.\\\"\",\"severity\":\"warning\",\"timestamp\":1567768909701},{\"isServerMessage\":false,\"message\":\"Error generating/fetching package item: Name: Norddeutschland_32632 URL: http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Norddeutschland/Norddeutschland_32632/MapServer Common::Error: Job error 6 Illegal state. Server job has failed. ERROR 001564: Requested tile count(888541) exceeds the maximum allowed number of tiles(100000) to be exported for service Norddeutschland/Norddeutschland_32632:MapServer.\",\"severity\":\"warning\",\"timestamp\":1567768909701},{\"isServerMessage\":false,\"message\":\"Error generating/fetching package item: Name: Hemelingen_TIF_32632 URL: http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Bremen/Hemelingen_TIF_32632/MapServer Common::Error: Job error 6 Illegal state. Server job has failed. ERROR 001564: Requested tile count(888454) exceeds the maximum allowed number of tiles(100000) to be exported for service Bremen/Hemelingen_TIF_32632:MapServer.\",\"severity\":\"warning\",\"timestamp\":1567768909701},{\"isServerMessage\":false,\"message\":\"Loading symbols for offline use.\",\"severity\":\"info\",\"timestamp\":1567768909701},{\"isServerMessage\":false,\"message\":\"Writing mobile map.\",\"severity\":\"info\",\"timestamp\":1567768909701},{\"isServerMessage\":false,\"message\":\"Job succeeded.\",\"severity\":\"info\",\"timestamp\":1567768909722}],\"status\":\"succeeded\"}"

You have been right: Requested tile count(888454) exceeds the maximum allowed number of tiles(100000) to be exported

So i tried to increased that number(s):

ArcMap, open Service Properties seems to be the way to do this. Portal and ArcGIS Server Manager (10.5) do not offer that value...After a boot of ArcGIS Server it seems to work, puhh

Redo downloading: of the maximum extent:

After ~5 minutes (progress ~30%) the /tmp/GenerateOfflineMap-C++XYz - Directory has a size of ~9 Gb.

After ~10Minutes (progress ~40%) the size is still ~9Gb. (Devices has enough space)

And it seems to stop at 41%, with illigal state:

Export tile cache: Creating server job. URL: http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Norddeutschland/Norddeutschland_32632/MapServer\",\"severity\":\"info\",\"timestamp\":1567770552232},{\"isServerMessage\":false,\"message\":\"Export tile cache: Job started. URL: http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Bremen/Hemelingen_TIF_32632/MapServer\",\"severity\":\"info\",\"timestamp\":1567770552232},{\"isServerMessage\":false,\"message\":\"Export tile cache: Creating server job. URL: http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Bremen/Hemelingen_TIF_32632/MapServer\",\"severity\":\"info\",\"timestamp\":1567770552232},{\"isServerMessage\":false,\"message\":\"Export tile cache: Server job complete. URL: http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Bremen/Hemelingen_TIF_32632/MapServer\",\"severity\":\"info\",\"timestamp\":1567770635774},{\"isServerMessage\":false,\"message\":\"Export tile cache: Downloading from server. URL: http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Bremen/Hemelingen_TIF_32632/MapServer\",\"severity\":\"info\",\"timestamp\":1567770635889},{\"isServerMessage\":false,\"message\":\"Export tile cache: Downloaded from server. URL: http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Bremen/Hemelingen_TIF_32632/MapServer\",\"severity\":\"info\",\"timestamp\":1567770654657},{\"isServerMessage\":false,\"message\":\"Export tile cache: Succeeded. URL: http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Bremen/Hemelingen_TIF_32632/MapServer\",\"severity\":\"info\",\"timestamp\":1567770654657},{\"isServerMessage\":false,\"message\":\"Export tile cache: Failed: \\\"Job error 6 Illegal state. Server job has failed. ERROR 999999: Error executing function. The index was either too large or too small.\\\"\",\"severity\":\"warning\",\"timestamp\":1567771610035},{\"isServerMessage\":false,\"message\":\"Error generating/fetching package item: Name: Norddeutschland_32632 URL: http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Norddeutschland/Norddeutschland_32632/MapServer Common::Error: Job error 6 Illegal state. Server job has failed. ERROR 999999: Error executing function. The index was either too large or too small.\",\"severity\":\"warning\",\"timestamp\":1567771610035},{\"isServerMessage\":false,\"message\":\"Loading symbols for offline use.\",\"severity\":\"info\",\"timestamp\":1567771610035},{\"isServerMessage\":false,\"message\":\"Writing mobile map.\",\"severity\":\"info\",\"timestamp\":1567771610035},{\"isServerMessage\":false,\"message\":\"Layer result: Successfully taken offline. Name: Hemelingen_TIF_32632 URL: http://excgeo21.sl.defence-elec.de/arcgis/rest/services/Bremen/Hemelingen_TIF_32632/MapServer Path: /tmp/GenerateOfflineMap - C++-Iuudgo/offlinemap.mmpk/p13/dc4d6569-0929-49ba-9ccb-8509c5d15b08.tpk\",\"severity\":\"info\",\"timestamp\":1567771610050},{\"isServerMessage\":false,\"message\":\"Job succeeded.\",\"severity\":\"info\",\"timestamp\":1567771610051}],\"status\":\"succeeded\"}"

The corresponding cache directories on the ArcGIS server have a size of just 300Mb + 3.5 Gb....

Finally i would like to download a service having an cache directory size of ~15Gb, maybe more...

I think i excced some limits even now 😞

Do you now some limitation?

0 Kudos
LukeSmallwood
Esri Contributor

Thanks for trying that out Norbert. The limits of tile counts etc. are not something we have control over via Runtime code so I'm not an expert on whether those have any hard limits. A couple of observations though:

1. Tiled data tends to increase dramatically in size with every additional LOD you include (I think it's a quadratic increase). If you can limit the amount of data you need to take offline by even a single LOD you will see a massive reduction in the size of the data. If you take an approach like that you may want to dynamically set the maxSale property of your Map and ArcGISTiledLayer (e.g. the basemap layers) to 0 (or your desired maxScale) so that you can zoom in fully. That will mean that the basemapp data is up-sampled when you zoom past the available data. An up-sampled tiled layer eventually starts to look pixelated/blocks but generally it is fine for the next scale down or so.

2. If you take a look at our "Basemap by reference" workflow (see arcgis-runtime-samples-qt/ArcGISRuntimeSDKQt_CppSamples/Maps/GenerateOfflineMapLocalBasemap at maste...  for a sample) you may be able to avoid taking the basemap offline each time. The idea with this workflow is that you can place the basemap (e.g. a tpk) on your device ahead of time (for example create it using Pro and then side load it to your device or export once). Then you can configure the Offline workflows to re-use that basemap for each new offline map.

I hope that helps,

Luke

NorbertThoden
Occasional Contributor III

Hi Luke!

Thanks for the imidiate replay, wow 🙂

Regarding 1) Size in relation to LOD:

I have learned some of that paramter in order to zoom in more than the maxScales of the service allows.

Regarding 2) Basemap by reference:

I want to avoid the necessity to create a tpk of the area offline. That is the reason i spent time with the OfflineMapTask...

Simplified explanation:

For one customer we have

  • one topo and one aerial map for 2D (and an adequate projection (32632 for Bremen, and MGRS-Grid is working)
  • one topo and one aerial map for 3D

This leads to 4 map services, Idealy with the same extent and so on.

And for the devices which are partially offline, i am looking for an possibility to let the user (or maybe his admin) do the dowload. I want to avoid, that i have to configure NOW the offline file he will use TOMORROW.

The basemaps are changed about one ime per year.

One alternative we currently using is to copy the cache directory.... but isn´t it a poor solution?

And i still have to configure the directories to the application in case the device is offline....

Until now there is no basemap selection for the user. Its more or less static.

And since i can´t get in touch with the portal and or Arcgis Server to discover the basemaps or services, it´s diffcult to add a proper basemap selection in our application....

Btw:

If i load a mmpk, i assume that i have nearly the some enviroment as normal: i can iterate through the basemaps, toggle visibility, change transparency, brightness, contrast and so, right?

Thx

0 Kudos