Found the issue with my setup
/dev/md127 isn’t the valid device. I need to use /dev/mapper/md127.
# swapon -d=once /dev/mapper/md127
# cat /proc/swaps
Filename Type Size Used Priority
/dev/dm-0 partition 8379388 0 -2