Spring boot @Scheduled and @SchedulerLock || Use of ShedLock for multi instance environment In Hindi

preview_player
Показать описание
Lock @Scheduled Tasks With ShedLock and Spring Boot using @SchedulerLock and mysql database with multiple application instances.
#springboot #springboot #ShedLock #Scheduled #SchedulerLock #EnableSchedulerLock

ShedLock for Spring Boot solves a very common problem, which occurs when running scheduled jobs in your application when deployed with a high availability setup into a production environment. You might be ending up with multiple job executions at the same time.
Рекомендации по теме
Комментарии
Автор

Please provide your feedback so that i know, where i need to improve. Please like share and subscribe.

karlecoding
Автор

Can you please make vedio on How to get cron expression value from database and added in @Schedule

mithunbhadra
Автор

Wow nicely explained bro.

I have an issue on production side.
There are 2 instances are running and client complaining he is getting duplicate notification (email).

I have created a cron job which runs every 30 sec.
I kept lockAtMostFor = 20sec
and lockAtLeastFor = 10sec

I am pretty much sure that my cron job taking more than 30 seconds as i checked in database.

As i kept lockAtMostFor =20sec and my cron job taking more than 30 seconds, is that means my 2nd instance pick the same record and he also sending the same notification to the recipient.

How to handle this situation i mean duplicate notification being sent

rahimkhan-fhdd
Автор

How to make cron expression database drivem, with an real-time example

mithunbhadra
Автор

could you provide how we unlock or release lock ?

l.r.sharma
Автор

Do we need to create the table with the same table name and column name. I have created a different name (as per my project standard) and it is not working. Can you please clarify on this?

sivakarthikperiyasamy
Автор

bhai yr urgent ek doubt tha..monday production release hai...we have 2 instance at qa env and same build is deployed there and now 1 instance is terminated but everytime that terminated instance is keep acquiring the lock in shedlock table . jiski vajah se that cron job never run. Can you please help why this might be happening?
When both the instances were up and running, everything was working as expected.

raghavsidana