Class DomainTemplateConflictHandler
java.lang.Object
fr.tiogars.inception.domains.domaintemplate.controllers.DomainTemplateConflictHandler
@RestControllerAdvice(basePackageClasses=DomainTemplateCreateController.class)
public class DomainTemplateConflictHandler
extends Object
Reports active-code and concurrent-write conflicts without hiding other database errors.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.springframework.http.ResponseEntity<Void> concurrentWrite(org.springframework.dao.OptimisticLockingFailureException exception) org.springframework.http.ResponseEntity<Void> duplicateActiveCode(org.springframework.dao.DataIntegrityViolationException exception)
-
Constructor Details
-
DomainTemplateConflictHandler
public DomainTemplateConflictHandler()
-
-
Method Details
-
concurrentWrite
@ExceptionHandler(org.springframework.dao.OptimisticLockingFailureException.class) public org.springframework.http.ResponseEntity<Void> concurrentWrite(org.springframework.dao.OptimisticLockingFailureException exception) -
duplicateActiveCode
@ExceptionHandler(org.springframework.dao.DataIntegrityViolationException.class) public org.springframework.http.ResponseEntity<Void> duplicateActiveCode(org.springframework.dao.DataIntegrityViolationException exception)
-