Number of Workers Requests suddenly doubled


#1

We use Workers for conditional proxying. Until recently we sent 20% of visitors to a different IP by using the resolveOverride feature, but last Friday at 14:00 EST we changed that to 100%. And starting from that time our number of requests per hour (for billing purposes) more than doubled! But I don’t understand why; we just change the destination of the request so I believe the number of requests should not have changed; is this a bug? The routes have not changed either.


#2

Hi @dan42,

Billing is based entirely on incoming requests. Changing what your worker does shouldn’t have any effect on how many times it runs, so this seems pretty strange. Does the regular (non-workers) analytics panel show an increase in traffic occurring at the same time?


#3

Hi again @dan42,

All the data we’ve been able to dig up seems to suggest your site’s request traffic actually increased by quite a bit on Friday. Moreover, our billing is based on incoming requests, so modifying a worker should not cause any change to the billable traffic – unless the modifications actually cause the client to make more requests.

To that end: As I recall, your resolve override directs some traffic to a content optimization service of some sort. Is it possible that that service in inserting additional assets that then need to be loaded by the client, hence generating additional requests that hit the worker? Or, perhaps they often return a redirect, which causes the client to immediately send a second request?


#4

Wow, your guess was spot on the money! Very impressive, as usual.