![]() One of the (many, many) beautiful things about Splunk is that you can emulate the traditional client-side tracking offered by off-the-shelf analytics tools, but without the limits imposed by those tools. The ideal is to have both client-side and server-side tracking in the same package. In other words, if you have a power user that is clicking all around your site, your analytics tool may eventually stop tracking that session. In some cases, youâre limited by the number of characters you can include in your call, and youâre limited by the number of events per user in a given time period. The down side is that your client-side tagging is beholden to your analytics toolâs limits. So, the upside of client-side tracking is that you can track any interaction. This means that in order to use those products, you must pepper your site with javascript code that - when triggered by a page load, mouse over, or mouse click - âphone homeâ to tell the analytics tool that a user loaded, clicked, or moused over something. Most of the current roster - like Google Analytics, Omniture Site Catalyst, and WebTrends - are client-side and typically rely on âtaggingâ. Great (client-side) taste! Less (server-side) filling! In the history of web analytics, analytics tools have evolved from client-side to server-side and back again. Those are client-side interactions that didnât require the page to reload and therefore are lost to the analytical ages, unless you have a way to capture those actions. For example, you could âmouse overâ the list of categories on the right nav or toggle the Tag list between âListâ and âCloudâ. However, there are some interactions you can have with this page that wonât show up in the logs. Youâve loaded this page and that action has been recorded in the apache server log, also known as server-side. What is server-side and client-side? Letâs say youâre reading this on. This blog shows how you can send both server-side and client-side data to Splunk and have the best of both worlds. Those logs are useful, but in many cases they only provide half the picture. of our customers use Splunk to analyze their Web traffic simply by indexing their apache or IIS server logs. =/ (Yes autoRun is very strange but if you follow the rule of only ever having one, and always having it at the top, almost all of the strangeness goes away)Ä£) and thirdly, here's a slightly cleaner version of your JS function that you may find useful. With the autoRun="true" on the Search module, the very first push on page load doesn't hide the checkbox because nobody has pushed the TimeRangePicker's data downstream yet. IN this case you should move it up to the TimeRangePicker and not have any autoRun on the Search module. ![]() It actually tells any module "when the page loads, start pushing data to all downstream from this point", and as such it should always be up at the top of the hierarchy. You have an autoRun="True" but you've made a common mistake which is to put it on the Search module thinking it tells the Search module to run it's search. For the second you meant to check the getLatestTimeTerms not getEarliestTimeTerms.Ĭhanging that alone gets it to mostly work.Ä¢) There is also a second lesser problem though. Now the checkbox goes away as soon as I change the time range and never comes back regardless of the setting.Ä¡) The main problem is that your if statement is only firing if the earliest time term is and also the earliest time term is "now". If & this.getContext().get("search").getTimeRange().getEarliestTimeTerms()="now")Īnd yes, I rebooted splunkweb to make sure application.js has been read by splunk after my change.Ä®DIT: I just found 2 errors, thanks to google developper tools.Ä¡- there was a brace missing in my javascript.Ä¢- I needed to get the context from "this". Var methodReference = (checkBoxModule) ĬheckBoxModule.onContextChange = function() ("LRO_ShowAutoRefreshCheckBox", function(checkBoxModule) ![]() But it's all there.Īnd here is the code I added in application.js: OK the code looks partly marked as code partly as regular comments. Index=os * | rex 'lvn-(?)-' | dedup Line | table Line | sort Lineįor 5 mins auto-refresh select the "Last 60 minutes" time range. It should only be visible when the user selects "Last 60 minutes" in the TimeRangePicker. The checkbox remains visible regardless of the time range I select. ![]() I wrote the code below after looking at many examples, and reviewing the modules documentation.Īnd yet, I can't get it to work.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |