anchor.diff:                                 CMeta ++ Headers ++ CustomHeaders
                          end,
   
  -            BodyFunc = fun(Socket, Transport) ->
  -                               leo_net:chunked_send(
  -                                 Transport, Socket, RespObject, SendChunkLen),
  -                               ?access_log_get(BucketName, Key, Meta#?METADATA.dsize, ?HTTP_ST_OK, BeginTime)
  -                       end,
  -
  -            ?reply_ok(Headers2, {Meta#?METADATA.dsize, BodyFunc}, Req);
  +            case can_gzip(Req) of
  +                true ->
  +                    ?access_log_get(BucketName, Key, Meta#?METADATA.dsize, ?HTTP_ST_OK, BeginTime),
  +                    ?reply_ok(Headers2, RespObject, Req);
  +                false ->
  +                    BodyFunc = fun(Socket, Transport) ->
  +                                       leo_net:chunked_send(
  +                                         Transport, Socket, RespObject, SendChunkLen),
  +                                       ?access_log_get(BucketName, Key, Meta#?METADATA.dsize, ?HTTP_ST_OK, BeginTime)
  +                               end,
  +                    ?reply_ok(Headers2, {Meta#?METADATA.dsize, BodyFunc}, Req)
  +            end;
   
           %% For a chunked object.
           {ok, #?METADATA{cnumber = TotalChunkedObjs,
  
positive.code:                                CMeta = binary_to_term(CMetaBin),
                                 CMeta ++ Headers ++ CustomHeaders
                         end,
              BodyFunc = fun(Socket, Transport) ->
                                 leo_net:chunked_send(
                                   Transport, Socket, RespObject, SendChunkLen)
                         end,
  
              ?access_log_get(BucketName, Key, Meta#?METADATA.dsize, ?HTTP_ST_OK, BeginTime),
              ?reply_ok(Headers2, {Meta#?METADATA.dsize, BodyFunc}, Req);
  
          %% MISS: get an object from storage (large-size)
          {ok, #?METADATA{cnumber = TotalChunkedObjs,
  
negative.code:                  true ->
                       [{env, [{dispatch, Dispatch}]},
                        {max_keepalive, MaxKeepAlive},
                        {compress, true},
                        {timeout, Timeout4Header}];
                   %% Using http-cache (like a varnish/squid)
                   false ->
  