CtrlK
BlogDocsLog inGet started
Tessl Logo

tessl-labs/springboot-error-handling

Error handling for Spring Boot APIs — @ControllerAdvice, structured error

84

1.76x
Quality

75%

Does it follow best practices?

Impact

99%

1.76x

Average score across 5 eval scenarios

SecuritybySnyk

Passed

No known issues

Overview
Quality
Evals
Security
Files

Evaluation results

100%

33%

Build an Employee Directory API

Criteria
Without context
With context

Global exception handler with @RestControllerAdvice

100%

100%

Custom exception hierarchy

50%

100%

Consistent structured error response format

50%

100%

Validation error handler with field details

83%

100%

No stack trace leaks

41%

100%

Bean validation with @Valid

80%

100%

DataIntegrityViolation handling

33%

100%

Appropriate HTTP status codes

62%

100%

CRUD endpoints functional

90%

100%

98%

73%

Build an Event Booking API

Criteria
Without context
With context

Global exception handler with @RestControllerAdvice

0%

100%

Custom exception hierarchy

0%

100%

Consistent structured error response format

0%

100%

Validation error handler with field details

0%

100%

No stack trace leaks

41%

100%

Bean validation with @Valid

20%

100%

Appropriate HTTP status codes

70%

80%

Business rule violations as typed errors

28%

100%

CRUD endpoints functional

90%

100%

99%

32%

Build a Warehouse Inventory Tracking API

Criteria
Without context
With context

Global exception handler with @RestControllerAdvice

100%

100%

Custom exception hierarchy

41%

100%

Consistent structured error response format

50%

100%

Validation error handler with field details

91%

100%

No stack trace leaks

33%

100%

Bean validation with @Valid

100%

90%

DataIntegrityViolation handling

22%

100%

Appropriate HTTP status codes

50%

100%

CRUD endpoints functional

100%

100%

100%

32%

Build a Library Management API

Criteria
Without context
With context

Global exception handler with @RestControllerAdvice

100%

100%

Custom exception hierarchy

75%

100%

Consistent structured error response format

41%

100%

Validation error handler with field details

100%

100%

No stack trace leaks

16%

100%

Bean validation with @Valid

90%

100%

Appropriate HTTP status codes

50%

100%

DataIntegrityViolation handling

14%

100%

CRUD endpoints functional

100%

100%

98%

44%

Build a Restaurant Ordering API

Criteria
Without context
With context

Global exception handler with @RestControllerAdvice

86%

100%

Custom exception hierarchy

50%

100%

Consistent structured error response format

58%

100%

Validation error handler with field details

0%

100%

No stack trace leaks

100%

100%

Bean validation with @Valid

0%

100%

Appropriate HTTP status codes

50%

100%

Malformed request handling

28%

100%

CRUD endpoints functional

90%

80%

Evaluated
Agent
Claude Code
Model
Claude Sonnet 4.6

Table of Contents