Combine all ingredients in a medium saucepan and bring to a simmer over medium heat. Reduce the heat to low, cover, and simmer for 1 to 1 1/2 hours. Remove cloves, cinnamon stick, and star anise. Serve warm or cool with pork or lamb dishes, or as topping for ice cream. Store in an airtight container with a lid in the refrigerator for up to 2 weeks.