I am using a write behind mapstore in my cache and I noticed that if the db call fails the thread will retry 3 times then print stacktrace and then repeat indefinitely.
Is there anyway we can handle this properly? or at least some way to inject some code so the admins are notified? Right now I didn't know about it until I open up my log file.
Yes, current behavior is retrying failed entries. There are plans already in place to add a retry limit for Mapstore operations in the upcoming versions.
As a workaround you can catch the specific exception thrown in your MapStore implementation so those objects are skipped.