If you are logged in with A Samsung account you can remote unlock the device. Google "Remote unlock samsung phone" , and look for a Samsung website.Google account allows you to do something similar provided you had the right settings turned on before...
I would suggest considering exporting older conversations and saving them somewhere and then cleaning up some of the conversations. Delete old media, messages etc. Also delete any old backups that might be stored on Drive or the device, and keep only...
As a last resort, if the clear cache doesn't work, clear the app data, you'll lose chats if they are not backed up. But that normally does the trick and gets the app working again.