batchee-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alonso Gonzalez (JIRA)" <j...@apache.org>
Subject [jira] [Created] (BATCHEE-48) ItemProcessListener.onProcessError() gets called with 'processedItem' instead of 'itemRead'
Date Thu, 24 Jul 2014 07:49:40 GMT
Alonso Gonzalez created BATCHEE-48:
--------------------------------------

             Summary: ItemProcessListener.onProcessError() gets called with 'processedItem'
instead of 'itemRead'
                 Key: BATCHEE-48
                 URL: https://issues.apache.org/jira/browse/BATCHEE-48
             Project: BatchEE
          Issue Type: Bug
    Affects Versions: 0.2-incubating
            Reporter: Alonso Gonzalez


In case of an exception, ChunkStepController calls ItemProcessListener.onProcessError with
'processedItem'. But processedItem will be always 'null' unless the process method finishes
without an exception.

The specification states that 'the item about to be processed' should be passed:
{quote}
/**
* The afterProcess method receives control after an item
* processor processes an item. The method receives the item processed
* and the result item as an input.
* @param item specifies the item about to be processed.
* @param ex specifies the exception thrown by the item processor.
* @throws Exception
*/
public void onProcessError(Object item, Exception ex) throws Exception;
{quote}

(Obviously the first part of the JavaDoc has been accidentally copied from the 'afterProcess'
method.)



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Mime
View raw message