Dual power rb5009ug+s+in

Can you use both the barrel jack and the 2 pin header to power the rb5009ug+s+in for redundancy?

Yes.
As far as I know that even work with all Mikrotiks that feature both ports. But don’t quote me on that.

You can also use the Poe in.

It will choose the input with highest voltage

Yes and no, the way Mikrotik double power input works is that the higher voltage of the two wins.

So it is not a particularly smart idea to power in both ports with two “same” voltage power supplies, without having thoroughly checked that both power supplies are very stable and have not fluctuating (as effect of load) voltage.

Otherwise there is the risk that the device will continuously (or at least too often) switch from the one power supply to the other and viceversa in cycles.

There should be at least a couple volts of difference in voltage between the two sources to make sure that one is “main” and the other is “spare”:

For the DC inputs Mikrotik uses an arrangements of one input diode per dc input with the cathodes joined, which serves as the input to the buffer capacitor and then the smps. Using the same voltage is therefore fine. (I have deployed many devices which do not have dual inputs with the single input powered by two power supplies connected through two diodes. Works fine. You just don’t want to connect power supplies directly to each other - for several reasons actually.)

The fine print: DC power supplies in general are so-called “unconditionally stable” supplies (i.e. they are stable on the entire right side of the load impedance plane) There are some really crappy ones that do not have this behavior, these are rare. There are power supplies that are meant only as chargers (phone chargers, power banks, etc.) that are not guaranteed to work well in these situations.

Fine print no. 2: The PoE input behaves a little differently in this regard. If PoE is applies first, then DC and the DC is taken away, the device will go on. If the order is reversed, that is the DC power is applied first then PoE, then in some circumstances the device will reboot before resuming operation from PoE. (This has to do with the sensing/negotiation for PoE.)

YES you can use dual power inputs.
Note , the DC input with the highest voltage will be the one that is actively used and carries the entire load.

( and just to clarify , this is not power supply load sharing , it is highest voltage to the board carries the load ).