[{"data":1,"prerenderedAt":1596},["ShallowReactive",2],{"article-alternates":3,"article-\u002Fit\u002Fdata\u002Fgtm-lato-server-conversion-api-produzione":13},{"i18nKey":4,"paths":5},"data-001-2026-07",{"de":6,"en":7,"es":8,"fr":9,"it":10,"ru":11,"tr":12},"\u002Fde\u002Fdata\u002Fserver-side-gtm-conversion-api-production","\u002Fen\u002Fdata\u002Fserver-side-gtm-conversion-api-production-deployment","\u002Fes\u002Fdata\u002Fsgtm-conversion-api-produccion","\u002Ffr\u002Fdata\u002Fserveur-gtm-et-api-conversion-de-zero-a-production","\u002Fit\u002Fdata\u002Fserver-side-gtm-conversion-api-production","\u002Fru\u002Fdata\u002Fsgtm-conversion-api-production","\u002Ftr\u002Fdata\u002Fserver-side-gtm-ve-conversion-api-sifirdan-productiona",{"_path":14,"_dir":15,"_draft":16,"_partial":16,"_locale":17,"title":18,"description":19,"publishedAt":20,"modifiedAt":20,"category":15,"i18nKey":4,"tags":21,"readingTime":27,"author":28,"body":29,"_type":1590,"_id":1591,"_source":1592,"_file":1593,"_stem":1594,"_extension":1595},"\u002Fit\u002Fdata\u002Fgtm-lato-server-conversion-api-produzione","data",false,"","Server-Side GTM e Conversion API: Da Zero a Production","Guida tecnica per deployare un container GTM server-side su Cloud Run o Workers, configurare la deduplication con Conversion API e progettare il monitoring production-ready.","2026-07-14",[22,23,24,25,26],"server-side-gtm","conversion-api","cloud-run","deduplication","privacy-sandbox",9,"Roibase",{"type":30,"children":31,"toc":1576},"root",[32,40,47,52,79,84,91,105,279,290,319,325,330,358,567,580,600,606,626,796,828,834,839,851,1222,1234,1240,1245,1332,1337,1342,1348,1361,1429,1463,1469,1474,1479,1485,1490,1565,1570],{"type":33,"tag":34,"props":35,"children":36},"element","p",{},[37],{"type":38,"value":39},"text","La misurazione basata su cookie non è più opzionale — Safari, Firefox e il blocco completo dei cookie di terze parti in Chrome nel 2025 rendono l'architettura first-party data obbligatoria. L'invio di eventi server-side tramite Google Analytics 4 e Meta Conversion API è il fondamento di questa nuova era. Ma c'è una distanza significativa tra \"abbiamo deplorato GTM server-side\" e \"funziona affidabilmente in production\": deployment del container, deduplication degli eventi, load balancing, gestione degli errori e ottimizzazione dei costi. In questo articolo costruiremo da zero una setup server-side GTM production-grade su Cloud Run o Cloudflare Workers.",{"type":33,"tag":41,"props":42,"children":44},"h2",{"id":43},"anatomia-di-server-side-gtm-container-tagging-server-e-client",[45],{"type":38,"value":46},"Anatomia di Server-Side GTM: Container, Tagging Server e Client",{"type":33,"tag":34,"props":48,"children":49},{},[50],{"type":38,"value":51},"Google Tag Manager server-side ha un'architettura sostanzialmente diversa dal GTM classico. Lo snippet JavaScript lato client esegue un semplice \"data layer push\", ma il lavoro pesante — inviare richieste alle API di terze parti, leggere cookie, enrichire dati — viene delegato a un container backend. Questo container viene distribuito come immagine Docker ed eseguito su Google Cloud Run, AWS Fargate o Cloudflare Workers.",{"type":33,"tag":34,"props":53,"children":54},{},[55,57,63,65,70,72,77],{"type":38,"value":56},"L'architettura si compone di tre livelli. Il primo è il ",{"type":33,"tag":58,"props":59,"children":60},"strong",{},[61],{"type":38,"value":62},"browser web",{"type":38,"value":64},": la libreria gtag.js o gtm.js invia un payload minimo (client_id, event_name, timestamp) tramite HTTP POST al server. Il secondo è il ",{"type":33,"tag":58,"props":66,"children":67},{},[68],{"type":38,"value":69},"tagging server",{"type":38,"value":71},": un container GTM basato su Node.js in esecuzione su un pod Cloud Run riceve il POST, attiva i tag nel workspace GTM (GA4, Meta CAPI, TikTok Events API) e inoltra ciascuno come richiesta HTTP parallela alle API delle piattaforme. Il terzo livello è rappresentato dalle ",{"type":33,"tag":58,"props":73,"children":74},{},[75],{"type":38,"value":76},"piattaforme di destinazione",{"type":38,"value":78},": Google Analytics Measurement Protocol, Meta Graph API, e altri. Server-side GTM funge da proxy tra questi livelli e contemporaneamente implementa logica di enrichment, filtrazione e deduplication.",{"type":33,"tag":34,"props":80,"children":81},{},[82],{"type":38,"value":83},"Nel GTM classico, ogni tag carica uno snippet JavaScript separato nella pagina web; 10 tag equivalgono a 10 richieste esterne, la pagina rallenta. Con l'approccio server-side, il browser invia una sola richiesta alla propria infrastruttura e le 10 richieste rimanenti vengono elaborate in parallelo nel backend. L'esperienza utente migliora, gli adblocker vengono agirati, la durata dei cookie first-party si allunga (i problemi SameSite=None scompaiono). Tuttavia, questa configurazione introduce costi aggiuntivi: ogni hit richiede un'invocazione Cloud Run, servizi di geolocalizzazione basati su IP, archiviazione log. Gestire correttamente questo trade-off determina il successo della soluzione in produzione.",{"type":33,"tag":85,"props":86,"children":88},"h3",{"id":87},"deploy-su-cloud-run-dockerfile-e-configurazione",[89],{"type":38,"value":90},"Deploy su Cloud Run: Dockerfile e Configurazione",{"type":33,"tag":34,"props":92,"children":93},{},[94,96,103],{"type":38,"value":95},"Potete utilizzare l'immagine ufficiale di Google ",{"type":33,"tag":97,"props":98,"children":100},"code",{"className":99},[],[101],{"type":38,"value":102},"gcr.io\u002Fcloud-tagging-10302018\u002Fgtm-cloud-image",{"type":38,"value":104},". In alternativa, create un Dockerfile personalizzato aggiungendo middleware custom (ad esempio blacklist IP, rate limiting). Deployment minimo su Cloud Run:",{"type":33,"tag":106,"props":107,"children":111},"pre",{"className":108,"code":109,"language":110,"meta":17,"style":17},"language-bash shiki shiki-themes github-dark","gcloud run deploy gtm-server \\\n  --image=gcr.io\u002Fcloud-tagging-10302018\u002Fgtm-cloud-image:stable \\\n  --platform=managed \\\n  --region=europe-west1 \\\n  --allow-unauthenticated \\\n  --set-env-vars=\"CONTAINER_CONFIG=\u003Cbase64_config>\" \\\n  --min-instances=1 \\\n  --max-instances=10 \\\n  --cpu=1 \\\n  --memory=512Mi \\\n  --concurrency=80\n","bash",[112],{"type":33,"tag":97,"props":113,"children":114},{"__ignoreMap":17},[115,149,162,175,188,201,219,232,245,257,270],{"type":33,"tag":116,"props":117,"children":120},"span",{"class":118,"line":119},"line",1,[121,127,133,138,143],{"type":33,"tag":116,"props":122,"children":124},{"style":123},"--shiki-default:#B392F0",[125],{"type":38,"value":126},"gcloud",{"type":33,"tag":116,"props":128,"children":130},{"style":129},"--shiki-default:#9ECBFF",[131],{"type":38,"value":132}," run",{"type":33,"tag":116,"props":134,"children":135},{"style":129},[136],{"type":38,"value":137}," deploy",{"type":33,"tag":116,"props":139,"children":140},{"style":129},[141],{"type":38,"value":142}," gtm-server",{"type":33,"tag":116,"props":144,"children":146},{"style":145},"--shiki-default:#79B8FF",[147],{"type":38,"value":148}," \\\n",{"type":33,"tag":116,"props":150,"children":152},{"class":118,"line":151},2,[153,158],{"type":33,"tag":116,"props":154,"children":155},{"style":145},[156],{"type":38,"value":157},"  --image=gcr.io\u002Fcloud-tagging-10302018\u002Fgtm-cloud-image:stable",{"type":33,"tag":116,"props":159,"children":160},{"style":145},[161],{"type":38,"value":148},{"type":33,"tag":116,"props":163,"children":165},{"class":118,"line":164},3,[166,171],{"type":33,"tag":116,"props":167,"children":168},{"style":145},[169],{"type":38,"value":170},"  --platform=managed",{"type":33,"tag":116,"props":172,"children":173},{"style":145},[174],{"type":38,"value":148},{"type":33,"tag":116,"props":176,"children":178},{"class":118,"line":177},4,[179,184],{"type":33,"tag":116,"props":180,"children":181},{"style":145},[182],{"type":38,"value":183},"  --region=europe-west1",{"type":33,"tag":116,"props":185,"children":186},{"style":145},[187],{"type":38,"value":148},{"type":33,"tag":116,"props":189,"children":191},{"class":118,"line":190},5,[192,197],{"type":33,"tag":116,"props":193,"children":194},{"style":145},[195],{"type":38,"value":196},"  --allow-unauthenticated",{"type":33,"tag":116,"props":198,"children":199},{"style":145},[200],{"type":38,"value":148},{"type":33,"tag":116,"props":202,"children":204},{"class":118,"line":203},6,[205,210,215],{"type":33,"tag":116,"props":206,"children":207},{"style":145},[208],{"type":38,"value":209},"  --set-env-vars=",{"type":33,"tag":116,"props":211,"children":212},{"style":129},[213],{"type":38,"value":214},"\"CONTAINER_CONFIG=\u003Cbase64_config>\"",{"type":33,"tag":116,"props":216,"children":217},{"style":145},[218],{"type":38,"value":148},{"type":33,"tag":116,"props":220,"children":222},{"class":118,"line":221},7,[223,228],{"type":33,"tag":116,"props":224,"children":225},{"style":145},[226],{"type":38,"value":227},"  --min-instances=1",{"type":33,"tag":116,"props":229,"children":230},{"style":145},[231],{"type":38,"value":148},{"type":33,"tag":116,"props":233,"children":235},{"class":118,"line":234},8,[236,241],{"type":33,"tag":116,"props":237,"children":238},{"style":145},[239],{"type":38,"value":240},"  --max-instances=10",{"type":33,"tag":116,"props":242,"children":243},{"style":145},[244],{"type":38,"value":148},{"type":33,"tag":116,"props":246,"children":247},{"class":118,"line":27},[248,253],{"type":33,"tag":116,"props":249,"children":250},{"style":145},[251],{"type":38,"value":252},"  --cpu=1",{"type":33,"tag":116,"props":254,"children":255},{"style":145},[256],{"type":38,"value":148},{"type":33,"tag":116,"props":258,"children":260},{"class":118,"line":259},10,[261,266],{"type":33,"tag":116,"props":262,"children":263},{"style":145},[264],{"type":38,"value":265},"  --memory=512Mi",{"type":33,"tag":116,"props":267,"children":268},{"style":145},[269],{"type":38,"value":148},{"type":33,"tag":116,"props":271,"children":273},{"class":118,"line":272},11,[274],{"type":33,"tag":116,"props":275,"children":276},{"style":145},[277],{"type":38,"value":278},"  --concurrency=80\n",{"type":33,"tag":34,"props":280,"children":281},{},[282,288],{"type":33,"tag":97,"props":283,"children":285},{"className":284},[],[286],{"type":38,"value":287},"CONTAINER_CONFIG",{"type":38,"value":289}," codifica in base64 il JSON esportato dal container server del vostro workspace GTM. Questa configurazione definisce quali tag attivare in base ai trigger, come popolare le variabili e così via. In produzione, archiviate questa configurazione in Cloud Secret Manager — una variabile d'ambiente in testo semplice è una vulnerabilità di sicurezza.",{"type":33,"tag":34,"props":291,"children":292},{},[293,295,301,303,309,311,317],{"type":38,"value":294},"Garantite il comportamento dell'auto-scaling di Cloud Run con ",{"type":33,"tag":97,"props":296,"children":298},{"className":297},[],[299],{"type":38,"value":300},"--min-instances=1",{"type":38,"value":302},". Se ",{"type":33,"tag":97,"props":304,"children":306},{"className":305},[],[307],{"type":38,"value":308},"min-instances=0",{"type":38,"value":310},", il primo hit subisce uno \"cold start\" (1-3 secondi); durante questo periodo il rischio di perdita di eventi è alto. Mantenere sempre 1 istanza attiva costa circa $10 al mese ma previene la perdita di eventi critici. ",{"type":33,"tag":97,"props":312,"children":314},{"className":313},[],[315],{"type":38,"value":316},"--concurrency=80",{"type":38,"value":318}," indica che un singolo pod può gestire 80 richieste parallele; calibrate questo numero tramite test di carico (concurrency elevata consuma memoria, concurrency bassa causa scaling non necessario).",{"type":33,"tag":41,"props":320,"children":322},{"id":321},"integrazione-conversion-api-meta-tiktok-e-deduplication",[323],{"type":38,"value":324},"Integrazione Conversion API: Meta, TikTok e Deduplication",{"type":33,"tag":34,"props":326,"children":327},{},[328],{"type":38,"value":329},"Lo scenario d'uso più critico di server-side GTM è il supporto di Meta Conversion API (CAPI) e TikTok Events API insieme ai pixel browser. Inviando lo stesso evento attraverso entrambi i canali, raggiungete il 100% del segnale: se il pixel mobile in iOS fallisce per ATT consent, l'evento server-side lo recupera; se i dati IP lato server sono incompleti, l'user agent del browser li integra. Tuttavia, inviare lo stesso evento due volte compromette l'attribution — la deduplication è obbligatoria.",{"type":33,"tag":34,"props":331,"children":332},{},[333,335,341,343,348,350,356],{"type":38,"value":334},"Meta CAPI prevede un campo ",{"type":33,"tag":97,"props":336,"children":338},{"className":337},[],[339],{"type":38,"value":340},"event_id",{"type":38,"value":342}," in ogni payload di evento. Se Meta riceve la stessa combinazione di ",{"type":33,"tag":97,"props":344,"children":346},{"className":345},[],[347],{"type":38,"value":340},{"type":38,"value":349}," + ",{"type":33,"tag":97,"props":351,"children":353},{"className":352},[],[354],{"type":38,"value":355},"event_name",{"type":38,"value":357}," una seconda volta entro 48 ore, applica automaticamente la deduplication. Implementazione semplice: quando il pixel lato client attiva un evento, generate un UUID e inviatelo sia al pixel che a server-side GTM.",{"type":33,"tag":106,"props":359,"children":363},{"className":360,"code":361,"language":362,"meta":17,"style":17},"language-javascript shiki shiki-themes github-dark","\u002F\u002F Client-side (web GTM o gtag.js)\nconst eventId = crypto.randomUUID(); \u002F\u002F UUID del browser\nfbq('track', 'Purchase', { value: 99.90, currency: 'USD' }, { eventID: eventId });\n\n\u002F\u002F Inviate lo stesso eventId a server-side GTM tramite data layer\ndataLayer.push({\n  event: 'purchase',\n  event_id: eventId,\n  value: 99.90,\n  currency: 'USD'\n});\n","javascript",[364],{"type":33,"tag":97,"props":365,"children":366},{"__ignoreMap":17},[367,376,416,469,478,486,504,522,530,546,559],{"type":33,"tag":116,"props":368,"children":369},{"class":118,"line":119},[370],{"type":33,"tag":116,"props":371,"children":373},{"style":372},"--shiki-default:#6A737D",[374],{"type":38,"value":375},"\u002F\u002F Client-side (web GTM o gtag.js)\n",{"type":33,"tag":116,"props":377,"children":378},{"class":118,"line":151},[379,385,390,395,401,406,411],{"type":33,"tag":116,"props":380,"children":382},{"style":381},"--shiki-default:#F97583",[383],{"type":38,"value":384},"const",{"type":33,"tag":116,"props":386,"children":387},{"style":145},[388],{"type":38,"value":389}," eventId",{"type":33,"tag":116,"props":391,"children":392},{"style":381},[393],{"type":38,"value":394}," =",{"type":33,"tag":116,"props":396,"children":398},{"style":397},"--shiki-default:#E1E4E8",[399],{"type":38,"value":400}," crypto.",{"type":33,"tag":116,"props":402,"children":403},{"style":123},[404],{"type":38,"value":405},"randomUUID",{"type":33,"tag":116,"props":407,"children":408},{"style":397},[409],{"type":38,"value":410},"(); ",{"type":33,"tag":116,"props":412,"children":413},{"style":372},[414],{"type":38,"value":415},"\u002F\u002F UUID del browser\n",{"type":33,"tag":116,"props":417,"children":418},{"class":118,"line":164},[419,424,429,434,439,444,449,454,459,464],{"type":33,"tag":116,"props":420,"children":421},{"style":123},[422],{"type":38,"value":423},"fbq",{"type":33,"tag":116,"props":425,"children":426},{"style":397},[427],{"type":38,"value":428},"(",{"type":33,"tag":116,"props":430,"children":431},{"style":129},[432],{"type":38,"value":433},"'track'",{"type":33,"tag":116,"props":435,"children":436},{"style":397},[437],{"type":38,"value":438},", ",{"type":33,"tag":116,"props":440,"children":441},{"style":129},[442],{"type":38,"value":443},"'Purchase'",{"type":33,"tag":116,"props":445,"children":446},{"style":397},[447],{"type":38,"value":448},", { value: ",{"type":33,"tag":116,"props":450,"children":451},{"style":145},[452],{"type":38,"value":453},"99.90",{"type":33,"tag":116,"props":455,"children":456},{"style":397},[457],{"type":38,"value":458},", currency: ",{"type":33,"tag":116,"props":460,"children":461},{"style":129},[462],{"type":38,"value":463},"'USD'",{"type":33,"tag":116,"props":465,"children":466},{"style":397},[467],{"type":38,"value":468}," }, { eventID: eventId });\n",{"type":33,"tag":116,"props":470,"children":471},{"class":118,"line":177},[472],{"type":33,"tag":116,"props":473,"children":475},{"emptyLinePlaceholder":474},true,[476],{"type":38,"value":477},"\n",{"type":33,"tag":116,"props":479,"children":480},{"class":118,"line":190},[481],{"type":33,"tag":116,"props":482,"children":483},{"style":372},[484],{"type":38,"value":485},"\u002F\u002F Inviate lo stesso eventId a server-side GTM tramite data layer\n",{"type":33,"tag":116,"props":487,"children":488},{"class":118,"line":203},[489,494,499],{"type":33,"tag":116,"props":490,"children":491},{"style":397},[492],{"type":38,"value":493},"dataLayer.",{"type":33,"tag":116,"props":495,"children":496},{"style":123},[497],{"type":38,"value":498},"push",{"type":33,"tag":116,"props":500,"children":501},{"style":397},[502],{"type":38,"value":503},"({\n",{"type":33,"tag":116,"props":505,"children":506},{"class":118,"line":221},[507,512,517],{"type":33,"tag":116,"props":508,"children":509},{"style":397},[510],{"type":38,"value":511},"  event: ",{"type":33,"tag":116,"props":513,"children":514},{"style":129},[515],{"type":38,"value":516},"'purchase'",{"type":33,"tag":116,"props":518,"children":519},{"style":397},[520],{"type":38,"value":521},",\n",{"type":33,"tag":116,"props":523,"children":524},{"class":118,"line":234},[525],{"type":33,"tag":116,"props":526,"children":527},{"style":397},[528],{"type":38,"value":529},"  event_id: eventId,\n",{"type":33,"tag":116,"props":531,"children":532},{"class":118,"line":27},[533,538,542],{"type":33,"tag":116,"props":534,"children":535},{"style":397},[536],{"type":38,"value":537},"  value: ",{"type":33,"tag":116,"props":539,"children":540},{"style":145},[541],{"type":38,"value":453},{"type":33,"tag":116,"props":543,"children":544},{"style":397},[545],{"type":38,"value":521},{"type":33,"tag":116,"props":547,"children":548},{"class":118,"line":259},[549,554],{"type":33,"tag":116,"props":550,"children":551},{"style":397},[552],{"type":38,"value":553},"  currency: ",{"type":33,"tag":116,"props":555,"children":556},{"style":129},[557],{"type":38,"value":558},"'USD'\n",{"type":33,"tag":116,"props":560,"children":561},{"class":118,"line":272},[562],{"type":33,"tag":116,"props":563,"children":564},{"style":397},[565],{"type":38,"value":566},"});\n",{"type":33,"tag":34,"props":568,"children":569},{},[570,572,578],{"type":38,"value":571},"Nel tag Meta CAPI di server-side GTM, mappate la variabile \"Event ID\" a ",{"type":33,"tag":97,"props":573,"children":575},{"className":574},[],[576],{"type":38,"value":577},"{{event_id}}",{"type":38,"value":579},". In questo modo gli eventi browser e server si unificano. Nel dashboard Meta, sotto \"Events Manager > Diagnostics\", potete monitorare il tasso di deduplication (Match Quality). L'obiettivo è oltre l'80%.",{"type":33,"tag":34,"props":581,"children":582},{},[583,585,590,592,598],{"type":38,"value":584},"TikTok Events API utilizza una logica ",{"type":33,"tag":97,"props":586,"children":588},{"className":587},[],[589],{"type":38,"value":340},{"type":38,"value":591}," simile. Tuttavia, dovete trasportare il valore del cookie TikTok (",{"type":33,"tag":97,"props":593,"children":595},{"className":594},[],[596],{"type":38,"value":597},"_ttp",{"type":38,"value":599},") da lato client a lato server — il pixel client-side imposta il cookie, il tag server-side lo legge. Trasportate questo dato in un cookie first-party o nel corpo della richiesta POST. Se usate Cloudflare Workers, potete scrivere middleware edge che parsa i cookie e li inietta nel container GTM.",{"type":33,"tag":85,"props":601,"children":603},{"id":602},"tabella-di-deduplication-e-controllo-event-hash",[604],{"type":38,"value":605},"Tabella di Deduplication e Controllo Event Hash",{"type":33,"tag":34,"props":607,"children":608},{},[609,611,616,618,624],{"type":38,"value":610},"In scenari ad alto traffico, lo stesso utente potrebbe eseguire rapidamente due volte \"add to cart\" — gli eventi browser e server potrebbero arrivare nello stesso secondo con ",{"type":33,"tag":97,"props":612,"children":614},{"className":613},[],[615],{"type":38,"value":340},{"type":38,"value":617}," diversi. In questo caso è necessario un livello di deduplication esterno: create una tabella ",{"type":33,"tag":97,"props":619,"children":621},{"className":620},[],[622],{"type":38,"value":623},"event_hash",{"type":38,"value":625}," in BigQuery.",{"type":33,"tag":106,"props":627,"children":631},{"className":628,"code":629,"language":630,"meta":17,"style":17},"language-sql shiki shiki-themes github-dark","CREATE TABLE analytics.event_dedup (\n  event_hash STRING NOT NULL,\n  event_time TIMESTAMP NOT NULL,\n  user_id STRING,\n  event_name STRING\n)\nPARTITION BY DATE(event_time)\nCLUSTER BY event_hash\nOPTIONS (\n  partition_expiration_days = 7\n);\n","sql",[632],{"type":33,"tag":97,"props":633,"children":634},{"__ignoreMap":17},[635,658,675,697,705,713,721,744,762,770,788],{"type":33,"tag":116,"props":636,"children":637},{"class":118,"line":119},[638,643,648,653],{"type":33,"tag":116,"props":639,"children":640},{"style":381},[641],{"type":38,"value":642},"CREATE",{"type":33,"tag":116,"props":644,"children":645},{"style":381},[646],{"type":38,"value":647}," TABLE",{"type":33,"tag":116,"props":649,"children":650},{"style":123},[651],{"type":38,"value":652}," analytics",{"type":33,"tag":116,"props":654,"children":655},{"style":397},[656],{"type":38,"value":657},".event_dedup (\n",{"type":33,"tag":116,"props":659,"children":660},{"class":118,"line":151},[661,666,671],{"type":33,"tag":116,"props":662,"children":663},{"style":397},[664],{"type":38,"value":665},"  event_hash STRING ",{"type":33,"tag":116,"props":667,"children":668},{"style":381},[669],{"type":38,"value":670},"NOT NULL",{"type":33,"tag":116,"props":672,"children":673},{"style":397},[674],{"type":38,"value":521},{"type":33,"tag":116,"props":676,"children":677},{"class":118,"line":164},[678,683,688,693],{"type":33,"tag":116,"props":679,"children":680},{"style":397},[681],{"type":38,"value":682},"  event_time ",{"type":33,"tag":116,"props":684,"children":685},{"style":381},[686],{"type":38,"value":687},"TIMESTAMP",{"type":33,"tag":116,"props":689,"children":690},{"style":381},[691],{"type":38,"value":692}," NOT NULL",{"type":33,"tag":116,"props":694,"children":695},{"style":397},[696],{"type":38,"value":521},{"type":33,"tag":116,"props":698,"children":699},{"class":118,"line":177},[700],{"type":33,"tag":116,"props":701,"children":702},{"style":397},[703],{"type":38,"value":704},"  user_id STRING,\n",{"type":33,"tag":116,"props":706,"children":707},{"class":118,"line":190},[708],{"type":33,"tag":116,"props":709,"children":710},{"style":397},[711],{"type":38,"value":712},"  event_name STRING\n",{"type":33,"tag":116,"props":714,"children":715},{"class":118,"line":203},[716],{"type":33,"tag":116,"props":717,"children":718},{"style":397},[719],{"type":38,"value":720},")\n",{"type":33,"tag":116,"props":722,"children":723},{"class":118,"line":221},[724,729,734,739],{"type":33,"tag":116,"props":725,"children":726},{"style":381},[727],{"type":38,"value":728},"PARTITION",{"type":33,"tag":116,"props":730,"children":731},{"style":381},[732],{"type":38,"value":733}," BY",{"type":33,"tag":116,"props":735,"children":736},{"style":381},[737],{"type":38,"value":738}," DATE",{"type":33,"tag":116,"props":740,"children":741},{"style":397},[742],{"type":38,"value":743},"(event_time)\n",{"type":33,"tag":116,"props":745,"children":746},{"class":118,"line":234},[747,752,757],{"type":33,"tag":116,"props":748,"children":749},{"style":397},[750],{"type":38,"value":751},"CLUSTER ",{"type":33,"tag":116,"props":753,"children":754},{"style":381},[755],{"type":38,"value":756},"BY",{"type":33,"tag":116,"props":758,"children":759},{"style":397},[760],{"type":38,"value":761}," event_hash\n",{"type":33,"tag":116,"props":763,"children":764},{"class":118,"line":27},[765],{"type":33,"tag":116,"props":766,"children":767},{"style":397},[768],{"type":38,"value":769},"OPTIONS (\n",{"type":33,"tag":116,"props":771,"children":772},{"class":118,"line":259},[773,778,783],{"type":33,"tag":116,"props":774,"children":775},{"style":397},[776],{"type":38,"value":777},"  partition_expiration_days ",{"type":33,"tag":116,"props":779,"children":780},{"style":381},[781],{"type":38,"value":782},"=",{"type":33,"tag":116,"props":784,"children":785},{"style":145},[786],{"type":38,"value":787}," 7\n",{"type":33,"tag":116,"props":789,"children":790},{"class":118,"line":272},[791],{"type":33,"tag":116,"props":792,"children":793},{"style":397},[794],{"type":38,"value":795},");\n",{"type":33,"tag":34,"props":797,"children":798},{},[799,801,807,809,815,817,826],{"type":38,"value":800},"In server-side GTM, calcolate come variabile custom ",{"type":33,"tag":97,"props":802,"children":804},{"className":803},[],[805],{"type":38,"value":806},"SHA256(user_id + event_name + FLOOR(timestamp\u002F60))",{"type":38,"value":808},". Questo hash raggruppa lo stesso evento dello stesso utente entro una finestra di 1 minuto. Prima di attivare il tag, eseguite un controllo BigQuery: ",{"type":33,"tag":97,"props":810,"children":812},{"className":811},[],[813],{"type":38,"value":814},"SELECT COUNT(*) WHERE event_hash = {{computed_hash}}",{"type":38,"value":816},". Se esiste una riga, saltate il tag. Questo pattern, quando combinato con identity resolution all'interno di ",{"type":33,"tag":818,"props":819,"children":823},"a",{"href":820,"rel":821},"https:\u002F\u002Fwww.roibase.com.tr\u002Fit\u002Ffirstparty",[822],"nofollow",[824],{"type":38,"value":825},"architetture first-party data",{"type":38,"value":827},", crea un potente strato di controllo della qualità del segnale.",{"type":33,"tag":41,"props":829,"children":831},{"id":830},"load-balancing-gestione-degli-errori-e-strategia-di-retry",[832],{"type":38,"value":833},"Load Balancing, Gestione degli Errori e Strategia di Retry",{"type":33,"tag":34,"props":835,"children":836},{},[837],{"type":38,"value":838},"In produzione, una singola istanza Cloud Run non è sufficiente. Per distribuire il carico, utilizzate Cloud Load Balancer o un proxy Cloudflare. Cloud Load Balancer collega il backend Cloud Run tramite NEG (Network Endpoint Group), termina SSL, fornisce protezione DDoS. Cloudflare Workers può implementare rate limiting basato su IP con KV store — il traffico abuse viene bloccato prima di raggiungere il tagging server.",{"type":33,"tag":34,"props":840,"children":841},{},[842,844,849],{"type":38,"value":843},"La gestione degli errori avviene su due livelli. Il primo è il ",{"type":33,"tag":58,"props":845,"children":846},{},[847],{"type":38,"value":848},"livello dei tag GTM",{"type":38,"value":850},": quando un tag Meta CAPI restituisce un errore 5xx, dovrebbe riprovare automaticamente? GTM non ha retry nativo, ma potete implementare backoff esponenziale in un tag HTML custom:",{"type":33,"tag":106,"props":852,"children":854},{"className":360,"code":853,"language":362,"meta":17,"style":17},"async function sendWithRetry(url, payload, maxRetries = 3) {\n  for (let i = 0; i \u003C maxRetries; i++) {\n    const res = await fetch(url, { method: 'POST', body: JSON.stringify(payload) });\n    if (res.ok) return res;\n    if (res.status \u003C 500) break; \u002F\u002F Non ritentare su errori 4xx\n    await new Promise(r => setTimeout(r, 2 ** i * 1000)); \u002F\u002F 1s, 2s, 4s\n  }\n  throw new Error('Max retries exceeded');\n}\n",[855],{"type":33,"tag":97,"props":856,"children":857},{"__ignoreMap":17},[858,918,974,1036,1059,1100,1176,1184,1214],{"type":33,"tag":116,"props":859,"children":860},{"class":118,"line":119},[861,866,871,876,880,886,890,895,899,904,908,913],{"type":33,"tag":116,"props":862,"children":863},{"style":381},[864],{"type":38,"value":865},"async",{"type":33,"tag":116,"props":867,"children":868},{"style":381},[869],{"type":38,"value":870}," function",{"type":33,"tag":116,"props":872,"children":873},{"style":123},[874],{"type":38,"value":875}," sendWithRetry",{"type":33,"tag":116,"props":877,"children":878},{"style":397},[879],{"type":38,"value":428},{"type":33,"tag":116,"props":881,"children":883},{"style":882},"--shiki-default:#FFAB70",[884],{"type":38,"value":885},"url",{"type":33,"tag":116,"props":887,"children":888},{"style":397},[889],{"type":38,"value":438},{"type":33,"tag":116,"props":891,"children":892},{"style":882},[893],{"type":38,"value":894},"payload",{"type":33,"tag":116,"props":896,"children":897},{"style":397},[898],{"type":38,"value":438},{"type":33,"tag":116,"props":900,"children":901},{"style":882},[902],{"type":38,"value":903},"maxRetries",{"type":33,"tag":116,"props":905,"children":906},{"style":381},[907],{"type":38,"value":394},{"type":33,"tag":116,"props":909,"children":910},{"style":145},[911],{"type":38,"value":912}," 3",{"type":33,"tag":116,"props":914,"children":915},{"style":397},[916],{"type":38,"value":917},") {\n",{"type":33,"tag":116,"props":919,"children":920},{"class":118,"line":151},[921,926,931,936,941,945,950,955,960,965,970],{"type":33,"tag":116,"props":922,"children":923},{"style":381},[924],{"type":38,"value":925},"  for",{"type":33,"tag":116,"props":927,"children":928},{"style":397},[929],{"type":38,"value":930}," (",{"type":33,"tag":116,"props":932,"children":933},{"style":381},[934],{"type":38,"value":935},"let",{"type":33,"tag":116,"props":937,"children":938},{"style":397},[939],{"type":38,"value":940}," i ",{"type":33,"tag":116,"props":942,"children":943},{"style":381},[944],{"type":38,"value":782},{"type":33,"tag":116,"props":946,"children":947},{"style":145},[948],{"type":38,"value":949}," 0",{"type":33,"tag":116,"props":951,"children":952},{"style":397},[953],{"type":38,"value":954},"; i ",{"type":33,"tag":116,"props":956,"children":957},{"style":381},[958],{"type":38,"value":959},"\u003C",{"type":33,"tag":116,"props":961,"children":962},{"style":397},[963],{"type":38,"value":964}," maxRetries; i",{"type":33,"tag":116,"props":966,"children":967},{"style":381},[968],{"type":38,"value":969},"++",{"type":33,"tag":116,"props":971,"children":972},{"style":397},[973],{"type":38,"value":917},{"type":33,"tag":116,"props":975,"children":976},{"class":118,"line":164},[977,982,987,991,996,1001,1006,1011,1016,1021,1026,1031],{"type":33,"tag":116,"props":978,"children":979},{"style":381},[980],{"type":38,"value":981},"    const",{"type":33,"tag":116,"props":983,"children":984},{"style":145},[985],{"type":38,"value":986}," res",{"type":33,"tag":116,"props":988,"children":989},{"style":381},[990],{"type":38,"value":394},{"type":33,"tag":116,"props":992,"children":993},{"style":381},[994],{"type":38,"value":995}," await",{"type":33,"tag":116,"props":997,"children":998},{"style":123},[999],{"type":38,"value":1000}," fetch",{"type":33,"tag":116,"props":1002,"children":1003},{"style":397},[1004],{"type":38,"value":1005},"(url, { method: ",{"type":33,"tag":116,"props":1007,"children":1008},{"style":129},[1009],{"type":38,"value":1010},"'POST'",{"type":33,"tag":116,"props":1012,"children":1013},{"style":397},[1014],{"type":38,"value":1015},", body: ",{"type":33,"tag":116,"props":1017,"children":1018},{"style":145},[1019],{"type":38,"value":1020},"JSON",{"type":33,"tag":116,"props":1022,"children":1023},{"style":397},[1024],{"type":38,"value":1025},".",{"type":33,"tag":116,"props":1027,"children":1028},{"style":123},[1029],{"type":38,"value":1030},"stringify",{"type":33,"tag":116,"props":1032,"children":1033},{"style":397},[1034],{"type":38,"value":1035},"(payload) });\n",{"type":33,"tag":116,"props":1037,"children":1038},{"class":118,"line":177},[1039,1044,1049,1054],{"type":33,"tag":116,"props":1040,"children":1041},{"style":381},[1042],{"type":38,"value":1043},"    if",{"type":33,"tag":116,"props":1045,"children":1046},{"style":397},[1047],{"type":38,"value":1048}," (res.ok) ",{"type":33,"tag":116,"props":1050,"children":1051},{"style":381},[1052],{"type":38,"value":1053},"return",{"type":33,"tag":116,"props":1055,"children":1056},{"style":397},[1057],{"type":38,"value":1058}," res;\n",{"type":33,"tag":116,"props":1060,"children":1061},{"class":118,"line":190},[1062,1066,1071,1075,1080,1085,1090,1095],{"type":33,"tag":116,"props":1063,"children":1064},{"style":381},[1065],{"type":38,"value":1043},{"type":33,"tag":116,"props":1067,"children":1068},{"style":397},[1069],{"type":38,"value":1070}," (res.status ",{"type":33,"tag":116,"props":1072,"children":1073},{"style":381},[1074],{"type":38,"value":959},{"type":33,"tag":116,"props":1076,"children":1077},{"style":145},[1078],{"type":38,"value":1079}," 500",{"type":33,"tag":116,"props":1081,"children":1082},{"style":397},[1083],{"type":38,"value":1084},") ",{"type":33,"tag":116,"props":1086,"children":1087},{"style":381},[1088],{"type":38,"value":1089},"break",{"type":33,"tag":116,"props":1091,"children":1092},{"style":397},[1093],{"type":38,"value":1094},"; ",{"type":33,"tag":116,"props":1096,"children":1097},{"style":372},[1098],{"type":38,"value":1099},"\u002F\u002F Non ritentare su errori 4xx\n",{"type":33,"tag":116,"props":1101,"children":1102},{"class":118,"line":203},[1103,1108,1113,1118,1122,1127,1132,1137,1142,1147,1152,1156,1161,1166,1171],{"type":33,"tag":116,"props":1104,"children":1105},{"style":381},[1106],{"type":38,"value":1107},"    await",{"type":33,"tag":116,"props":1109,"children":1110},{"style":381},[1111],{"type":38,"value":1112}," new",{"type":33,"tag":116,"props":1114,"children":1115},{"style":145},[1116],{"type":38,"value":1117}," Promise",{"type":33,"tag":116,"props":1119,"children":1120},{"style":397},[1121],{"type":38,"value":428},{"type":33,"tag":116,"props":1123,"children":1124},{"style":882},[1125],{"type":38,"value":1126},"r",{"type":33,"tag":116,"props":1128,"children":1129},{"style":381},[1130],{"type":38,"value":1131}," =>",{"type":33,"tag":116,"props":1133,"children":1134},{"style":123},[1135],{"type":38,"value":1136}," setTimeout",{"type":33,"tag":116,"props":1138,"children":1139},{"style":397},[1140],{"type":38,"value":1141},"(r, ",{"type":33,"tag":116,"props":1143,"children":1144},{"style":145},[1145],{"type":38,"value":1146},"2",{"type":33,"tag":116,"props":1148,"children":1149},{"style":381},[1150],{"type":38,"value":1151}," **",{"type":33,"tag":116,"props":1153,"children":1154},{"style":397},[1155],{"type":38,"value":940},{"type":33,"tag":116,"props":1157,"children":1158},{"style":381},[1159],{"type":38,"value":1160},"*",{"type":33,"tag":116,"props":1162,"children":1163},{"style":145},[1164],{"type":38,"value":1165}," 1000",{"type":33,"tag":116,"props":1167,"children":1168},{"style":397},[1169],{"type":38,"value":1170},")); ",{"type":33,"tag":116,"props":1172,"children":1173},{"style":372},[1174],{"type":38,"value":1175},"\u002F\u002F 1s, 2s, 4s\n",{"type":33,"tag":116,"props":1177,"children":1178},{"class":118,"line":221},[1179],{"type":33,"tag":116,"props":1180,"children":1181},{"style":397},[1182],{"type":38,"value":1183},"  }\n",{"type":33,"tag":116,"props":1185,"children":1186},{"class":118,"line":234},[1187,1192,1196,1201,1205,1210],{"type":33,"tag":116,"props":1188,"children":1189},{"style":381},[1190],{"type":38,"value":1191},"  throw",{"type":33,"tag":116,"props":1193,"children":1194},{"style":381},[1195],{"type":38,"value":1112},{"type":33,"tag":116,"props":1197,"children":1198},{"style":123},[1199],{"type":38,"value":1200}," Error",{"type":33,"tag":116,"props":1202,"children":1203},{"style":397},[1204],{"type":38,"value":428},{"type":33,"tag":116,"props":1206,"children":1207},{"style":129},[1208],{"type":38,"value":1209},"'Max retries exceeded'",{"type":33,"tag":116,"props":1211,"children":1212},{"style":397},[1213],{"type":38,"value":795},{"type":33,"tag":116,"props":1215,"children":1216},{"class":118,"line":27},[1217],{"type":33,"tag":116,"props":1218,"children":1219},{"style":397},[1220],{"type":38,"value":1221},"}\n",{"type":33,"tag":34,"props":1223,"children":1224},{},[1225,1227,1232],{"type":38,"value":1226},"Il secondo livello è la ",{"type":33,"tag":58,"props":1228,"children":1229},{},[1230],{"type":38,"value":1231},"dead letter queue",{"type":38,"value":1233},": indirizzate gli errori 5xx nei log Cloud Run verso un topic Pub\u002FSub, e un worker pool di background ritenti questi eventi per 24 ore. Questo pattern riduce la perdita di eventi allo 0.01%. Scrivete la dead letter queue in BigQuery ed eseguire analisi di pattern sugli eventi persi — ad esempio, le richieste da una particolare regione geografica potrebbero subire timeout costanti.",{"type":33,"tag":85,"props":1235,"children":1237},{"id":1236},"monitoring-latenza-error-rate-e-costo-per-evento",[1238],{"type":38,"value":1239},"Monitoring: Latenza, Error Rate e Costo per Evento",{"type":33,"tag":34,"props":1241,"children":1242},{},[1243],{"type":38,"value":1244},"Una configurazione production-ready non è completa senza metriche. Monitorate tre metriche principali:",{"type":33,"tag":1246,"props":1247,"children":1248},"table",{},[1249,1273],{"type":33,"tag":1250,"props":1251,"children":1252},"thead",{},[1253],{"type":33,"tag":1254,"props":1255,"children":1256},"tr",{},[1257,1263,1268],{"type":33,"tag":1258,"props":1259,"children":1260},"th",{},[1261],{"type":38,"value":1262},"Metrica",{"type":33,"tag":1258,"props":1264,"children":1265},{},[1266],{"type":38,"value":1267},"Target",{"type":33,"tag":1258,"props":1269,"children":1270},{},[1271],{"type":38,"value":1272},"Soglia di Allarme",{"type":33,"tag":1274,"props":1275,"children":1276},"tbody",{},[1277,1296,1314],{"type":33,"tag":1254,"props":1278,"children":1279},{},[1280,1286,1291],{"type":33,"tag":1281,"props":1282,"children":1283},"td",{},[1284],{"type":38,"value":1285},"p95 request latency",{"type":33,"tag":1281,"props":1287,"children":1288},{},[1289],{"type":38,"value":1290},"\u003C500ms",{"type":33,"tag":1281,"props":1292,"children":1293},{},[1294],{"type":38,"value":1295},">1000ms",{"type":33,"tag":1254,"props":1297,"children":1298},{},[1299,1304,1309],{"type":33,"tag":1281,"props":1300,"children":1301},{},[1302],{"type":38,"value":1303},"Error rate (5xx \u002F total)",{"type":33,"tag":1281,"props":1305,"children":1306},{},[1307],{"type":38,"value":1308},"\u003C0.1%",{"type":33,"tag":1281,"props":1310,"children":1311},{},[1312],{"type":38,"value":1313},">1%",{"type":33,"tag":1254,"props":1315,"children":1316},{},[1317,1322,1327],{"type":33,"tag":1281,"props":1318,"children":1319},{},[1320],{"type":38,"value":1321},"Cost per event",{"type":33,"tag":1281,"props":1323,"children":1324},{},[1325],{"type":38,"value":1326},"\u003C$0.0001",{"type":33,"tag":1281,"props":1328,"children":1329},{},[1330],{"type":38,"value":1331},">$0.001",{"type":33,"tag":34,"props":1333,"children":1334},{},[1335],{"type":38,"value":1336},"Collegate i metriche Cloud Run al dashboard Cloud Monitoring. Un picco di latenza proviene solitamente da un rallentamento dell'API downstream (Meta, GA4) — in questo caso applicate il pattern circuit breaker: se Meta non risponde per 10 secondi, disabilitate temporaneamente quel tag. Per il costo per evento, dividete la fattura mensile Cloud Run per il numero totale di hit. Se il costo supera $0.0001, ottimizzate concurrency o dimensione dell'istanza.",{"type":33,"tag":34,"props":1338,"children":1339},{},[1340],{"type":38,"value":1341},"Per gli allarmi, configurate integrazione con webhook Slack o PagerDuty. Se l'error rate supera l'1%, attivate automaticamente il rollback (utilizzate Cloud Run revision management per tornare alla versione precedente stabile). Questa automazione riduce i production incident a 5 minuti.",{"type":33,"tag":41,"props":1343,"children":1345},{"id":1344},"identity-resolution-e-user-id-forwarding",[1346],{"type":38,"value":1347},"Identity Resolution e User ID Forwarding",{"type":33,"tag":34,"props":1349,"children":1350},{},[1351,1353,1359],{"type":38,"value":1352},"Il punto di forza di server-side GTM è la capacità di trasportare l'identità first-party ai sistemi downstream. Inviando l'",{"type":33,"tag":97,"props":1354,"children":1356},{"className":1355},[],[1357],{"type":38,"value":1358},"user_id",{"type":38,"value":1360}," di un utente loggato nel web a GA4, Meta CAPI e CDP contemporaneamente, potete implementare cross-device attribution. Tuttavia, per conformità GDPR e KVKK, non dovete inviare nemmeno l'hash di PII (email, telefono) senza consenso dell'utente.",{"type":33,"tag":34,"props":1362,"children":1363},{},[1364,1366,1372,1374,1380,1382,1388,1390,1395,1397,1403,1405,1411,1413,1419,1421,1427],{"type":38,"value":1365},"Nel container server GTM, configurate il trigger \"Consent Mode v2\": verificate lo stato del consenso ",{"type":33,"tag":97,"props":1367,"children":1369},{"className":1368},[],[1370],{"type":38,"value":1371},"ad_storage",{"type":38,"value":1373}," e ",{"type":33,"tag":97,"props":1375,"children":1377},{"className":1376},[],[1378],{"type":38,"value":1379},"analytics_storage",{"type":38,"value":1381},". Se non c'è consenso, inviate solo ",{"type":33,"tag":97,"props":1383,"children":1385},{"className":1384},[],[1386],{"type":38,"value":1387},"client_id",{"type":38,"value":1389}," anonimo; se c'è consenso, aggiungete SHA256(email) e ",{"type":33,"tag":97,"props":1391,"children":1393},{"className":1392},[],[1394],{"type":38,"value":1358},{"type":38,"value":1396},". Per Meta CAPI, compilate i campi advanced matching ",{"type":33,"tag":97,"props":1398,"children":1400},{"className":1399},[],[1401],{"type":38,"value":1402},"em",{"type":38,"value":1404}," (email con hash), ",{"type":33,"tag":97,"props":1406,"children":1408},{"className":1407},[],[1409],{"type":38,"value":1410},"ph",{"type":38,"value":1412}," (telefono con hash), ",{"type":33,"tag":97,"props":1414,"children":1416},{"className":1415},[],[1417],{"type":38,"value":1418},"fn",{"type":38,"value":1420},"\u002F",{"type":33,"tag":97,"props":1422,"children":1424},{"className":1423},[],[1425],{"type":38,"value":1426},"ln",{"type":38,"value":1428}," (nome\u002Fcognome con hash). TikTok e Google Ads supportano campi di matching avanzato simili.",{"type":33,"tag":34,"props":1430,"children":1431},{},[1432,1434,1440,1442,1447,1449,1454,1456,1461],{"type":38,"value":1433},"Gestite la logica di identity resolution in una tabella centrale ",{"type":33,"tag":97,"props":1435,"children":1437},{"className":1436},[],[1438],{"type":38,"value":1439},"user_identity",{"type":38,"value":1441}," in BigQuery. Ogni hit server-side dovrebbe interrogare questa tabella per integrare segnali mancanti (ad esempio, se il ",{"type":33,"tag":97,"props":1443,"children":1445},{"className":1444},[],[1446],{"type":38,"value":1387},{"type":38,"value":1448}," ricavato dal cookie corrisponde a un ",{"type":33,"tag":97,"props":1450,"children":1452},{"className":1451},[],[1453],{"type":38,"value":1358},{"type":38,"value":1455}," noto, aggiungete quel ",{"type":33,"tag":97,"props":1457,"children":1459},{"className":1458},[],[1460],{"type":38,"value":1358},{"type":38,"value":1462}," a tutti gli eventi). Questo pattern, combinato con un'architettura CDP, fornisce una visione a 360 gradi del cliente.",{"type":33,"tag":41,"props":1464,"children":1466},{"id":1465},"cloudflare-workers-come-alternativa-deployment-al-edge",[1467],{"type":38,"value":1468},"Cloudflare Workers come Alternativa: Deployment al Edge",{"type":33,"tag":34,"props":1470,"children":1471},{},[1472],{"type":38,"value":1473},"Oltre a Cloud Run, potete deployare il container GTM su Cloudflare Workers. Gli Workers eseguono V8 isolate, quindi non hanno cold start (0ms), ma presentano limiti di CPU (10ms CPU time per richiesta) e dimensione bundle (1MB). L'immagine GTM ufficiale non rientra in questi limiti — dovete scrivere un layer di tagging lightweight personalizzato.",{"type":33,"tag":34,"props":1475,"children":1476},{},[1477],{"type":38,"value":1478},"Vantaggi di Workers: edge globale (300+ location), protezione DDoS integrata, cache sub-millisecond con KV. Svantaggi: nessuna gestione tag via GUI GTM (configurazione basata su codice), nessuna integrazione BigQuery diretta (necessitate pipeline Workers → Pub\u002FSub → BigQuery). Preferite Workers per scenari ad alto RPS (>10k req\u002Fs) e bassa latenza — ad esempio, analytics di giochi mobile.",{"type":33,"tag":41,"props":1480,"children":1482},{"id":1481},"production-checklist-lista-di-controllo-pre-deploy",[1483],{"type":38,"value":1484},"Production Checklist: Lista di Controllo Pre-Deploy",{"type":33,"tag":34,"props":1486,"children":1487},{},[1488],{"type":38,"value":1489},"Non deployate se non rientra in questa lista di controllo:",{"type":33,"tag":1491,"props":1492,"children":1493},"ol",{},[1494,1505,1515,1525,1535,1545,1555],{"type":33,"tag":1495,"props":1496,"children":1497},"li",{},[1498,1503],{"type":33,"tag":58,"props":1499,"children":1500},{},[1501],{"type":38,"value":1502},"La config del container è versionata?",{"type":38,"value":1504}," Ogni cambio di workspace deve essere committato su Git.",{"type":33,"tag":1495,"props":1506,"children":1507},{},[1508,1513],{"type":33,"tag":58,"props":1509,"children":1510},{},[1511],{"type":38,"value":1512},"La deduplication è stata testata?",{"type":38,"value":1514}," Inviate lo stesso event_id due volte e verificate che il dashboard mostri un solo evento.",{"type":33,"tag":1495,"props":1516,"children":1517},{},[1518,1523],{"type":33,"tag":58,"props":1519,"children":1520},{},[1521],{"type":38,"value":1522},"La dead letter queue è configurata?",{"type":38,"value":1524}," Gli errori 5xx non dovrebbero andare persi.",{"type":33,"tag":1495,"props":1526,"children":1527},{},[1528,1533],{"type":33,"tag":58,"props":1529,"children":1530},{},[1531],{"type":38,"value":1532},"C'è un allarme di costo?",{"type":38,"value":1534}," Ricevete email se la spesa giornaliera supera $X.",{"type":33,"tag":1495,"props":1536,"children":1537},{},[1538,1543],{"type":33,"tag":58,"props":1539,"children":1540},{},[1541],{"type":38,"value":1542},"Consent Mode è integrato?",{"type":38,"value":1544}," La piattaforma di gestione dei consensi (OneTrust, Cookiebot) è sincronizzata con i trigger GTM?",{"type":33,"tag":1495,"props":1546,"children":1547},{},[1548,1553],{"type":33,"tag":58,"props":1549,"children":1550},{},[1551],{"type":38,"value":1552},"SSL\u002FTLS è corretto?",{"type":38,"value":1554}," Se usate un dominio personalizzato, il rinnovo del certificato è automatico (Let's Encrypt o Cloud CDN managed cert)?",{"type":33,"tag":1495,"props":1556,"children":1557},{},[1558,1563],{"type":33,"tag":58,"props":1559,"children":1560},{},[1561],{"type":38,"value":1562},"È stato eseguito un load test?",{"type":38,"value":1564}," Simulate 1000 RPS con k6 o Locust e osservate il comportamento di scaling dell'istanza.",{"type":33,"tag":34,"props":1566,"children":1567},{},[1568],{"type":38,"value":1569},"La transizione in produzione dovrebbe essere graduale. Nel primo giorno, instradatate il 10% del traffico a server-side (utilizzando Cloud Load Balancer con backend ponderato), il restante 90% rimane sul vecchio GTM client-side. Confrontate le metriche: numero di conversioni, attribution dei ricavi",{"type":33,"tag":1571,"props":1572,"children":1573},"style",{},[1574],{"type":38,"value":1575},"html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}",{"title":17,"searchDepth":164,"depth":164,"links":1577},[1578,1581,1584,1587,1588,1589],{"id":43,"depth":151,"text":46,"children":1579},[1580],{"id":87,"depth":164,"text":90},{"id":321,"depth":151,"text":324,"children":1582},[1583],{"id":602,"depth":164,"text":605},{"id":830,"depth":151,"text":833,"children":1585},[1586],{"id":1236,"depth":164,"text":1239},{"id":1344,"depth":151,"text":1347},{"id":1465,"depth":151,"text":1468},{"id":1481,"depth":151,"text":1484},"markdown","content:it:data:gtm-lato-server-conversion-api-produzione.md","content","it\u002Fdata\u002Fgtm-lato-server-conversion-api-produzione.md","it\u002Fdata\u002Fgtm-lato-server-conversion-api-produzione","md",1785967492676]