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

Rule Firing Order

Avatar

Avatar
Seeker
Level 2
bigbaldbasso
Level 2

Likes

14 likes

Total Posts

20 posts

Correct Reply

1 solution
Top badges earned
Seeker
Shape 1
Give Back
Ignite 1
Validate 1
View profile

Avatar
Seeker
Level 2
bigbaldbasso
Level 2

Likes

14 likes

Total Posts

20 posts

Correct Reply

1 solution
Top badges earned
Seeker
Shape 1
Give Back
Ignite 1
Validate 1
View profile
bigbaldbasso
Level 2

25-04-2019

I am migrating a property from DTM to Launch.  I have a couple of rules that trigger on Library Loaded that I need to fire early, so I set the Order value to 10 and 20.  All the others are the default of 50.

The rule with an order of 10 always fires first, but one with an order of 20 always fires after several of the 50 rules.  This is causing some grief.

Why is the order value not honored after the first one?

Thanks!

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Seeker
Level 2
bigbaldbasso
Level 2

Likes

14 likes

Total Posts

20 posts

Correct Reply

1 solution
Top badges earned
Seeker
Shape 1
Give Back
Ignite 1
Validate 1
View profile

Avatar
Seeker
Level 2
bigbaldbasso
Level 2

Likes

14 likes

Total Posts

20 posts

Correct Reply

1 solution
Top badges earned
Seeker
Shape 1
Give Back
Ignite 1
Validate 1
View profile
bigbaldbasso
Level 2

29-04-2019

Hi, stephenk67545596

Actually, this rule has custom code in the rule condition and no actual rule body.  That custom code does a getVar on several data elements which, in turn, execute custom code.

I didn't write it in the first place, but I have seen plenty of instances of tricks like this where people have tried to reduce the number of js files that DTM would load.  So it's a weird case.  I have gotten around the problem by moving this code into the rule with an Order value of 10.  Phase II of the migration is to unwind things like this and do stuff in a more Launch-y way.

If you are looking for positives, I now have practical experience to back up my warning to clients that the "creative" implementations they may have done to make DTM more performant can lead to hassles when migrating to Launch.

Answers (1)

Answers (1)

Avatar

Avatar
Boost 5
Level 2
stephenk6754559
Level 2

Likes

22 likes

Total Posts

9 posts

Correct Reply

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

Avatar
Boost 5
Level 2
stephenk6754559
Level 2

Likes

22 likes

Total Posts

9 posts

Correct Reply

0 solutions
Top badges earned
Boost 5
Boost 3
Boost 10
Boost 1
Applaud 5
View profile
stephenk6754559
Level 2

27-04-2019

Does your rule with the order of 20 (which is firing late) have a custom code action? I am seeing that custom code actions appear to execute somewhat asynchronously and cause rules to fire out of order, I'm wondering if you are seeing the same thing.