I read a flat file (for example a .csv file with 1 line per User, Ex: UserId,age,rate,marks). Below is example
user1,27,good,1111111
user2,56,fair,222222
user1,28,good,333333
So as per above data Item processor should pass user object at row 2 & row 3 to item writer. But how to handle duplicated User item in the item processor (where last entry of duplicate user given precedence or should be pass to itemwriter)