davsclaus opened a new pull request, #3157:
URL: https://github.com/apache/camel-kamelets/pull/3157

   _Claude Code on behalf of Claus Ibsen_
   
   Template fixes for bugs found while documenting the Kamelets (#3141–#3155). 
Each was reproduced first, then fixed and verified on Camel 4.23.0 and 
4.24.0-SNAPSHOT.
   
   ## Fixes
   
   | Kamelets | Bug | Fix | Verified |
   |---|---|---|---|
   | The SQL sources (PostgreSQL, MySQL, MariaDB, SQL Server, Oracle, 
Snowflake, Databricks, Redshift) | `consumedQuery` without `RAW()`: `price = 
price + 1` ran as `price   1` (BadSqlGrammar), and an `&` broke the start | 
`onConsume=RAW({{?consumedQuery}})` | PostgreSQL in Docker |
   | `cassandra-sink`, `cassandra-source` | `cql` without `RAW()`: `'a+b'` was 
stored as `a b` | `cql=RAW({{query}})` | Cassandra in Docker |
   | `jira-add-issue-sink`, `jira-update-issue-sink` | `ce-issueDescription` 
was mapped to `CamelJiraIssueDescription`, which no Jira producer reads. 
Documented since d63e6e1f2 as "the body takes precedence", but never worked | 
When the body is empty, it is set from the header; the body still wins | A 
local fake Jira logging the requests |
   | `mongodb-sink` | `db-upsert`/`ce-dbupsert` were mapped to 
`CamelMongoDbUpsert`, which an insert ignores | The dead mapping is removed. An 
upsert would need an operator-set option, not a message header; that is for a 
follow-up | MongoDB in Docker |
   | `redis-sink` | `channels` was never used, so PUBLISH without a channel 
header failed | `channels` is the channel when no channel header is set; the 
`channel`/`ce-channel` headers still win | Redis in Docker, with a subscriber |
   | `google-sheets-source` | `majorDimension` was only set as a header, so 
cells were always read by rows | Passed to the component (default `ROWS`, as 
before) | The Sheets client pointed at a local fake API |
   | The five GitHub sources | No poll delay, so every 500 ms: over 7,200 API 
calls an hour, above GitHub's 5,000 per token | A new `delay` option, default 
60000 ms | A local fake GitHub API |
   
   Notes on the first two rows:
   - `aws-redshift-source` has the same line as the other SQL sources and gets 
the same `RAW()`.
   - On 4.23 an `&` inside `RAW()` is still cut when it comes through a 
Kamelet. A plain `sql:` endpoint works, so this is a runtime issue, already 
fixed in 4.24. A `+` works on both versions.
   
   ## Not changed
   
   `ogcapi-features-action` `split=true` was reported as having no effect.
   - **When it works:** it does split when the Kamelet is used as a Kamelet EIP 
with nested steps.
   - **When it can't:** used with `to:` or in a Pipe, one call returns one 
message, so no template change can emit several. Changing it to return a JSON 
array would change what working users get.
   - **Instead:** the option's description should say this, in #3154.
   
   ## Behaviour changes on upgrade
   
   - **The GitHub sources poll every 60 s instead of every 500 ms.** Set 
`delay` for a faster rate.
   - **`redis-sink`:** a PUBLISH with no channel header now goes to `channels` 
(default `one`); before, it failed.
   - **The Jira sinks:** with an empty body and `ce-issueDescription`, the 
issue now gets that description.
   - **`google-sheets-source` with `majorDimension=COLUMNS`** now really reads 
columns.
   - **SQL and Cassandra:** queries with `+` now reach the database unchanged. 
A query that worked around the bug, for example with `%2B`, now sends a literal 
`%2B`.
   
   The descriptions in #3146, #3147, #3151 and #3154 describe the old behaviour 
of some of these. I will update them after this is merged, or in those PRs, 
whichever merges second.
   
   `./mvnw clean install` from the root passes.
   
   🤖 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]

Reply via email to