请求不带参数的图片时,头部的最后修改丢失

时间:2018-10-25 09:55:38

标签: imageresizer

当请求不带参数的图像的开头(curl --head https://example.com/resizer/example.png)时,缺少Last-Modified属性:

HTTP/1.1 200 OK
Cache-Control: private
Content-Length: 2064513
Content-Type: image/png
Server: Microsoft-IIS/8.5
X-AspNet-Version: 4.0.30319
X-Powered-By: ASP.NET
Date: Thu, 25 Oct 2018 09:05:46 GMT

我尝试将redirectToBlobIfUnmodified参数设置为“ true”无济于事。我还需要配置其他东西吗?

下面,我包括了web.config的相关部分:

 <resizer>
    <plugins>
      <add name="PrettyGifs" />
      <add name="WhitespaceTrimmer" />
      <add name="DiskCache" />      
      <add name="AzureReader2" prefix="~/" redirectToBlobIfUnmodified="false" checkForModifiedFiles="true" cacheMetadata="true" connectionString="" />
    </plugins>    
    <diskcache autoClean="true" hashModifiedDate="true" subfolders="1024"/>     
    <clientcache minutes="1440" />
    <licenses>
      <license></license>
    </licenses>
  </resizer>

0 个答案:

没有答案