fix(aria): fix os_eol_status enum cast — use native SQL throughout
CD - Develop / build-and-deploy (push) Failing after 14m42s
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:
@@ -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);
|
||||
|
||||
Reference in New Issue
Block a user