snowplow / enrich

Snowplow Enrichment jobs and library
https://snowplowanalytics.com
Other
21 stars 39 forks source link

Common: placeholder for extracting client-side cookie in enrichment #66

Open chuwy opened 4 years ago

chuwy commented 4 years ago

A Snowplow user writes:

With the pixel tracker - why is it not possible to collect the cookie data set in the client browser (if exists) with the pixel request or even a collector redirect url. For example if I have a user on www.acme.co.uk who has a cookie set to acme.co.uk, can we not have a pixel tracker link with a CNAME collector.acme.co.uk url that then is able to read the cookie data and feed it into the event stream ?

This is a good point - at the moment the JavaScript Tracker-set cookie (duid) and the collector-set cookie (nuid) are kept very separate, but yes, if your sub-domains and cookie paths are set up correctly, it should theoretically be possible for a collector to read the nuid and re-attach that to the event.

Note that this would work well with the Scala Stream Collector, which already records all headers (including all cookies), so we could write a new enrichment to extract the domain_userid etc from the cookie in Hadoop/Stream Enrich.

chuwy commented 4 years ago

Migrated from https://github.com/snowplow/snowplow/issues/3088 (comments are auto-generated)