Using spring batch config how to send a mail and how to configure in the job
<p>I need to send a mail using spring batch configs.in the mail having the status of the mail(It's success or failure) now am able to read data from csv and write into the Database.after write into the database i need to send a mail.
please any one suggest to me
this is my java config file job configuration</p>

<pre><code>return jobs.get("insertIntoDbFromCsvJob")
            .start(readRegistrations())
                .build();
    }
</code></pre>

<p>here is am readRegistrations() step is read data from csv and write into the database.
now i need to send a mail if that step is succec or failure.</p>