AGOL Web Mapping Application With Updating KML

920
7
05-27-2014 04:58 AM
CharlesGant
New Contributor III
I'm trying to create a web mapping application with a URL linked KML.  I have the application completed, with the KML loaded in the web map itself, linked to the URL.  Everything looks great.  However, when I create an updated KML, and ftp to my webserver (where the KML is linked from) the data is not updating.  Why is that?  Does the KML/KMZ have to be hosted as a Dynamic Map Service?  Can you not just link to a KML/KMZ and have it update like I'm trying to do?

Thanks in advance!
Tags (2)
0 Kudos
7 Replies
CharlesGant
New Contributor III
Anyone have anything?
0 Kudos
HeathBrackett1
Occasional Contributor II
I had reported this as a bug last year. Bug NIM088399.  It hasn't been fixed.

I noticed that you can register the kml feed as an item and every time you open the item it is refreshed.  But when it is added to a web map, it does not refresh - in fact, layers within the kml feed will turn off as they try to refresh.

That's all I know.  The only solution that I know of is to create a map service from the database that the kml is accessing.  Kinda stinks!

Heath
0 Kudos
CharlesGant
New Contributor III
Thanks Heath,

What a bummer.  I wish there was a better solution.  How do you create a Map Service for a KMZ since you can directly load that into ArcMap, can you?

Danny
0 Kudos
DavidRunneals
New Contributor II

Here's a link to the documentation on this: KML—Help | ArcGIS

AGOL caches KML's for up to 30 minutes.

One way to get around that is to make another KML file and use the <NetworkLink> Tags in it (an example can be found here). Even though the KML is at http://dotp.blob.core.windows.net/511/511events.kml‌, we reference the kml where the actual data is at (http://dotp.blob.core.windows.net/511/511_events_data.kml‌) and specify a refresh interval in seconds (600 = 10 min).

Google's KML Reference guide is a GREAT place to go and look for details on KML markup tags.

Hope this helps answer your question.

David Runneals

GIS Intern, Iowa Department of Transportation

HeathBrackett1
Occasional Contributor II

Thanks David!  That works well for me and it just may be the solution that we use to begin to incorporate these dynamic kml layers in our web maps. 

The only thing I see that is unfortunate about this method is that the actual kml layers are embedded deeper into the service if you need to go deeper to turn particular layers on of off.  But that's a relatively small consequence in this case.

Heath

0 Kudos
DavidRunneals
New Contributor II

Yup, NP. Please mark my response answered if that is what you needed.

I also have posted about that same issue here. Hopefully someone will be able to answer it eventually.

-David

0 Kudos
HeathBrackett1
Occasional Contributor II

I don't think I can mark this as answered since I am not the person who started this thread.  At least that's how it used to be in the old forums...

Thanks again.

0 Kudos