[
https://issues.apache.org/jira/browse/CAMEL-26426?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Work on CAMEL-26426 started by Adriano Machado.
-----------------------------------------------
> camel-core - AbstractExchange: a field for TO_ENDPOINT and a lazily created
> internal properties map
> ---------------------------------------------------------------------------------------------------
>
> Key: CAMEL-26426
> URL: https://issues.apache.org/jira/browse/CAMEL-26426
> Project: Camel
> Issue Type: Sub-task
> Reporter: Adriano Machado
> Assignee: Adriano Machado
> Priority: Major
>
> Tier 1 item #3 of CAMEL\-25132. Every exchange allocates an EnumMap with a
> backing array for all the ExchangePropertyKey constants, which is most of the
> size of a new DefaultExchange and is cloned by every copy. Creating the map
> lazily saves nothing on its own, as TO\_ENDPOINT is set on every send, so
> TO\_ENDPOINT gets a dedicated field and the map is only created when another
> key is set. Prototyped in the ticket at about \-312 bytes per exchange on
> normal routes, CPU neutral. Split and multicast items and exchanges with
> other internal keys, such as CHARSET\_NAME, still use the map.
> AbstractExchange is package\-private and its two subclasses are final, so
> this is not a public API change.
> _Claude Code on behalf of Adriano Machado \(@ammachado\)_
> _This was generated by an AI agent and may contain inaccuracies. Please
> verify before relying on it._
--
This message was sent by Atlassian Jira
(v10.3.26#10030026)