You are viewing limited content. For full access, please sign in.

Question

Question

Query Data slows down

asked on September 22, 2015

I have a workflow I'm using to create entries for testing and I've noticed that the query data activities slow down over time as the workflow runs. They start out at about 400 ms and get up to the 10 sec range with a few spiking over a minute.

I'd blame our database team but the steadily increasing nature of the delay makes me suspect a cumulative issue with workflow.

Anyone know if it's my slapdash workflow design, the nature of workflows or if I have to get them to throw some more CPU's at my SQL server VM?

 

(workflow 9.2)

workflow.jpg
workflow.jpg (18.58 KB)
0 0

Answer

SELECTED ANSWER
replied on September 22, 2015

This is expected behavior as the workflow has to keep track of more and more data with each iteration. One workaround would be to move the activities inside For Each into their one workflow and invoke it. That would reduce the number of activities in the current one (and speed up processing a bit since those workflows could run in parallel). But with 68,000 iterations you'll still see some slowdown.

1 0

Replies

replied on September 23, 2015

Hi Matt,

I think you are hitting into a queuing mechanism that is meant to limit the number of simultaneous queries on a database. Miruna's answer is good if you are trying to process more then 1k results in a workflow at a time. 

Try the answer from the following post: 

https://answers.laserfiche.com/questions/44010/Workflow-Custom-Queries-and-VB-Scripts

1 0
replied on September 22, 2015

As even the fast query data activities were in the  400 ms range and I have ~68,000 of them it would always be a slow workflow.

I've rewritten the workflow to use a new SQL view that contains all of the data the workflow needs so I only need one query data activity in the workflow.

It's not a solution to my question but a relevant work around.

workflow.jpg
workflow.jpg (7.41 KB)
0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.