davsclaus opened a new pull request, #24781: URL: https://github.com/apache/camel/pull/24781
## Summary _Claude Code on behalf of davsclaus_ When an OpenAPI spec has operations without `operationId`, `validateOpenApi()` correctly generates synthetic IDs (`GENOPID_<VERB><sanitized_path>`) and validates against them. However, the generated ID was never written back to the `Operation` object, so `process()` called `operation.getOperationId()` which returned `null`, dispatching every request to `direct:null` instead of the generated endpoint. **Fix:** Write the generated operationId back to the `Operation` object in `validateOpenApi()`, so both validation and runtime dispatch use the same ID. **Failure scenario (before fix):** - Spec with `GET /users` and no `operationId` - `missingOperation=fail`: startup tells user to add `direct:GENOPID_GET.users`; user adds it; validation passes; every request resolves `direct:null` → `DirectConsumerNotAvailableException` → HTTP 500 - `missingOperation=mock/ignore`: user-defined GENOPID route is silently never invoked ## Test plan - [x] New test `testMissingOperationIdSetsGeneratedIdOnOperation` verifies operationIds are written back after validation - [x] Existing test `testMissingOperationId` still passes (validation error message unchanged) - [x] All 135 tests in `camel-rest-openapi` pass - [ ] CI validates no regressions 🤖 Generated with [Claude Code](https://claude.com/claude-code) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
