Results 1 to 2 of 2
- 02-22-2012, 10:51 PM #1Member
- Join Date
- Feb 2012
- Rep Power
Ads are served to users directly though their browsers. Depending on user interaction with the ad in a browser, different events may be appended to a log file (ads_out.txt). Log entries are in the following format:
userId = a 10 digit randomly assigned int value - this value should be consistent throughout the ad flow.
timestamp = GMT server time
The valid flow of an Ad is
1) A user requests an Ad and the Ad is displayed in the browser
2) User can either click on the Ad, or close the Ad
3) If a user clicks on the displayed Ad, they are redirected to a landing page with more details on the Ad
4) User can either click on links within the landing page or close the landing page
Events in Log file:
When an Ad is rendered to a user, event = 1
When a user clicks on a rendered Ad, event = 2
When a user clicks on an a link from an Ad landing page, event = 3
When a userId is provided that is not in proper format, event = 4
When an campaign is requested that is invalid, event = 5
Valid (supported) campaign values:
You can assume that event type 4 and 5 only happen when an ad is requested. The ad shouldn't display due to an error, so users won't be able to interact with the ad and no further events would be triggered.
Assume ads_out.txt is served on an external server.
To interact with the ads service, the following url can be used (this url doesn't actually exist):
I wanted to write a code to validate the logging of events in the text file work as intended.
- 02-22-2012, 11:25 PM #2
- By radhi16 in forum New To JavaReplies: 2Last Post: 01-27-2011, 04:44 PM
- By S-NESH in forum New To JavaReplies: 2Last Post: 12-13-2010, 01:32 PM
- By necro-1000 in forum AWT / SwingReplies: 2Last Post: 01-12-2008, 11:37 AM
- By pks in forum New To JavaReplies: 1Last Post: 01-09-2008, 12:07 AM
- By dirtycash in forum New To JavaReplies: 3Last Post: 12-03-2007, 09:17 PM