官术网_书友最值得收藏!

Standard response headers

All services should return the following headers.

  • Date: The date that the request was processed in RFC 3339 format.
  • Content-Type: The content type of the response.
  • Content-Encoding: gzip or deflate.
  • X-Request-ID/X-Correlation-ID: Whilst you may not directly request your clients to implement this header it may be something that you add to requests when you call downstream services. When you are trying to debug a service that is running in production it can be incredibly useful to be able to group all the requests by a single transaction ID. A common practice that we will see when we look at logging and monitoring is to store all logs in a common database such as Elastic Search. By setting the standard way of working when building many connected microservices that they pass the correlation ID with each downstream call you will be able to query your logs in Kibana or another log query tool and group them into a single transaction:
        X-Request-ID: f058ebd6-02f7-4d3f-942e-904344e8cde 
主站蜘蛛池模板: 汤阴县| 秀山| 奇台县| 门头沟区| 墨玉县| 神农架林区| 沧州市| 中江县| 田东县| 昌江| 梁平县| 湖州市| 门头沟区| 开封县| 宁陵县| 怀宁县| 桦南县| 康马县| 商丘市| 运城市| 兴城市| 卢湾区| 奉贤区| 古交市| 广昌县| 年辖:市辖区| 遂溪县| 奉节县| 普宁市| 钦州市| 沧州市| 金塔县| 沁阳市| 轮台县| 福贡县| 繁峙县| 双辽市| 额尔古纳市| 南漳县| 延长县| 西乌珠穆沁旗|