CORS Issue Running Server Workflow
I have a client workflow that calls a server workflow as the last activity. This server workflow send an email with information for end users. I am now encountering a CORS issue, which in the browser states the following:

The redacted part of the URL is actually the name of the machine, not the DNS name that IT added so that the URL doesn't show the name of the machine.
I have both the client and server workflows saved so the baked-in auth URL should be vertigis.domain.org/vertigisstudio/workflow/service/auth/token/run. The part of the workflow that fails is the activity that calls the server workflow. Is this going to continue to occur because the workflow is hosted on the server and not in Portal, so the URL references the server name? Do I need to just have IT allow CORS requests from the URL it's currently prohibiting, since it's a server workflow?
This is also occurring with another workflow that also calls a server workflow as the last activity, which makes me think it is because it's a server workflow, and the URL references the machine name, so the CORS policy needs to be updated.
EDIT: IT has a very loose CORS policy, so this shouldn't be caused by IT policy. I'm not sure what else is causing it
-
The server url for a server workflow is stored in the properties of its AGOL/Portal item. It's likely you were using the internal url for the designer when you saved the server workflow.
I recommend you do the following:
- Open Item Manager: https://apps.vertigisstudio.com/itemmanager
- Use the controls on the left to locate your server workflow and select it. (The actual content of the server workflow is saved on your server, but there is a “wrapper” workflow saved in AGOL/Portal.)
- In the second column, select Item JSON.
- Look for a section entitled “properties”, something like this:
"properties": {
"isServerWorkflow": true,
"serverUrl": “https://(server)/vertigisstudio/workflow/service”
}, - Edit the “serverUrl” to the value you want.
- Click Save at the bottom-right.
It might also be possible to just access the designer using the public URL and edit/save your server workflow. I don't recall offhand if we replace the serverUrl on subsequent saves, or if it's only set once on creation.
0
Vous devez vous connecter pour laisser un commentaire.
Commentaires
1 commentaire