{"record":{"id":"22e12735460d98a4","repo":"floci-io/floci","slug":"resourcenotfoundexception-22e127","errorCode":"ResourceNotFoundException","errorMessage":"No notification configuration found for backup vault: {vaultName}","messagePattern":"No notification configuration found for backup vault: (.+?)","errorType":"exception","errorClass":"AwsException","httpStatus":400,"severity":"info","filePath":"src/main/java/io/github/hectorvent/floci/services/backup/BackupController.java","lineNumber":99,"sourceCode":"    @Path(\"/backup-vaults/\")\n    public Response listBackupVaults(@Context HttpHeaders headers) {\n        String region = regionResolver.resolveRegion(headers);\n        List<BackupVault> vaults = service.listBackupVaults(region);\n        ObjectNode out = objectMapper.createObjectNode();\n        ArrayNode list = out.putArray(\"BackupVaultList\");\n        vaults.forEach(list::addPOJO);\n        return Response.ok(out).build();\n    }\n\n    // Notification configuration is an optional, never-configured aspect of a vault in the\n    // emulator. Per the AWS Backup API, GetBackupVaultNotifications returns\n    // ResourceNotFoundException (HTTP 400) when no notification configuration exists for the\n    // vault. We mirror that exact error contract so SDK clients see the documented\n    // \"not configured\" signal rather than an empty 200 or a generic 400 they can't interpret.\n    @GET\n    @Path(\"/backup-vaults/{backupVaultName}/notification-configuration\")\n    public Response getBackupVaultNotifications(@PathParam(\"backupVaultName\") String vaultName) {\n        throw new AwsException(\"ResourceNotFoundException\",\n                \"No notification configuration found for backup vault: \" + vaultName, 400);\n    }\n\n    // Access policy is an optional, never-configured aspect of a vault in the emulator. Per the\n    // AWS Backup API, GetBackupVaultAccessPolicy returns ResourceNotFoundException (HTTP 400)\n    // when no policy exists for the vault. We mirror that exact error contract so SDK clients\n    // see the documented \"not configured\" signal rather than an empty 200 or a generic 400.\n    @GET\n    @Path(\"/backup-vaults/{backupVaultName}/access-policy\")\n    public Response getBackupVaultAccessPolicy(@PathParam(\"backupVaultName\") String vaultName) {\n        throw new AwsException(\"ResourceNotFoundException\",\n                \"No access policy found for backup vault: \" + vaultName, 400);\n    }\n\n    // ── Plan ───────────────────────────────────────────────────────────────────\n\n    @PUT\n    @Path(\"/backup/plans/\")","sourceCodeStart":81,"sourceCodeEnd":117,"githubUrl":"https://github.com/floci-io/floci/blob/62ff490619e7bd3554597c28c704081b4c15add5/src/main/java/io/github/hectorvent/floci/services/backup/BackupController.java#L81-L117","documentation":"GetBackupVaultNotifications in the BackupController always throws ResourceNotFoundException (HTTP 400) because the emulator never stores notification configurations for vaults. AWS Backup returns this same documented 'not configured' signal when no notifications were ever put on a vault, so SDK clients get the expected contract instead of an empty 200.","triggerScenarios":"Calling GetBackupVaultNotifications for any vault name, configured or not — the emulator has no PutBackupVaultNotifications state, so the response is unconditional.","commonSituations":"Audit or drift-detection tooling enumerating vault notification configs against the emulator; porting backup-alarm workflows that rely on SNS notifications, which the emulator does not implement.","solutions":["Guard the call with error-code handling for ResourceNotFoundException and treat it as 'notifications not configured'","Skip GetBackupVaultNotifications entirely when running against the emulator","For real notification behavior, run against actual AWS Backup — the emulator does not model it"],"exampleFix":"// before\nGetBackupVaultNotificationsResponse resp = backup.getBackupVaultNotifications(\n    GetBackupVaultNotificationsRequest.builder().backupVaultName(vault).build());\n\n// after\ntry {\n    GetBackupVaultNotificationsResponse resp = backup.getBackupVaultNotifications(\n        GetBackupVaultNotificationsRequest.builder().backupVaultName(vault).build());\n} catch (ResourceNotFoundException e) {\n    // notifications are never configured in the emulator — treat as absent\n}","handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":"catch (ResourceNotFoundException e) { notifications = Optional.empty(); // documented not-configured signal }","preventionTips":["Treat ResourceNotFoundException from this endpoint as normal emulator behavior","Feature-detect emulator vs. real AWS before asserting notification configuration exists"],"tags":["backup","notifications","not-implemented","aws-emulator"],"backgroundTag":null,"analyzedSha":"62ff490619e7bd3554597c28c704081b4c15add5","analyzedAt":"2026-08-14T14:25:23.764Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}