org.springframework.boot.autoconfigure.web.ErrorAttributes Java Examples
The following examples show how to use
org.springframework.boot.autoconfigure.web.ErrorAttributes.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: SmartGlobalErrorController.java From super-cloudops with Apache License 2.0 | 5 votes |
public SmartGlobalErrorController(ErrorAttributes errorAttributes, ErrorControllerProperties config, CompositeErrorConfiguringAdapter adapter) { super(errorAttributes); notNull(config, "ErrorControllerProperties must not be null."); notNull(adapter, "CompositeErrorConfiguringAdapter must not be null."); this.config = config; this.adapter = adapter; }
Example #2
Source File: SearchBoxConfiguration.java From searchbox-core with Apache License 2.0 | 5 votes |
@Bean public ErrorAttributes customizeErrorResponseAttributes() { return new DefaultErrorAttributes(){ @Override public Map<String, Object> getErrorAttributes(RequestAttributes requestAttributes, boolean includeStackTrace) { Map<String, Object> errorAttributes = super.getErrorAttributes(requestAttributes, includeStackTrace); errorAttributes.remove("timestamp"); errorAttributes.remove("exception"); return errorAttributes; } }; }
Example #3
Source File: CustomErrorControllerConfiguration.java From spring-mvc-error-handling-example with Apache License 2.0 | 5 votes |
/** * 抄的是{@link ErrorMvcAutoConfiguration#basicErrorController(ErrorAttributes)} * * @param errorAttributes * @return */ @Bean public CustomErrorController customErrorController(ErrorAttributes errorAttributes) { return new CustomErrorController( errorAttributes, this.serverProperties.getError(), this.errorViewResolvers ); }
Example #4
Source File: ErrorController.java From NoteBlog with MIT License | 4 votes |
public ErrorController(HttpServletRequest request, ErrorAttributes errorAttributes, ServerProperties serverProperties) { Assert.notNull(errorAttributes, "ErrorAttributes must not be null"); this.errorAttributes = errorAttributes; this.serverProperties = serverProperties; this.request = request; }
Example #5
Source File: ConsoleIndex.java From eagle with Apache License 2.0 | 4 votes |
@Autowired public ConsoleIndex(ErrorAttributes errorAttributes) { super(errorAttributes); }
Example #6
Source File: CrnkErrorController.java From crnk-framework with Apache License 2.0 | 4 votes |
public CrnkErrorController(ErrorAttributes errorAttributes, ErrorProperties errorProperties) { super(errorAttributes, errorProperties); }
Example #7
Source File: CrnkErrorControllerAutoConfiguration.java From crnk-framework with Apache License 2.0 | 4 votes |
@Bean @ConditionalOnMissingBean(value = ErrorController.class, search = SearchStrategy.CURRENT) public BasicErrorController jsonapiErrorController(ErrorAttributes errorAttributes) { return new CrnkErrorController(errorAttributes, this.serverProperties.getError(), this.errorViewResolvers); }
Example #8
Source File: ErrorControllerAutoConfiguration.java From super-cloudops with Apache License 2.0 | 4 votes |
@Bean public SmartGlobalErrorController smartGlobalErrorController(ErrorAttributes errorAttrs, CompositeErrorConfiguringAdapter adapter, ErrorControllerProperties config) { return new SmartGlobalErrorController(errorAttrs, config, adapter); }
Example #9
Source File: CustomErrorController.java From spring-mvc-error-handling-example with Apache License 2.0 | 4 votes |
public CustomErrorController(ErrorAttributes errorAttributes, ErrorProperties errorProperties) { super(errorAttributes, errorProperties); }
Example #10
Source File: CustomErrorController.java From spring-mvc-error-handling-example with Apache License 2.0 | 4 votes |
public CustomErrorController(ErrorAttributes errorAttributes, ErrorProperties errorProperties, List<ErrorViewResolver> errorViewResolvers) { super(errorAttributes, errorProperties, errorViewResolvers); }
Example #11
Source File: CustomErrorAttributesConfiguration.java From spring-mvc-error-handling-example with Apache License 2.0 | 4 votes |
@Bean public ErrorAttributes errorAttributes() { return new CustomErrorAttributes(); }
Example #12
Source File: DefaultStandaloneControllerConfig.java From spring-boot-practice with Apache License 2.0 | 4 votes |
@Bean ErrorAttributes errorAttributes() { return new DefaultErrorAttributes(); }
Example #13
Source File: ErrorHandleConfiguration.java From onetwo with Apache License 2.0 | 4 votes |
@Bean @ConditionalOnMissingBean(DataResultErrorController.class) public ErrorController dataResultErrorController(ErrorAttributes errorAttributes, ServerProperties serverProperties){ return new DataResultErrorController(errorAttributes, serverProperties.getError(), this.errorViewResolvers); }
Example #14
Source File: DataResultErrorController.java From onetwo with Apache License 2.0 | 4 votes |
public DataResultErrorController(ErrorAttributes errorAttributes, ErrorProperties errorProperties) { super(errorAttributes, errorProperties); }
Example #15
Source File: DataResultErrorController.java From onetwo with Apache License 2.0 | 4 votes |
public DataResultErrorController(ErrorAttributes errorAttributes, ErrorProperties errorProperties, List<ErrorViewResolver> errorViewResolvers) { super(errorAttributes, errorProperties, errorViewResolvers); }
Example #16
Source File: CrnkErrorController.java From crnk-framework with Apache License 2.0 | 3 votes |
public CrnkErrorController(ErrorAttributes errorAttributes, ErrorProperties errorProperties, List<ErrorViewResolver> errorViewResolvers) { super(errorAttributes, errorProperties, errorViewResolvers); }
Example #17
Source File: WxErrorController.java From fw-cloud-framework with MIT License | 2 votes |
/** * Controller for the Error Controller * * @param errorAttributes */ public WxErrorController(ErrorAttributes errorAttributes) { this.errorAttributes = errorAttributes; }