POST with +100 ecommerce products fails

202 views
Skip to first unread message

Teake Nutma

unread,
Jul 15, 2015, 11:09:26 AM7/15/15
Hi,

I ran into some unexpected behavior of the measurement protocol the other day. When posting purchases with less than 100 products everything works OK, but with 100 or more I'm getting back 400s instead of 200s. The debug URL also stops parsing the payloads at that stage. I've attached a Python script that demonstrates the problem.

This seems like a bug to me -- anybody know what's going on?

Btw, this might be related: https://groups.google.com/d/msg/google-analytics-measurement-protocol/yayofF5Nu3I/auGrZT-BV1cJ

Thanks,

Teake
measurementprotocoltests.py

Philip Walton

unread,
Jul 15, 2015, 7:57:20 PM7/15/15
to Teake Nutma, [email protected]
I believe the maximum hit size (for POST hits) is 8K, but now that I'm saying that, I'm not seeing it documented anywhere.

Can you check if your failed hits have a payload size that large?

--
You received this message because you are subscribed to the Google Groups "google-analytics-measurement-protocol" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To view this discussion on the web visit https://groups.google.com/d/msgid/google-analytics-measurement-protocol/5689a74b-545d-43e5-be31-e5297c9810d0%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Teake Nutma

unread,
Jul 16, 2015, 10:33:09 AM7/16/15
It seems you're right. The hits start failing when their payload is above 8K. I also couldn't find any documentation on this.
It's a shame the debug URL also stops working above this limit -- a 'payload too big' message would be much more helpful.

Philip Walton

unread,
Jul 16, 2015, 8:45:16 PM7/16/15
to Teake Nutma, [email protected]
Agreed, I'll see if I can fix both of these problems.

Perry Scopix

unread,
Jul 17, 2015, 10:40:45 AM7/17/15
Hi,

I believe this is documented here:


  • payload_data – The BODY of the post request. The body must include exactly 1 URI encoded payload and must be no longer than 8192 bytes.
Best regards,

Perry

Philip Walton

unread,
Jul 17, 2015, 9:24:41 PM7/17/15
to Perry Scopix, [email protected], Teake Nutma
Reply all
Reply to author
Forward
0 new messages