fix(aria): fix os_eol_status enum cast — use native SQL throughout
CD - Develop / build-and-deploy (push) Failing after 14m42s

PostgreSQL named enum types require explicit casts that Hibernate's
derived query methods don't generate. Replace countByOsEolStatus and
findByOsEolStatusOrderByPostureScoreAsc with native @Query variants that
CAST(:status AS os_eol_status). Same pattern already applied to severity.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-06-15 15:57:41 -04:00
parent 1e7625db8b
commit 89a088c4b3
3 changed files with 9 additions and 7 deletions
@@ -52,7 +52,7 @@ public class DevicePostureController {
Pageable pageable = PageRequest.of(page, size);
if (osEolStatus != null) {
return postureRepository.findByOsEolStatusOrderByPostureScoreAsc(osEolStatus, pageable);
return postureRepository.findByOsEolStatusNativeOrderByPostureScoreAsc(osEolStatus.name(), pageable);
}
if ("low".equals(scoreFilter)) {
return postureRepository.findByPostureScoreLessThanOrderByPostureScoreAsc(50, pageable);