You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "James Netherton (JIRA)" <ji...@apache.org> on 2018/02/27 08:13:00 UTC

[jira] [Assigned] (CAMEL-12293) Avoid KeyAlreadyExistsException in ManagedTypeConverterRegistry.listTypeConverters()

     [ https://issues.apache.org/jira/browse/CAMEL-12293?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

James Netherton reassigned CAMEL-12293:
---------------------------------------

    Assignee: James Netherton

> Avoid KeyAlreadyExistsException in ManagedTypeConverterRegistry.listTypeConverters()
> ------------------------------------------------------------------------------------
>
>                 Key: CAMEL-12293
>                 URL: https://issues.apache.org/jira/browse/CAMEL-12293
>             Project: Camel
>          Issue Type: Improvement
>          Components: camel-core
>            Reporter: James Netherton
>            Assignee: James Netherton
>            Priority: Minor
>
> There is a JMX operation on the TypeConverterRegisty to fetch a list of converters.
>  
> The TabularData object that's returned is keyed on the 'from' type name and 'to' type name. This mostly works ok. But you could have multiple converters which handle the same 'from' and 'to' types. In this case a KeyAlreadyExistsException exception is thrown when adding CompositeData to TabularData.
>  
> We could avoid this by using a simple 'index' field in the CompositeData ,which could just be a simple number we increment each time around the type converter list loop.
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)