[ 
https://issues.apache.org/jira/browse/CAMEL-27654?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Claus Ibsen updated CAMEL-27654:
--------------------------------
    Fix Version/s: 4.25.0
                       (was: 4.24.0)

> camel-ibm-watsonx-data: createSchema ignores schemaName, doc examples use the 
> v2 API URL
> ----------------------------------------------------------------------------------------
>
>                 Key: CAMEL-27654
>                 URL: https://issues.apache.org/jira/browse/CAMEL-27654
>             Project: Camel
>          Issue Type: Bug
>            Reporter: Claus Ibsen
>            Priority: Minor
>             Fix For: 4.25.0
>
>
> Found while improving the option descriptions of camel-ibm-watsonx-data for 
> CAMEL-23832 (commit 
> https://github.com/apache/camel/commit/3a7c8203d694ffaeea4b0eeb9b24c990db7635d0).
> These are separate problems of the component; the descriptions commit only 
> documents the current behavior.
> h4. 1. createSchema ignores the schemaName option
> {{WatsonxDataProducer.handleCreateSchema()}} reads the schema name only from 
> the {{CamelIBMWatsonxDataSchemaName}} header. The other operations that take 
> a schema name ({{deleteSchema}}, {{listTables}}, {{getTable}}, 
> {{deleteTable}}, {{updateTable}}, {{getAllColumns}}) use 
> {{resolveHeader(...)}} and fall back to the {{schemaName}} option.
> So {{ibm-watsonx-data:x?operation=createSchema&schemaName=s1&...}} without 
> the header fails with "Schema name is required for this operation".
> Proposed change: use {{resolveHeader(exchange, 
> WatsonxDataConstants.SCHEMA_NAME, config.getSchemaName())}} in 
> {{handleCreateSchema()}} as well, and update the option and header 
> descriptions.
> h4. 2. The doc page examples use the v2 service URL
> The examples in {{ibm-watsonx-data-component.adoc}} use 
> {{serviceUrl=https://us-south.lakehouse.cloud.ibm.com/lakehouse/api/v2}}. The 
> component uses the IBM SDK {{com.ibm.cloud:watson-x-data}} 0.9.0, which is 
> the v3 client: {{WatsonxData.DEFAULT_SERVICE_URL}} is 
> {{https://region.lakehouse.cloud.ibm.com/lakehouse/api/v3}}, and the SDK 
> appends v3 paths such as {{/catalogs}} or {{/presto_engines}} to the service 
> URL.
> Proposed change: use {{/lakehouse/api/v3}} in the examples (the option 
> description already does).
> _Claude Code on behalf of davsclaus_



--
This message was sent by Atlassian Jira
(v10.3.26#10030026)

Reply via email to