Dual AC feed to power a DC unit (Raspberry Pi) with Diode and Polyfuse for protection
Given the relatively low cost of a Raspberry Pi, this could be one approach:


Power the Pi with an off-the-shelf online charger -->> battery pack -->> UBEC such as used in remote control model aircraft. This provides a regulated voltage from the UBEC output, takes care of charging and safeguards for the battery, and also, with some chargers, will provide a visual alert when the battery has aged beyond a specified extent.
Power the charger through any failover mechanism of choice from both raw power lines.
Set up two such independent Pi + power units, in separate racks, to duplicate each other's function - since the RPi is not an industrial reliability product, failure during continuous operation is not unlikely.
Incorporate remote heartbeat code on each RPi, polled from your central Network Operations Center or equivalent, so the failure of any RPi generates an alert on the monitoring panel.