Announcement Announcement Module
Collapse
No announcement yet.
How dump exception logs in ListFieldstemapper into execution context Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • How dump exception logs in ListFieldstemapper into execution context

    how to use execution context to dump bad records logged at ListFieldSetmapper
    ListFieldSetMapper.java:-

    Code:
    public class ListFieldSetMapper implements FieldSetMapper<ListItem>{
    public ListItem mapFieldSet(FieldSet fs) {

    ------------
    -------
    }
    }Here I'm reading various columns of each row using corresponding data types supported by FieldSet. This class is also catching exceptions for bad records, with unmatched data types. I want to log this stuff and dump it into ExecutionContext, with the key by name "logFile". The same logFile is used at writer level of step1 and also in step2.
    I implemented InitializingBean interface, and tried to initialize ExecutonContext in the same way, I did for writer class of step1, but it is throwing null pointer exception.
    How can I initialize ExecutionContext to dump log file here in ListFieldSetMapper?.
    Please suggest
    Thanks

  • #2
    I replied on the other thread: http://forum.springsource.org/showth...t=71470&page=2

    Comment

    Working...
    X