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

   # Description
   
   Part of [CAMEL-23832](https://issues.apache.org/jira/browse/CAMEL-23832). 
The umbrella ticket stays open.
   
   ## Summary
   
   This PR rewrites the component description and the texts of 17 endpoint 
options of `hwcloud-imagerecognition` (the
   component has no headers in its metadata). The new texts say what each value 
is, which exchange property replaces it
   (`CamelHwCloudImageContent`, `CamelHwCloudImageUrl`, 
`CamelHwCloudImageTagLanguage`, `CamelHwCloudImageTagLimit`,
   `CamelHwCloudImageThreshold`), how `accessKey` and `secretKey` fall back to 
`serviceKeys`, and the default threshold of
   each operation (60 for tagRecognition, 0.48 for celebrityRecognition).
   
   Corrections of wrong texts:
   
   - `region` said that only cn-north-1 and cn-north-4 are supported. The SDK 
(huaweicloud-sdk-image 3.1.225) also knows
     ap-southeast-1, ap-southeast-3 and cn-east-3, so the text now says that 
the producer looks the endpoint of the region
     up in the SDK.
   - `imageContent` and `imageUrl` said that `imageContent` takes precedence. 
The producer sends both to the service when
     both are set; the new texts say so.
   - `imageUrl` was cut into list fragments without separators and referred to 
a Huawei page that is not linked.
   
   Sources: the Camel code (`ImageRecognitionEndpoint`, 
`ImageRecognitionProducer`) and huaweicloud-sdk-image 3.1.225
   (`ImageRegion`, `ImageTaggingReq`, `CelebrityRecognitionReq`).
   
   ### Found, not changed
   
   - `accessKey` and `secretKey` are marked as required, although the producer 
takes them from `serviceKeys` when they are
     not set.
   - `region` is marked as required, although it is not used when `endpoint` is 
set.
   - `operation` and `tagLanguage` have no `enums` in the metadata 
(celebrityRecognition, tagRecognition; zh, en).
   - The five exchange properties are not in the component metadata; they 
appear only in a hand-written table of the doc
     page, which gives `CamelHwCloudImageThreshold` the type `Integer`, while 
the producer reads it as a `Float`.
   - The component has the category `MESSAGING` besides `CLOUD`, which does not 
fit an image recognition service.
   - The producer builds the client configuration for every message and fails 
without access key, secret key and project
     ID, even when an `ImageClient` is set on the endpoint with 
`setImageClient`.
   
   ## Tests
   
   - There is no new test, as only description text changes.
   - A script compared the component JSON with the parent commit: only 
`description` fields changed (18 texts).
   
   # Target
   
   - [x] I checked that the commit is targeting the correct branch (Camel 4 
uses the `main` branch)
   
   # Tracking
   
   - [x] If this is a large change, bug fix, or code improvement, I checked 
there is a [JIRA issue](https://issues.apache.org/jira/browse/CAMEL) filed for 
the change (usually before you start working on it).
   
   # Apache Camel coding standards and style
   
   - [x] I checked that each commit in the pull request has a meaningful 
subject line and body.
   - [x] I ran the formatter and built the module, then regenerated the catalog 
copy, `dsl/camel-endpointdsl` and `dsl/camel-componentdsl`, and committed all 
generated changes.
   
   # AI-assisted contributions
   
   - [x] If this PR includes AI-generated code, commits have proper 
co-authorship attribution (e.g., `Co-authored-by` trailers) and the PR 
description identifies the AI tool used.
   
   _Claude Code on behalf of davsclaus_
   
   🤖 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