Expand my Community achievements bar.

Applications are now open to join the Adobe Experience Platform Champion Program. Apply by June 10!

Mark Solution

This conversation has been locked due to inactivity. Please create a new post.

SOLVED

sendBeacon and _satellite.track with custom code actions

Avatar

Level 1

Hi all,

 

I have questions regarding the execution of _satellite.track calls in conjunction with 's.useBeacon = true' in Adobe Launch. Could someone please validate my assumptions for Adobe Launch?

 

Scenario 1: 

I trigger a _satelitte.track('xxx') via an onbeforeunload listener. The associated rule has a custom code action block where I interacting directly with the s object via s.tl(..). 's.useBeacon' is set to true.

 

 

Assumption: It's not given that tracking call is executed successfully, because custom code is not embedded within the main library and loaded asynchronously as a sperate file. This leads to a race condition, even with 's.useBeacon = true'.

 

Scenario 2: 

 

Same as above, with the difference that I use the Adobe Analytics extensions and a setVar + sendBeacon actions instead of custom code.

 

Assumption: It's given that tracking call is executed successfully because _satelitte.track is executed synchronously with associated code included in main library. s.useBeacon ensures request is sent even with the imminent page unload.

 

Is this assumption correct? 

 

Thanks a lot in advance!

Jones

 

 

1 Accepted Solution

Avatar

Correct answer by
Level 2

Yes, your assumptions are correct.

In general, Custom Code actions are loaded via separate JS files. So you will face a race condition in Scenario 1 where the browser is loading that JS file for your action, but then the browser also redirects to the next page.

View solution in original post

2 Replies

Avatar

Correct answer by
Level 2

Yes, your assumptions are correct.

In general, Custom Code actions are loaded via separate JS files. So you will face a race condition in Scenario 1 where the browser is loading that JS file for your action, but then the browser also redirects to the next page.

Avatar

Level 1
Hi Yuhui, Thanks a lot for confirming!