节点npm Unirest给出陈旧/旧数据

我从我的节点js脚本中使用Unirest中间件来发出GET请求。 但由于某种原因,我正在从被请求的资源中获取陈旧/旧的数据。

即使在更新数据之后,我也从资源中获取陈旧的数据。 代码如下:

let unirest = require('unirest'); unirest.get('<resource_url>') .headers({"cache-control": "no-cache"}) .end(function (response) { console.log('body===>',JSON.stringify(response.body)); console.log('status=====>',response.status); console.log('response headers=====>',response.headers); }); 

响应标题===== {'strict-transport-security':'max-age = 15768000; includeSubDomains',date:'Fri,2017年9月15日18:58:40 GMT',cached_response:'true','cache-control':'no-transform,max-age = 3600',过期时间:'Fri,15 Sep 2017 12:10:53 GMT',变化:'接受,接受编码','内容长度':'1383',连接:'closures','内容types':'application / json','content-语言':'en-US'}

当通过Python scipt或CURL尝试时,相同的资源立即提供更新的数据。

注意:经过一段时间说3小时,节点js脚本提供更新的数据。