In a saucepan, combine plum preserves, vinegar, shallots, brown sugar, garlic, ginger, pepper flakes, and 5-spice powder, and stir to combine. Bring to a boil. Stir, reduce the heat and simmer until thickened and the flavors are married, 4 to 5 minutes. Remove the plum sauce from the heat and adjust the seasoning, to taste. Let cool to room temperature.