Skip to content
This repository was archived by the owner on Nov 11, 2025. It is now read-only.
This repository was archived by the owner on Nov 11, 2025. It is now read-only.

DeviceSimulatorUpdater.readAndCheckDownloadUrl() error validated response using Gzip #28

Description

@Sdcxv

I used caddy as the reverse proxy for the hawkbit server and enabled gzip compression while forwarding. However, this part of the client emulator (for http response entity content length check) filters the gzipped response, so it has not been able to trigger OTA file transfers.

                if (response.getEntity().getContentLength() != size) {
                    final String message = wrongContentLength(url, size, response);
                    return new UpdateStatus(ResponseStatus.ERROR, message);
                }

When gzip enable, response.getEntity().getContentLength() will be -1, according to org.apache.http.client.entity.GzipCompressingEntity.getContentLength()

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions