Claus Ibsen created CAMEL-27856:
-----------------------------------

             Summary: camel-aws-parameter-store: a wrongly cased type or tier 
is sent as "null", a missing operation gives NullPointerException
                 Key: CAMEL-27856
                 URL: https://issues.apache.org/jira/browse/CAMEL-27856
             Project: Camel
          Issue Type: Bug
          Components: camel-aws
            Reporter: Claus Ibsen
             Fix For: 4.25.0


Found while improving the option descriptions of camel-aws-parameter-store for 
CAMEL-23832 (pull request https://github.com/apache/camel/pull/31144).
These are separate problems of the component; the descriptions change only 
documents the current behavior.

h4. 1. A wrongly cased type or tier is sent as "null"
{{ParameterStoreProducer.putParameter}} uses ParameterType.fromValue / 
ParameterTier.fromValue, which are case-sensitive; "string" or "advanced" 
becomes UNKNOWN_TO_SDK_VERSION, whose toString() "null" is sent, and AWS 
answers with a misleading validation error.
Proposed change: pass the string with builder.type(String) / tier(String), or 
fail early listing the valid values.

h4. 2. A missing operation gives NullPointerException
With no operation option or header, determineOperation returns null and the 
switch throws NullPointerException.
Proposed change: throw IllegalArgumentException("operation must be specified").


_Claude Code on behalf of davsclaus_



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

Reply via email to