Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn More

View all

Sign in to view all badges

Update Data step failing on concurrent updates

Avatar

Avatar
Validate 10
Level 3
Kanwaljit
Level 3

Likes

19 likes

Total Posts

52 posts

Correct Reply

3 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 10
View profile

Avatar
Validate 10
Level 3
Kanwaljit
Level 3

Likes

19 likes

Total Posts

52 posts

Correct Reply

3 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 10
View profile
Kanwaljit
Level 3

26-07-2017

Hi,

We have a AC6 6.1.1 with build number : 8594. It has an UPDATe STEP that is trying to insert-or-update into a AC6's own database ( no FDA being used here for this update data step).

This step is in a campaign workflow that has two instance that are trying to update the same row in the same table. But it is throwing an error.

Is there a way, we can enable either a WAIT+QUEUE or a concurrency check to wait in the step till the database lock is available. Is this a configuration ?

/Regards

Kanwal

Accepted Solutions (0)

Answers (6)

Answers (6)

Avatar

Avatar
Validate 1
Level 2
lukkyluke
Level 2

Likes

8 likes

Total Posts

28 posts

Correct Reply

0 solutions
Top badges earned
Validate 1
Boost 5
Boost 3
Boost 1
Applaud 5
View profile

Avatar
Validate 1
Level 2
lukkyluke
Level 2

Likes

8 likes

Total Posts

28 posts

Correct Reply

0 solutions
Top badges earned
Validate 1
Boost 5
Boost 3
Boost 1
Applaud 5
View profile
lukkyluke
Level 2

20-09-2018

Solved by setting the isRunning-variable to false in the advanced tab in the scheduler-activity. This is code is only triggered upon restart/start and not by "execute pending tasks now"

Avatar

Avatar
Validate 10
MVP
Amit_Kumar
MVP

Likes

329 likes

Total Posts

649 posts

Correct Reply

231 solutions
Top badges earned
Validate 10
Validate 1
Establish
Give Back 50
Give Back 5
View profile

Avatar
Validate 10
MVP
Amit_Kumar
MVP

Likes

329 likes

Total Posts

649 posts

Correct Reply

231 solutions
Top badges earned
Validate 10
Validate 1
Establish
Give Back 50
Give Back 5
View profile
Amit_Kumar
MVP

17-07-2018

Hi Kanwaljit,

In Adobe campaign there is no configuration available to enforce locks, you can use SQL activity to use SQL code to use locking if required.

Now you have two option, either change the workflow design to prevent this from happening or you can use below approach, which will cover some use cases with obvious performance tradeoffs.

1. Reduce batch size i.e to 100

1529688_pastedImage_0.png

2. Use Update records systematically

1529693_pastedImage_2.png

this should be able to fix your issue but redesigning the workflow should be the ideal solution.

Avatar

Avatar
Boost 50
Employee
Adhiyan
Employee

Likes

239 likes

Total Posts

342 posts

Correct Reply

124 solutions
Top badges earned
Boost 50
Boost 5
Boost 3
Boost 25
Boost 100
View profile

Avatar
Boost 50
Employee
Adhiyan
Employee

Likes

239 likes

Total Posts

342 posts

Correct Reply

124 solutions
Top badges earned
Boost 50
Boost 5
Boost 3
Boost 25
Boost 100
View profile
Adhiyan
Employee

12-07-2018

Test workflow :

1526371_pastedImage_1.png

Set up the instance variable:

1526370_pastedImage_0.png

Avatar

Avatar
Boost 50
Employee
Adhiyan
Employee

Likes

239 likes

Total Posts

342 posts

Correct Reply

124 solutions
Top badges earned
Boost 50
Boost 5
Boost 3
Boost 25
Boost 100
View profile

Avatar
Boost 50
Employee
Adhiyan
Employee

Likes

239 likes

Total Posts

342 posts

Correct Reply

124 solutions
Top badges earned
Boost 50
Boost 5
Boost 3
Boost 25
Boost 100
View profile
Adhiyan
Employee

12-07-2018

Hi Kanwaljit,

The solution here could be to use a concurrency check for the workflow instance by using an instance variable called isRunning.

Instance variables are shared by all the parallel executions of the workflows.

Here is a simple test workflow:

The scheduler is triggering an event every minute. The next test activity is going to test the isRunning instance variable to decide

whether or not to continue the execution:

Note: isRunning is the variable name I've chosen for this example. This is not a built-in variable.

Then the activity immediately following the test in the yes branch must set the instance variable in its Initialization script:

instance.vars.isRunning = true

Finally the very last activity in the yes branch must revert the variable to false in its Initialization script:

instance.vars.isRunning = false

Regards,

Adhiyan

Avatar

Avatar
Boost 3
Employee
deepikas1826242
Employee

Likes

3 likes

Total Posts

6 posts

Correct Reply

2 solutions
Top badges earned
Boost 3
Boost 1
Affirm 1
View profile

Avatar
Boost 3
Employee
deepikas1826242
Employee

Likes

3 likes

Total Posts

6 posts

Correct Reply

2 solutions
Top badges earned
Boost 3
Boost 1
Affirm 1
View profile
deepikas1826242
Employee

10-07-2018

Hi Kanwal,

This functionality is not available currently OOB.

Adobe recommends to improve the design of workflows so that multiple workflows do not try to improve the same schema at the same time.

Thanks,

Deepika

Avatar

Avatar
Validate 1
Level 2
lukkyluke
Level 2

Likes

8 likes

Total Posts

28 posts

Correct Reply

0 solutions
Top badges earned
Validate 1
Boost 5
Boost 3
Boost 1
Applaud 5
View profile

Avatar
Validate 1
Level 2
lukkyluke
Level 2

Likes

8 likes

Total Posts

28 posts

Correct Reply

0 solutions
Top badges earned
Validate 1
Boost 5
Boost 3
Boost 1
Applaud 5
View profile
lukkyluke
Level 2

29-08-2018

Hello,

I have implemented your suggested solution into one workflow. However I get problems as soon as the workflow gets paused due to an error. In such scenarios the isRunning variable is still set to true even after restart. Is there any way to auto-reset the instance variables in a workflow when the restart-button is clicked?