Give the possibility to remove default value for geoprocessing services parameters

1696
9
07-18-2016 11:38 AM
Status: Implemented
MaximeDemers
Occasional Contributor III

Give the possibility to remove default value for geoprocessing services parameters

Tags (1)
9 Comments
ThomasEdghill

Maxime Demers‌ are you able to expand a bit about the parameters you wish to be changed? I'd like to understand some more about which parameters you find yourself regularly having to switch, and how often you publish GP Services to get an idea of how regularly you are tasked with altering the default parameters.

Furthermore, is this something that you would like to be configured at a per-site basis, or a per-user basis? For example, would you like all users connecting to the same ArcGIS Server to face the same default values, configured by an Administrator? Or is there another way that you envision this request being fulfilled?

MaximeDemers

Hello Thomas Edghill,

The point of my request is the following. To be able to publish a geoprocessing service to ArcGIS Server, you have to run it first in ArcGIS Desktop. The parameter values you defined in ArcGIS Desktop for the service will automatically become the default parameter values published on ArcGIS Server.

That behavior is not really logical according to me. You don't necessary want to publish the parameters values that was used for testing the service during the publication process. Sometimes, you don't want default parameter values at all.

I hope that will clarify my point. Thank you very much for your interest in this idea.

Maxime Demers

ThomasEdghill

Hello Maxime,

Thank you for this clarification! I now have more understanding that you are referring to the inputs which must be defined in the script/model used to publish the GP Service.

If I may ask a further clarifying question, I'd like to know some more about how you use your GP Services. Are they typically used in a Web Application such as Web AppBuilder, something custom-built, or some other way? 

Best,

Thomas

FlorianSteiner

Hi Thomas,

I would like to answer your questions, since I have the same problem. We use GP-Services in a custom-built web app. We had to define an own "default" empty value (#) that is transferred to the GP-Service in order to overwrite these default values, if necessary.

Hope that helps!

Best regards,
Florian

SigamGeo

My GP Service uses a security key parameter (string). This key is given as default value to anyone who knows the rest url in the submit job page. I have to try to input a fake key and modify it hard coded in Python when running the tool in AG, then modify the script back in the published service folder.

MaximeDemers

You could do something like this to make the script run completely only when published on server:

from platform import node

if node() == 'your_server_machine_name':
  #here you put your gp service script‍‍‍‍

When you run the script with empty input parameters on your desktop, there will be no output so no default value when published to the server

Bernd_Loigge

And again - this is so unbelievable frustrating with this product called ESRI / ArcGis Pro / ArcGIS Enterprise / whatever product runs under your flag - why is this implemented this way? Who approves this during development? Why are the values set per default when publishing the WebTool? In the properties of the parameter section of the python script which I publish, I am not setting any default values - so I would expect that the script will get published without any DEFAULT VALUES!!!!! This makes 0, zero, no sense

MatthewGeorge

This is extremely frustrating. The default value for a Feature Layer input causes geometry types to be filtered to only those of the original input. The filter can be removed by editing the JSON for Web AppBuilder apps but means that I have to go and do this every time I create a new app that uses this tool.

jill_es
Status changed to: Implemented

This will be implemented in ArcGIS Pro 3.3 / ArcGIS Enterprise 11.3.