It could be connected to a timer but generally AC pumps are not controllable, control of an AC motor requires complex electronics that regulate Hz and V precisely and they have to be designed specifically to the motor being used and this generally costs more than a DC pump and is not very sensical as you have all the costs, but none of the added safety of low voltage. If the pump does not restart, the most common issue is that it is dirty, this pump is very low wattage, it is similar to a very small car engine in that regard, very fuel efficient, but it doesn't have the oomph to overcome an obstacle, it is critical that the pump is cleaned regularly. Every 4-6 months the motor should be removed, the impeller and impeller cover removed, the nipple for air inlet on the impeller cover cleaned of salt creep and the motor and impeller cleaned so no lime scale remains. If it does not restart when clean, the impeller is likely bad, weak magnet, broken, etc.