cancel
Showing results for 
Search instead for 
Did you mean: 

cronjob always shows status as running

Former Member
0 Kudos

i am following this trail https://wiki.hybris.com/display/tr52/Trail+~+CronJobs when i click on start job , status shows as running and not receing email. can someone help on this. not even getting error also.

Former Member
0 Kudos

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi,

Can you try activating "https://www.google.com/settings/security/lesssecureapps" for the gmail account which you are using?

I could send emails without any issues. Did you do the below steps,

Open the cuppy-section and edit a player Set the newsletter-attribute to true. Change the eMail address of this player to your email address. It seems the condition might not be satisfied.

If the above doesnot solve your problem You can add below code replacing the existing one in perform method of ranking job to check email is working fine.

 final PlayerModel player = new PlayerModel(); 
 player.setUid("uidtest"); 
 player.setEMail("xxx@gmail.com");
  mailService.sendConfirmationMail(player); 
 return new PerformResult(CronJobResult.SUCCESS, CronJobStatus.FINISHED);

This does not contain any condition. If you execute cronjob it will send confirmation email. Let me know if you face any issues.

Thanks,

Jayahar

Former Member
0 Kudos

yes i have done the changes.still i am not getting email.pls help on this

Former Member
0 Kudos

Are you in corporate network? Did you check your spam as well. In the meantime I will try to incorporate the same in my local and come up with the update if I find any.

Former Member
0 Kudos

i checked my spam also. pls try and help

Former Member
0 Kudos

I could send emails. Did you do the below steps,

Open the cuppy-section and edit a player Set the newsletter-attribute to true Change the eMail address of this player to your email address It seems the condition might not be satisfied or You can below code replacing the existing one in perform method of ranking job to check email is working fine. final PlayerModel player = new PlayerModel(); player.setUid("uidtest"); player.setEMail("xxx@gmail.com"); mailService.sendConfirmationMail(player); return new PerformResult(CronJobResult.SUCCESS, CronJobStatus.FINISHED);

Former Member
0 Kudos

I have updated my answer. Request you to check and let me know if you face any issues.