When a batch is sent that is over the pubsub limit of 10MB we get
ERROR com.spotify.ffwd.pubsub[output:2] - Failed sending metrics io.grpc.StatusRuntimeException: INVALID_ARGUMENT: Request payload size exceeds the limit: 10485760 bytes.
Which gets retried and causes a backup of metrics.
This will check the size of metrics being sent in bytes and reduce the size appropriately before sending to pubsub.
When a batch is sent that is over the pubsub limit of 10MB we get
ERROR com.spotify.ffwd.pubsub[output:2] - Failed sending metrics io.grpc.StatusRuntimeException: INVALID_ARGUMENT: Request payload size exceeds the limit: 10485760 bytes.
Which gets retried and causes a backup of metrics.This will check the size of metrics being sent in bytes and reduce the size appropriately before sending to pubsub.