I have 2 integrations that use REST calls to pull data from an outside system. I have a PM that uses these two integrations (2 nodes). When I run it it takes about 6 seconds to run. If a call the same 2 integrations from an interface, it takes about 3 seconds to run. I have a parent PM where I call this PM containing the integrations in order to pull the data, that way I can take that data and pass it into a form. I just don't like how slow it is. When I kick off the process model and load the form it is noticeable on the front end.
Is there a way to speed up process models with integrations, or a way to call integrations within an interface without using a saveInto()? Overall I just want to improve the time it takes to run the integrations so the form is faster to load.
Discussion posts and replies are publicly visible
If the integrations are read-only operations, you just just be able to call them in a load() like any other expression.
@Jim Schweitzer, I forgot to mention that the first integration is a post that I use to retrieve a token which I use in my second integration. Hence the reason why I need that PM or a saveInto
ok, then you can do something like this:
load( local!mytoken: rule!MYAPP_integration1(input: ri!myinput).result.body, local!myresult: rule!MYAPP_integration2(token: local!mytoken).result.body, local!myresult /* do whatever you want here */ )
Already tried that which doesn't work. Appian does not allow you to run an integration without a saveinto if it is a POST
I think Appian assumes read-only actions should be GET. I know this isn't 100% the case depending on the remote system. Perhaps your action isn't truly read-only though. If it has to be a POST then you'll need some saveInto
You can use a POST integration on load as long as you select the usage option as Queries Data instead of Modifies Data in your integration (assuming that your query is only to retrieve information and not to update data in the other system).
I did not know that. I will give it a try and see if that works
Hi Jose, Is the process model with 2 Integrations activity chained? If it is not activity chained, It would be best to have the integration call in the PM itself.
I assume in your case, you have 2 integrations followed by UI node and these are all activity chained. Assuming user might prefer to keep it in task, everytime we open the UI, the integration call is initiated whereas if the integration call is in PM, each of the service is called once.
@Peter Lewis, this seems to be the way to go. That was a simple change to make it work
Peter Lewis
I'm also facing a similar problem. I'm using a POST integration and the usage option is set as Queries Data only. Still I'm seeing a lag when the integration object is called from a process model. It takes 2 secs time from process and few (50-200) ms from the integration object.
That is the expected behaviour. Appian process are made to scale to millions of active instances, compromising on single node execution time.