-
Notifications
You must be signed in to change notification settings - Fork 41.7k
Fix actuator endpoint tables in docs #14712
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix actuator endpoint tables in docs #14712
Conversation
snicoll
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR. integrationgraph is enabled by default, I've added a comment.
| |`integrationgraph` | ||
| |Yes | ||
| |Yes | ||
| |No |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What makes you think this is not enabled by default? There is a graph only if you're actually using Spring Integration. If you have no graph, there's not much to show so the endpoint is conditional on that.
So the endpoint is enabled by default but only shows up if you're using SI. Is that confusing?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This table is for exposure rather than enablement. The endpoint is enabled by default, but I don't believe it is exposed by default. In other words, I agree with @dreis2211 that the table is currently incorrect.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this is a bit different from exposure or enablement. I think adding the integration graph as No in the exposure table, might lead to the misconception that it will be available if management.endpoints.web.exposure is set to *. But it is conditionally available on SI and setting that flag won't make it available.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The flyway endpoint is very similar here. It requires Flyway of course, but also states a No. I don't care too much in the end and do what the team prefers, but setting integrationgraph to No seems more consistent at the moment.
Setting it to No also backs the code handling default exposure. E.g. WebEndpointAutoConfiguration
@Bean
public ExposeExcludePropertyEndpointFilter<ExposableWebEndpoint> webExposeExcludePropertyEndpointFilter() {
WebEndpointProperties.Exposure exposure = this.properties.getExposure();
return new ExposeExcludePropertyEndpointFilter<>(ExposableWebEndpoint.class,
exposure.getInclude(), exposure.getExclude(), "info", "health");
}
Or ManagementWebSecurityConfigurerAdapter
@Override
protected void configure(HttpSecurity http) throws Exception {
http.authorizeRequests()
.requestMatchers(
EndpointRequest.to(HealthEndpoint.class, InfoEndpoint.class))
.permitAll().anyRequest().authenticated().and().formLogin().and()
.httpBasic();
}
Both only expose the health and the info endpoint.
Having that said, I think we could do the following:
- Accept the PR as it is to be more consistent
- Clarify both the enablement and exposure tables documentation with an additional hint, that some endpoints can be conditional on something. Flyway having Flyway available,
integrationgraphhaving SI on the classpath, etc
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@dreis2211 Ignore my comment. I misread the change. Thanks for the clarification.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This table is for exposure rather than enablement.
I misread that, sorry.
* pr/14712: Fix actuator endpoint tables in docs
Hi,
this PR fixes a missing entry for the
cachesendpoint in the production-ready-endpoints-exposing-endpoints section.While doing that, I noticed that the
integrationgraphendpoint is documented to be available via Web by default, which doesn't seem to be the case. Maybe I'm missing something here though (in which case I'm happy to revert that particular change).Let me know what you think.
Cheers,
Christoph