Hi

I have created a ticket to add such a feature in the future
https://issues.apache.org/activemq/browse/CAMEL-2830


On Sat, Jun 12, 2010 at 5:48 PM, Claus Ibsen <[email protected]> wrote:
> Hi
>
> You can split into single records and process the records one by one.
> Then the failed can be moved to a DLC and the good can continue.
>
>
> On Wed, Jun 9, 2010 at 3:01 PM, DSailor <[email protected]> wrote:
>>
>> My use case says I should process a set of records - delivered via file.
>> If any of the records has one of more fields which cannot be unmarshalled
>> (example: text field which cannot be converted to Integer), then, the record
>> should be placed in an exception queue (EIP pattern - Dead Letter Channel).
>> Records which can be unmarshalled should continue processing.
>>
>> To my knowledge, Bindy will unmarshall my file into an object
>> List<Map<String, Object>>.
>> If my file has a bad record, I get an exception and processing is rolled
>> back - Example of exception:  java.lang.IllegalArgumentException: String
>> provided does not fit the Integer pattern defined or is not parseable,
>> position : 1, line : 5
>>
>> How can I continue processing of the "good" records ?
>>
>> One option I see is to make all attributes of my csvRevord class as String
>> and run a validation and transformation afterwards on the object created by
>> Bindy. This approach, unfortunatelly, does not leverage the usage of
>> conversion provided by Bindy - csv text attribute converted automatically to
>> a Date object if attribute is of type Date.
>>
>> Any other option ?
>>
>> Thanks in advance.
>> --
>> View this message in context: 
>> http://old.nabble.com/Bindy---CsvRecord---handling-bad-records-on-batch-processing-tp28830072p28830072.html
>> Sent from the Camel - Users mailing list archive at Nabble.com.
>>
>>
>
>
>
> --
> Claus Ibsen
> Apache Camel Committer
>
> Author of Camel in Action: http://www.manning.com/ibsen/
> Open Source Integration: http://fusesource.com
> Blog: http://davsclaus.blogspot.com/
> Twitter: http://twitter.com/davsclaus
>



-- 
Claus Ibsen
Apache Camel Committer

Author of Camel in Action: http://www.manning.com/ibsen/
Open Source Integration: http://fusesource.com
Blog: http://davsclaus.blogspot.com/
Twitter: http://twitter.com/davsclaus

Reply via email to