Advertisement
NLinker

JobTemplate json

Nov 1st, 2013
189
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. {
  2.    "jtmId":0,
  3.    "name":"DLX",
  4.    "source":{
  5.       "srcId":0,
  6.       "name":"Vertica at Staging",
  7.       "extractor":"File:DLX",
  8.       "driver":"com.vertica.jdbc.Driver",
  9.       "url":"C:\Temp\results.txt",
  10.       "username":"test",
  11.       "password":"test"
  12.    },
  13.    "destination":{
  14.       "destId":0,
  15.       "name":"My S3 bucket",
  16.       "url":"https://net_thumbtack_tapad.s3.amazonaws.com/",
  17.       "username":"",
  18.       "password":"",
  19.       "accessKey":"AKIAJBGTAIDUK7C6BIQA",
  20.       "secretKey":"3KX9geqbq6I7PIGkAtnOCHgxMZJAKpxhwC0DQ5w9",
  21.    },
  22.    "schedule":{
  23.       "schedule":"0 0 12 ? * MON *"
  24.    },
  25.    "processingData":{
  26.       "fileNameTemplate":"tapad-${fireTime?time}-${desc}.txt",
  27.       "fileType":"TSV"
  28.       "extractor":"File:DLX",
  29.       "extractionSQL":"\nselect\n  device_id,\n  campaign_id,\n  date,\n  creative_id,\n  campaign_id,\n  device_id,\n  inventory_type,\n  platform_id,\n  sum(impressions) as impressions,\n  sum(clicks) as clicks\nfrom (\nselect\n  device_id as shared_id,\n  campaign_id,\n  date(created_at) as date,\n  creative_id,\n  campaign_id as segment_id,\n  case when action_id = 'impression' then 1 else 0 end as impressions,\n  case when action_id = 'click' then 1 else 0 end as clicks,\n  device_id,\n  1 as inventory_type,\n  platform_id\nfrom taps\nwhere campaign_id = ${campaign_id} and date(created_at) = date('${fireTime?date}')\n) tt\ngroup by 1, 2, 3, 4, 5, 6, 7, 8 order by date desc;\n    ",
  30.       "additionalData":"{campaign_id=\"1537\",date=\"2013-10-10\"}",
  31.       "template":{
  32.          "header":"campaign_id\tdate\tdevice_id\tcreative_id\tinventory_type\tplatform_id\timpressions\tclicks",
  33.          "footer":"---footer---",
  34.          "row":"${campaign_id}\t${date}\t${device_id}\t${creative_id}\t${inventory_type}\t${platform_id}\t${impressions}\t${clicks}"
  35.       }
  36.    }
  37. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement