I'm just designing a smart home system.
Do you use a MQTT connection to the controller?
ESP8266 memory is enough. You can add a communication check to the controller (for example, a request for the current time). And then you can restart SIM800L through an external pin on the module, and you can also restart ESSP8266.