ES and CQRS not working correctly with Mysql post application restart

We have a lagom Microservice that has ES and CQRS implemented along with MYSQL database. Whenever the database is empty and we are performing operations very first time then Readside procesoor performs fine and all entries go to database and get persisted. But when we restart the service, the Readside processor behaves inconsistently. It sometimes adds entries in database and sometimes it fails to add the entries. We have waited for a long time, to ensure that this is not due to the eventually consistent nature of ES and CQRS. But that does not look like the case, those missed entries never reach the database.