oscerd commented on issue #328: URL: https://github.com/apache/camel-kamelets/issues/328#issuecomment-5830438660
Status update: one of the three questions this shares with #929 is now settled in code, and it narrows what is left here. **Answered — the catalog API now prefers the Kamelet's own declaration.** #3061 landed today (#929 closed): `getKameletSupportedHeaders` consults `spec.dataTypes.<in|out>.headers` first and only falls back to the underlying Camel component when the Kamelet declares nothing. So the objection I raised in my earlier comment — that a consumer asking the catalog what a Kamelet emits gets the *component's* answer rather than the Kamelet's — no longer holds for headers. For the media types this issue asks about, that question never really arose: `KameletsCatalog.getDataTypes(name)` already returns the Kamelet's own `spec.dataTypes` block verbatim, `mediaType` included, and there is no component-derived value to prefer over it. There is no convenience accessor (nothing like `getKameletOutputMediaType`), but the data is reachable. **Still open — and these are what actually gate this issue.** Points 1 and 2 ask for the declaration to exist on *every* source and sink. It sits at 20 declarations across 19 Kamelets because: 1. the declaration hangs off `dataTypes`, so a Kamelet that performs no data type transformation has no natural place to put it; and 2. nothing validates its presence, so there is no pressure to add it. Neither is addressed by #3061. Both are still a catalog-wide design decision rather than an implementation task, and answering them is what would take this from 7% to the whole catalog. Point 3 — examples for input and output types — still has no mechanism at all. --- _Claude Code on behalf of Andrea Cosentino_ -- 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]
