> For the complete documentation index, see [llms.txt](https://jack80342.gitbook.io/spring-boot/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://jack80342.gitbook.io/spring-boot/v.-spring-boot-actuator/50.-endpoints/50.4-configuring-endpoints.md).

# 50.4 配置端点

端点自动缓存不带任何参数的读取操作的响应。使用`cache.time-to-live`属性，配置端点缓存响应的时间。下面的例子将`beans`端点的缓存的存活时间设置为10秒：

**application.properties.**

```
management.endpoint.beans.cache.time-to-live=10s
```

**注** 前缀`management.endpoint.<name>`用于唯一确定一个端点。

**注** 当发送一个经过验证的HTTP请求时，`Principal`会被当做端点的输入，因此，响应不会被缓存。
