M.App Enterprise Discussions

Discuss topics with other M.App Enterprise Product pioneers and experts to get the most out of it.
Showing results for 
Search instead for 
Do you mean 
Reply
Highlighted
Contributor
Posts: 28
Registered: ‎10-23-2015
Accepted Solution

Issues adding WMTS from Apollo to Rich Client

Good day.

 

I'm having some strange issues when trying to add a WMTS service, served from Apollo, to Rich Client. Following are the steps I took to add the layer:

 

  • WMS and WMTS services are created on Apollo Core for my ecw layer. See attached screenshot. The following Tile Matrixes has been enabled:
    • Google Maps Compatible
    • GoogleMapsCompatibleExt:epsg:3857
    • GoogleMapsCompatibleExt2:epsg:3857
  • In MappEnt Studio, I created a WMTS Geoservice. See attached screenshot
    No errors pops up when I click on the Save button, however, there is an error logged in studio:
  • System.NullReferenceException: Object reference not set to an instance of an object.
       [Details]
       MS_LoggedBy: System.Collections.Generic.List`1[System.Object]
       at MApp.Endpoints.Fusion.FusionContext.SetupHttpClient()
       at MApp.Endpoints.Fusion.FusionContext.<GetServicesByTypeAsync>d__4.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at MApp.Endpoints.FusionContentController.<GetFusionImports>d__0.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Threading.Tasks.TaskHelpersExtensions.<CastToObject>d__1`1.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Web.Http.Controllers.ApiControllerActionInvoker.<InvokeActionAsyncCore>d__1.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Web.Http.Filters.ActionFilterAttribute.<CallOnActionExecutedAsync>d__6.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Web.Http.Filters.ActionFilterAttribute.<CallOnActionExecutedAsync>d__6.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Web.Http.Filters.ActionFilterAttribute.<ExecuteActionFilterAsyncCore>d__5.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Web.Http.Controllers.ActionFilterResult.<ExecuteAsync>d__5.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Web.Http.Filters.AuthorizationFilterAttribute.<ExecuteAuthorizationFilterAsyncCore>d__3.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Web.Http.Controllers.AuthenticationFilterResult.<ExecuteAsync>d__5.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Web.Http.Dispatcher.HttpControllerDispatcher.<SendAsync>d__15.MoveNext()
    • Also, when editing the newly created Geoservice again, the Tile Matrix is blank. Have to set it again before I save
  • I added the WMTS layer to the Desktop legend entry and launched Rich Client
    When displaying the WMTS layer, the image does not display. When looking at the Rich Client logs, I see the following at the bottom of the log. Complete logfile also attached:
  • <fieldset><h4>Detailed Error Information:</h4> 
      <div id="details-left"> 
       <table border="0" cellpadding="0" cellspacing="0"> 
        <tr class="alt"><th>Module</th><td>&nbsp;&nbsp;&nbsp;IIS Web Core</td></tr> 
        <tr><th>Notification</th><td>&nbsp;&nbsp;&nbsp;MapRequestHandler</td></tr> 
        <tr class="alt"><th>Handler</th><td>&nbsp;&nbsp;&nbsp;StaticFile</td></tr> 
        <tr><th>Error Code</th><td>&nbsp;&nbsp;&nbsp;0x80070002</td></tr> 
         
       </table> 
      </div> 
      <div id="details-right"> 
       <table border="0" cellpadding="0" cellspacing="0"> 
        <tr class="alt"><th>Requested URL</th><td>&nbsp;&nbsp;&nbsp;http://DBSERVER.geospace.co.za:80/erdas-iws/ogc/wmts/RSA_MOSAIC/RSA_MOSAIC_DECEMBER2016.ecw/default/OGC:1.0:GoogleMapsCompatible/10/591/597.png?TileMatrixSet=OGC:1.0:GoogleMapsCompatible&amp;Format=image/png&amp;TileRow=591&amp;Version=1.0.0&amp;Request=GetTile&amp;Service=WMTS&amp;Style=default&amp;TileCol=597&amp;Layer=RSA_MOSAIC_DECEMBER2016.ecw&amp;TileMatrix=10</td></tr> 
        <tr><th>Physical Path</th><td>&nbsp;&nbsp;&nbsp;C:\Program Files\Hexagon\ERDAS APOLLO\bin\ogc\wmts\RSA_MOSAIC\RSA_MOSAIC_DECEMBER2016.ecw\default\OGC:1.0:GoogleMapsCompatible\10\591\597.png</td></tr> 
        <tr class="alt"><th>Logon Method</th><td>&nbsp;&nbsp;&nbsp;Anonymous</td></tr> 
        <tr><th>Logon User</th><td>&nbsp;&nbsp;&nbsp;Anonymous</td></tr> 
         
       </table> 
       <div class="clear"></div> 
      </div> 
     </fieldset> 
    </div> 
     
    <div class="content-container"> 
     <fieldset><h4>More Information:</h4> 
      This error means that the file or directory does not exist on the server. Create the file or directory and try the request again. 
      <p><a href="http://go.microsoft.com/fwlink/?LinkID=62293&amp;IIS70Error=404,0,0x80070002,9600">View more information &raquo;</a></p> 
  • Seems Rich Client is looking for a tile on the Apollo server, which it cant find? Aren't the tiles created on the fly, on client side machines?
    Any help or suggestions will be appreciated!

Warm regards

Adriaan

Highlighted
Technical Evangelist
Posts: 1,374
Registered: ‎09-11-2015

Re: Issues adding WMTS from Apollo to Rich Client

Hi Adriaan,

 

Looks like a bug in the Desktop App, adding unnecessary extra parameters to the WMTS requests. Could you please create a support ticket on the matter?

 

Thanks,

Jan

Jan Neumann
Post Sales Engineer Web Applications
Hexagon Geospatial

Highlighted
Technical Evangelist
Posts: 1,374
Registered: ‎09-11-2015

Re: Issues adding WMTS from Apollo to Rich Client

Maybe worth mentioning is, that if you put the folder / files into (Default) folder of Apollo Essentials, it will work fine in Desktop App. Looks like the problem is only for data located in other than default fodler tree.

Jan Neumann
Post Sales Engineer Web Applications
Hexagon Geospatial

Highlighted
Contributor
Posts: 28
Registered: ‎10-23-2015

Re: Issues adding WMTS from Apollo to Rich Client

Thanks for the reply Jan

 

I will log the ticket thanks. As for your other comment, I would not even know where to look for the files it is requesting. Arent those files generated on client's machines on the fly, in anycase? Would like to try and relocate the requested files to defaul folder, can you give more info regarding where I can find these?

 

Warm regards

Adriaan

Highlighted
Technical Evangelist
Posts: 1,374
Registered: ‎09-11-2015

Re: Issues adding WMTS from Apollo to Rich Client

What I found out is, that if the files are stored in (Default) folder in the Core Console (green rectangle), then the WMTS link doesn't have the /FOLDER/ added to the WMTS GetCapabilities URL. In this case Apollo accept (yet ignores) the extra parameters.

 

But if you create a new service ('mosa' in the red rectangle) the WMTS will include the new service's name in the URL. In this case, the added extra parameters to it will cause the Apollo WMTS to show error instead of file. This is something that should be probably solved on both sides of the software.

apollowmts.png

 

Jan Neumann
Post Sales Engineer Web Applications
Hexagon Geospatial