A sewage ejector pump and/or a sump pump both use a float switch to turn the pump on and off. It is common for the switches to fail. Sometimes stuff in the basin can also stop the float from moving freely, which will prevent the switch from operating properly.
If the pump is running and not pumping any liquids, it will cause it to fail prematurely. I would fix the switch immediately, as it would be a lot cheaper that replacing a burned-out pump.