Class LogFileMvcEndpoint
- java.lang.Object
- org.springframework.web.servlet.config.annotation.WebMvcConfigurerAdapter
- org.springframework.boot.actuate.endpoint.mvc.AbstractMvcEndpoint
- org.springframework.boot.actuate.endpoint.mvc.AbstractNamedMvcEndpoint
- org.springframework.boot.actuate.endpoint.mvc.LogFileMvcEndpoint
- All Implemented Interfaces:
org.springframework.beans.factory.Aware
,MvcEndpoint
,NamedMvcEndpoint
,org.springframework.context.EnvironmentAware
,org.springframework.web.servlet.config.annotation.WebMvcConfigurer
@ConfigurationProperties(prefix="endpoints.logfile") public class LogFileMvcEndpoint extends AbstractNamedMvcEndpoint
Controller that provides an API for logfiles, i.e. downloading the main logfile configured in environment property 'logging.file' that is standard, but optional property for spring-boot applications.- Since:
- 1.3.0
Field Summary
Fields inherited from interface org.springframework.boot.actuate.endpoint.mvc.MvcEndpoint
DISABLED_RESPONSE
Constructor Summary
Constructors Constructor Description LogFileMvcEndpoint()
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description File
getExternalFile()
void
invoke(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
void
setExternalFile(File externalFile)
Methods inherited from class org.springframework.boot.actuate.endpoint.mvc.AbstractNamedMvcEndpoint
getName
Methods inherited from class org.springframework.boot.actuate.endpoint.mvc.AbstractMvcEndpoint
getEndpointType, getEnvironment, getPath, isEnabled, isSensitive, setEnabled, setEnvironment, setPath, setSensitive
Methods inherited from class org.springframework.web.servlet.config.annotation.WebMvcConfigurerAdapter
addArgumentResolvers, addCorsMappings, addFormatters, addInterceptors, addResourceHandlers, addReturnValueHandlers, addViewControllers, configureAsyncSupport, configureContentNegotiation, configureDefaultServletHandling, configureHandlerExceptionResolvers, configureMessageConverters, configurePathMatch, configureViewResolvers, extendHandlerExceptionResolvers, extendMessageConverters, getMessageCodesResolver, getValidator
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.springframework.boot.actuate.endpoint.mvc.MvcEndpoint
getEndpointType, getPath, isSensitive
Constructor Detail
LogFileMvcEndpoint
public LogFileMvcEndpoint()
Method Detail
getExternalFile
public File getExternalFile()
setExternalFile
public void setExternalFile(File externalFile)
invoke
@RequestMapping(method={GET,HEAD}) public void invoke(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws javax.servlet.ServletException, IOException
- Throws:
javax.servlet.ServletException
IOException