2

Using the HTTP protocol, is it possible to leverage of HTTP compression (i.e. Content-Encoding: gzip) in order to reduce the body size of a publishEvent, reducing the total cost of IoT core?

maurocchi
  • 640
  • 1
  • 6
  • 14

2 Answers2

2

I've received a feedback by Google, this is an excerpt:

Cloud IoT supports receiving data on gzip compressed encoding in the REST devices API. Though this approach could save you some bandwidth usage from your devices to Google Cloud, sending compressed data will NOT reduce the total cost of Cloud IoT core. Cloud IoT will account for ingress data the uncompressed version of the data for billing.

maurocchi
  • 640
  • 1
  • 6
  • 14
1

I tested setting the gzip header in the Node HTTP example and it continued to work for me so you should be able to do this. Also note that you can use MQTT, which is a binary protocol, which may also help to reduce network overhead.

Note that the actual payload itself as well as configuration change messages are binary data that can be compressed before sending over the wire.

class
  • 8,621
  • 29
  • 30