Claus Ibsen created CAMEL-27833:
-----------------------------------

             Summary: camel-aws2-translate: a String 
CamelAwsTranslateTerminologyNames header is ignored
                 Key: CAMEL-27833
                 URL: https://issues.apache.org/jira/browse/CAMEL-27833
             Project: Camel
          Issue Type: Bug
          Components: camel-aws2
            Reporter: Claus Ibsen
             Fix For: 4.25.0


Found while improving the option descriptions of camel-aws2-translate for 
CAMEL-23832 (pull request https://github.com/apache/camel/pull/31141).
This is a separate problem of the component; the descriptions change only 
documents the current behavior.

h4. A String terminology header is ignored
{{Translate2Producer.translateText}} reads the header with 
getHeader(TERMINOLOGY_NAMES, Collection.class); a String (one name, or "a,b") 
converts to null, so the header is dropped without notice (confirmed with a 
test). A String[] or a List works.
Proposed change: also accept a String (one name or comma-separated), or fail 
with a clear error.


_Claude Code on behalf of davsclaus_



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

Reply via email to