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

   ## Description
   
   [CAMEL-24961](https://issues.apache.org/jira/browse/CAMEL-24961)
   
   `azure-eventgrid` was the last of the 415 catalog components without body 
types. CAMEL-26093 only registered it in the catalog after the components had 
been done.
   
   The body types, checked at runtime against `BinaryData.fromObject` of 
azure-core 1.57.0:
   
   - **producerIn:** a Map, a POJO or a List. The body is the data of the 
CloudEvent, serialized to JSON by the Azure SDK.
     - A Map or a POJO becomes a JSON object, and a number a JSON number.
     - Text becomes a JSON string and is not parsed, so JSON text must be 
unmarshalled first.
     - Bytes become a base64 string, a stream an empty object, and a file its 
path.
     - A List is sent as one event per element, and no body fails.
   - **producerOut:** unchanged. Publishing gives no result and sets no header.
   
   ### Found while checking, not fixed here
   
   The producer builds each event with `new CloudEvent("/camel", type, 
BinaryData.fromObject(data), null, null)`. azure-core 1.57.0 throws 
`NullPointerException: 'format' cannot be null when 'data' isn't null` for 
every body, so every send fails before it reaches Azure. The module's only 
test, `EventGridComponentTest`, configures endpoints and never sends. The 
constructor call has been there since the component was added (CAMEL-20552).
   
   _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