[mapguide-users] Layer usage analyses

Jackie Ng jumpinjackie at gmail.com
Wed Feb 12 17:26:09 PST 2020


Hi Philip,

Layer toggles are manifested through GETDYNAMICMAPOVERLAYIMAGE requests to
the mapagent in the SHOWLAYERS/HIDELAYERS parameter. As
GETDYNAMICMAPOVERLAYIMAGE is an API specific to the mapagent, these requests
won't appear in your access.log, but rather your http web server logs.

Unfortunately the values passed in are runtime layer object uuids which are
near meaningless from an analytical context as they are always unique and
new values are generated for every MgMap creation.

The only practical solution at this moment would be implement a custom
mapagent handler (example:
https://github.com/jumpinjackie/mapagent-dotnet-sample) and intercept
`GETDYNAMICMAPOVERLAYIMAGE `requests to do custom logging. At the point of
request interception, you'll have the MAPNAME and layer ids to show/hide so
you can open a MgMap at that point and resolve the MgLayer instances from
the layer ids given and log the respective name/resid/etc of these MgLayers.

Then you'll have to re-route your viewer applications to talk to this custom
mapagent handler instead of the regular mapagent.

Hope that helps.

- Jackie



--
Sent from: http://osgeo-org.1560.x6.nabble.com/MapGuide-Users-f4182607.html


More information about the mapguide-users mailing list