This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Updates: | |
totals | |
{ 'b' } | |
tracks | |
{ 't', 'b', 'u' } # This is theoretically irrelevant | |
# because track links 1-to-1 to user | |
{ 't', 'b' } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Updates: | |
totals | |
{ 'b' } | |
tracks | |
{ 't', 'b', 'u' } # This is theoretically irrelevant | |
# because track links 1-to-1 to user | |
{ 't', 'b' } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Indexes for [apps/track] | |
_id_ | |
t_1 | |
t_-1_b_-1_v_-1_c_-1 | |
t_-1_b_-1_v_-1_d_-1 | |
t_-1_b_-1_v_-1_f_-1 | |
t_-1_b_-1_v_-1_p_-1 | |
Indexes for [apps/track/slim] | |
_id_ | |
t_1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if exists?(referrer = event[:referrer]) | |
if ((matches = referrer.match(/([^\#]+)\#(.+)?\:(.+)?/))) && matches.size == 4 | |
detail = "#{DETAILS}.#{escape(matches[2])}.#{escape(matches[3])}.#{PLAYS}" | |
# Here we split the stuff in the specialised referrer | |
# i.e. facebook.com#p:AwsomePage | |
# And we increment the detail below, but in the REFERRER for the update | |
# referrer is passed instead of matches[1] ( which is just the facebook.com ) | |
buckets.each do |bucket| | |
@referrers_per_track.update({ TRACK => track_id, BUCKET => bucket, REFERRER => referrer }, { | |
'$inc' => { |
NewerOlder