Comments (4)
- boomerang does actually work for single page apps. You use the
requestStart
andresponseEnd
methods to time in-page user events.
For example, when the action is initiated by the user, you would call this:
if (typeof BOOMR !== "undefined") {
var timer = BOOMR.requestStart("some-tag-name");
}
Then, when the action is completed, you will call this code:
if (timer) {
timer.loaded();
}
which will cause a beacon to be fired.
-
you're right that the default version of boomerang does not do this, however we've been experimenting for some time now with tying actions to a session and if there's interest, I can merge this into the primary product.
-
If the child iframe is also instrumented with boomerang, then should get a separate beacon from the iframe. If not, then you could still use the API as mentioned in (1) to measure from click to iframe.onload/onerror (although I've had mixed success with whether an iframe's onload event will fire or not, and when).
-
This is true. There's no way to tell from JavaScript (or even from within the browser) when everything has been drawn to screen. What generally happens is that the browser will execute JavaScript, and send rendering information to the GPU (or video memory), and at that point it's a black box. There is no feedback on when those bytes make it to the display device. The best that we can do is measure when JavaScript has finished executing, which again means instrumenting using the API mentioned in (1) since this would be different for different sites.
-
I can see how this would be useful, and it's doable via the API, but I think it could be made better. Perhaps if we capture clicks on buttons as well and automatically add meta data about that button to the beacon.
One question I do have is, are you okay with firing a beacon on every action (this is more reliable), or would you prefer if beacons were batched and sent periodically (this is likely to fail if the user closes the page).
from boomerang.
- boomerang does actually work for single page apps.
For example, when the action is initiated by the user, you would call this:
1.1) I am not sure this is often the case. I expect most of the applications are written without boomerang in mind. In other words, if you "just add boomerang" to the existing app, it does not "just work".
You know, there are some signs of notion of the url of the link / form. However it is very limited and it is not extensible.
Then, when the action is completed, you will call this code:
1.2) Sometimes the action is completed in a different module. For instance, "shop" button in a Customer Summary module starts the interation, and the interaction completes in the Shopping module. You might have hard time passing boomr variables between development teams.
however we've been experimenting for some time now with tying actions to a session and if there's interest, I can merge this into the primary product.
I am going to refine my set of plugins (I do not support multiframe pages very well yet), and I do not find requestStart API, RT plugin, etc boomerang API very useful for that purpose.
I am interested if there is some generic solution. For now I have nothing to contribute to RT plugin as it just does not suit me.
- If the child iframe is also instrumented with boomerang, then should get a separate beacon from the iframe. If not, then you could still use the API as mentioned in (1) to measure from click to iframe.onload/onerror (although I've had mixed success with whether an iframe's onload event will fire or not, and when).
My aim is to have a single beacon for a single user interaction. Sub-beacons are fine (as in "nice to have") provided there is a global notion of the overall event. I do not want to develop extended log processing tools that will use artificial intelligence to deduce which beacons should be combined to get the response time of a "shop" button. I just want to see it as a single entry.
Boomerang does not track/capture page rendering activities.
This is true. There's no way to tell from JavaScript (or even from within the browser) when everything has been drawn to screen.
You tell a bit different story. I mean: boomerang could do much better job for capturing paint/document mutation events. MutationObserver, requestAnimationFrame, and setTimeout can detect document mutations (and paintings) quite well.
The best that we can do is measure when JavaScript has finished executing
This is false. See above.
- and it's doable via the API, but I think it could be made better.
The extensibility part of RT plugin is a bit poor.
One question I do have is, are you okay with firing a beacon on every action (this is more reliable), or would you prefer if beacons were batched and sent periodically (this is likely to fail if the user closes the page).
Currently I fire a beacon for each click. The clickstream is not high as I am running the load tests: real browsers, Selenium, limited set of load boxes.
Beacon batching is "nice to have", however I believe the primary goal is to capture the required information. The batching can be added afterwards.
sent periodically (this is likely to fail if the user closes the page)
For instance, when performing a load test, you control the environment and the load script just does not close the window unexpectedly.
localStorage
can be used to buffer beacons, so they get sent after user reconnects.
from boomerang.
1.1) I am not sure this is often the case. I expect most of the applications are written without
boomerang in mind. In other words, if you "just add boomerang" to the existing app, it does not "just
work".You know, there are some signs of notion of the url of the link / form. However it is very limited and it
is not extensible.
Boomerang (in my opinion) has been kept and designed in a general purpose way in order to meet the needs of a broader user base. Of course if you want to do more involved things with boomerang you will have to put effort into it. If you are planning to implement metrics and analysis into a internal tool on an enterprise-scale, yes you will have to reach consensus across teams to get where you want to go.
Vanilla Boomerang is not a stop-gap measure or drop-in replacement for Google-Analytics. You will need to integrate it properly if you want to have a enhanced look into your application.
1.2) Sometimes the action is completed in a different module. For instance, "shop" button in a Customer Summary module starts the interation, and the interaction completes in the Shopping module. You might have hard time passing boomr variables between development teams.
This again comes down to team-collaboration and communication across teams. If you are from the engineering or analytics/metrics team and want to have data from a specific teams module you will have to communicate that.
However if we're talking about an SPA it should not be as problematic as one might think as most of Boomerang and here specifically the BOOMR
Object is hooked into the window object of the browser.
This way accessing variables,subscriptions,events,functions of the BOOMR
Object can be accessed by any of the modules.
Functionality to measure specific non-DOM-Element related events is not yet implemented in boomerang but I'd like to suggest this as a new feature for the future:
@bluesmoon How about letting users add subscribable events to boomerang using BOOMR.utils
?
i.e:
BOOMR.utils.addCustomEvent({
"object_change" : function(data) {
console.log("Event triggered: ", data);
}
});
Where addCustomEvent()
would append "object_change"
to impl.events
and push the function onto the stack of events subscribed.
That way more subscriptions can be added with:
BOOMR.subscribe("object_change",function() { /* foo bar baz */});
If you want I can see if I can implement this?
You tell a bit different story. I mean: boomerang could do much better job for capturing
paint/document mutation events. MutationObserver, requestAnimationFrame, and setTimeout can
detect document mutations (and paintings) quite well.
...
My aim is to have a single beacon for a single user interaction. Sub-beacons are fine (as in "nice to have") provided there is a global notion of the overall event. I do not want to develop extended log processing tools that will use artificial intelligence to deduce which beacons should be combined to get the response time of a "shop" button. I just want to see it as a single entry.
I'll have to agree that the wording of the boomerang documentation isn't necessarily the best in that regard. Boomerang is (by design and mechanics) mostly focused on the timing aspects from the initial GET
Request of a page by a browser to the point where everything is rendered and the page_ready
event is fired. Everything else in between that is handled by plugins and the like. Boomerang itself is - as mentioned before - NOT a strict replacement for Google-Analytics. And yes one has to create your own data analysis for what boomerang sends back to the server.
Currently I fire a beacon for each click. The clickstream is not high as I am running the load tests: real browsers, Selenium, limited set of load boxes.
Beacon batching is "nice to have", however I believe the primary goal is to capture the required information. The batching can be added afterwards.
Rudimentary click-tracking has landed in bluesmoon/boomerang.git quite recently. Maybe you can check it out.
For instance, when performing a load test, you control the environment and the load script just does not close the window unexpectedly.
localStorage can be used to buffer beacons, so they get sent after user reconnects.
This goes with the assumption that theres only a limited set of very modern browsers. That too isn't always the case unless you know your environment. Boomerang tries to be as general in this regard as possible and work with most audiences (even those that run IE6)
from boomerang.
Thanks @vlsi for your feedback. Since there haven't been any additional comments on this issue, we're closing it for now.
Note SOASTA has contributed quite a bit of updates for monitoring SPAs in the spa
, angular
and other plugins. #68
from boomerang.
Related Issues (20)
- Which event should I subscribe to control header value? HOT 1
- Can we use Boomerang to send custom metrics/logs? HOT 1
- Bug: Trying to read metric from plugin that is undefined HOT 1
- How does the Cache-Reload Plugin works HOT 3
- API Key Disclosure HOT 2
- how about to move Plugins to webworker
- Integrate Plugins into asynchronous loader snippet HOT 5
- Continuity Visually Ready (c.tti.vr) gradually increased in Chromium 105 and 106 HOT 3
- What event should I subscribe to to know when the fetch is complete HOT 2
- t_done,t_page and rt.tt values are negative on SPA HOT 21
- Global collision issue HOT 2
- about web vital score HOT 1
- How to know user spent time on page HOT 6
- soft navigation not stop
- disable page unload beacon HOT 2
- Potential forced style layout HOT 5
- What is the use of the last_location function in spa plugin HOT 2
- SPA beacon is blocked if link href value is updated after soft navigation HOT 2
- Increment in TTI value for long task
- Critical vulnerabilities in the project HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from boomerang.