To the remaining caramelized onions, add the lentils, 3 cups of the water, orange juice and zest, star anise, cinnamon stick, bay leaf, ground cardamom and allspice.
Season with ½ teaspoon of salt, then raise the heat and bring to a boil.
Cover, lower the heat to a simmer and cook until the lentils are tender and most of the water has absorbed, 35 to 40 minutes.
When the lentils are ready, add the rice, black-eyed peas and remaining 1½ cups of water.
Cover and simmer until the rice is done, about 15 minutes.
Remove from the heat and let sit, covered, for 5 minutes, before removing the lid and fluffing with a fork.
Add the reserved caramelized onions, then taste and adjust the seasoning as needed. Makes about 7 cups mujadara.