You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -133,7 +133,9 @@ or [**`ProblemHandlingWebflux`**](src/main/java/com/ksoot/problem/spring/advice/
133
133
|`├──`[**`DataIntegrityViolationAdviceTrait`**](src/main/java/com/ksoot/problem/spring/advice/dao/DataIntegrityViolationAdviceTrait.java)|[`500 Internal Server Error`](https://httpstatus.es/500)| data.integrity.violation.\<Failed DB constraint name\>|
134
134
|`└──`[**`DuplicateKeyExceptionAdviceTrait`**](src/main/java/com/ksoot/problem/spring/advice/dao/DuplicateKeyExceptionAdviceTrait.java)|[`500 Internal Server Error`](https://httpstatus.es/500)| data.integrity.violation.\<Failed DB constraint name\>|
135
135
136
-
These advices are autoconfigured as a bean `DaoExceptionHandler` if following conditions are true
136
+
These advices are autoconfigured as [**`WebDaoExceptionHandler`**](src/main/java/com/ksoot/problem/spring/boot/autoconfigure/web/WebDaoExceptionHandler.java)
137
+
or [**`WebFluxDaoExceptionHandler`**](src/main/java/com/ksoot/problem/spring/boot/autoconfigure/webflux/WebFluxDaoExceptionHandler.java)
138
+
for Spring Web and Spring Webflux respectively, if following conditions are true
137
139
*`problem.dao-advice-enabled` is not set to `false`. Its default value is `true`
138
140
* If using relation databases then `spring-data-jpa` jar is detected in classpath and either `spring.datasource.url` or `spring.r2dbc.url` is configured
139
141
* If using MongoDB then `spring-data-mongodb` jar is detected in classpath and `spring.data.mongodb.uri` is configured
@@ -162,7 +164,7 @@ and [**`ProblemAccessDeniedHandler`**](src/main/java/com/ksoot/problem/spring/ad
162
164
are autoconfigured as `authenticationEntryPoint` and `accessDeniedHandler` beans respectively.
163
165
164
166
But to make it work following needs to be done in application's Spring Security configuration.
165
-
Refer to example [**`SecurityConfiguration`**](https://github.com/officiallysingh/problem-handler-web-demo/blob/main/src/main/java/com/ksoot/problem/demo/config/SecurityConfiguration.java)
167
+
Refer to example [**`WebSecurityConfiguration`**](https://github.com/officiallysingh/problem-handler-web-demo/blob/main/src/main/java/com/ksoot/problem/demo/config/WebSecurityConfiguration.java)
@@ -194,7 +196,7 @@ and [**`ProblemServerAccessDeniedHandler`**](src/main/java/com/ksoot/problem/spr
194
196
are autoconfigured as `authenticationEntryPoint` and `accessDeniedHandler` beans respectively.
195
197
196
198
But to make it work following needs to be done in application Spring Security configuration.
197
-
Refer to example [**`SecurityConfiguration`**](https://github.com/officiallysingh/problem-handler-webflux-demo/blob/main/src/main/java/com/ksoot/problem/demo/config/SecurityConfiguration.java)
199
+
Refer to example [**`WebFluxSecurityConfiguration`**](https://github.com/officiallysingh/problem-handler-webflux-demo/blob/main/src/main/java/com/ksoot/problem/demo/config/WebFluxSecurityConfiguration.java)
*`problem.open-api.req-validation-enabled`:- To enable or disable OpenAPI specification validation for request, default is `false`.
323
325
*`problem.open-api.res-validation-enabled`:- To enable or disable OpenAPI specification validation for response, default is `false`.
324
326
325
-
326
327
## Error Key
327
328
The main concept behind specifying the error attributes in `properties` file is **Error key**, which is mandatory to be unique for each error scenario.
328
329
**It is either derived or specified by application** while throwing exception and used to externalize the error attributes in `properties` file.
0 commit comments