Put the oil in a large pot or Dutch oven over medium-high heat.
Add the chopped onion and cook, stirring occasionally, until softened, about 3-4 minutes. 2.
Add the chopped apples, a generous pinch of salt, and lots of black pepper.
Continue cooking and stirring until the apples begin to release their juices, about 3 minutes more.
Reduce the heat to low and let the mixture cook, stirring occasionally, until the onions and apples are deeply golden and caramelized, about 15 to 20 minutes. This step builds a sweet foundation of flavor. 3.
Raise the heat to medium-high and add the drained sauerkraut.
Cook, stirring frequently, until the mixture is quite dry and just begins to stick to the bottom of the pot, about 10 to 15 minutes.
Don't skip this step—it toasts the kraut and deepens its flavor. 4.
Pour in the vegetable stock, using a wooden spoon to scrape up any flavorful browned bits from the bottom of the pot. 5.
Stir in the millet (if using), bay leaves, cloves, and juniper berries (if using).
Bring the soup to a boil, then immediately reduce the heat to low.
Cover and let it simmer gently until the sauerkraut and grains are very tender, about 20 to 25 minutes. 6.
Before serving, carefully remove and discard the bay leaves, cloves, and juniper berries.
Taste the soup and adjust the seasoning with more salt and pepper if needed.
Serve hot and enjoy!