4

Is there a way to check quickly within the service description when (date, time) the service had been published?

PolyGeo
  • 65,136
  • 29
  • 109
  • 338
  • What version of ARCGIS Server do you have? AFAIK this information isn't stored anywhere. But I'll love to be proved wrong. – Devdatta Tengshe Oct 22 '13 at 02:46
  • Thank you Devdatta Tengshe. Will keep posted if I find something here. (using ArcGis server 10.1, will see what happens under 10.2). – Pascal Douard Oct 22 '13 at 18:41
  • @Alex: the CreaDate and CreaTime elements show the date/time that the service was created, not the date/time that the service was last published. It looks like that information is not available in either the REST endpoint of the service nor the Admin API of of the server (nor in ArcGIS Online as the Updated date). Seems like the only way to find this is to browse the AGS server directory and get the timestamp on the \AGS_SERVER_NAME\DRIVE$\arcgisserver\directories\arcgissystem\arcgisinput\FOLDER_NAME\SERVICE_NAME.MapServer folder, and/or on the MXD in the underlying ...\extracted\v101\MXD_NAM – user126691 Sep 12 '18 at 00:03

2 Answers2

1

This information is not exposed via GUI for users in 10.1/10.2 (although it would be nice to have), so the answer is no, you cannot check it quickly. However, since 10.1, there is metadata.xml file that is created during publishing of service (not only map services, but others too).

"C:\arcgisserver\directories\arcgissystem\arcgisinput\<servicename>.<servicetype>\extracted\esriinfo\metadata\metadata.xml"

This XML file contains two tags which can tell you when the service was published.

<CreaDate>20130522</CreaDate>
<CreaTime>14393300</CreaTime>

Since it is only the service name that will be different, you have multiple options:

  1. Use Windows explorer and manually navigate to the location for each service you have.
  2. Use Python for reading the rows in the .xml file or parse XML and look for these tags.
  3. Embrace this Python code into an ArcGIS script tool / add-in that will take as input a service name and type (MapService, ImageService etc) and give back in Progress dialog those two tags information.
  4. Use ArcGIS Server Admin API to define the service name programmatically and then retrieve the tags by parsing XML file or just reading raw lines. An example of similar tools where user provides service name and gets back some info is ArcGIS Server Administration Toolkit

UPDATE: this information is actually exposed in 10.1 and 10.2 via GUI and the REST endpoint (so you can parse the content with Python), so you can view the date/time a service was created via URL:

http://server:6080/arcgis/rest/services/Parks/MapServer/info/metadata

This web page can be opened in REST API via ArcGIS Services Directory > service > under Child Resources - Info > Metadata.

Alex Tereshenkov
  • 29,912
  • 4
  • 54
  • 119
0

The 2 create tags in the file "C:\arcgisserver\directories\arcgissystem\arcgisinput\<servicename>.<servicetype>\extracted\esriinfo\metadata\metadata.xml" seem to provide the date the map service was created but not last published.

But the time stamp of the file is the approximate date/time the map service was last published. Also the latest server log folder ("C:\arcgisserver\logs\<server>\services\<servicename>_YYYYMMDDhhmm.<servicetype>") and log file inside have a date/time stamp that is the approximate date/time, as well as their names. And the log file inside that folder has a tag named Msg time that has the date/time.

Kadir Şahbaz
  • 76,800
  • 56
  • 247
  • 389