Preheat oven to 250℉.
Wash jars in hot water, pat dry, put onto a sheet pan and place in the heated oven. (If you have a silicone liner, that helps keep them from being wobbly.)
Put rings and lids into a pot on the stove top and simmer.
In a 3-4 quart pot, add the sugar, water, vinegar, garlic, and salt and bring to a boil. Reduce heat and simmer for 3-4 minutes.
Slice the jalapeño peppers and set aside.
Slice the serrano peppers and set aside.
Add the jalapeño peppers to the brine, return to a boil then reduce and simmer for 3-4 minutes, stirring occasionally.
Remove the jars from the oven and add a piece of serrano to each as well as 3-4 peppercorns.
Use a slotted spoon -- or a spider -- spoon the peppers into prepared jars. (Having a jar-funnel helps. Just saying.)
Bring brine back to a boil and boil for 3-5 minutes.
Pour over the peppers and let cool.
Wipe the rims, add a lid, and a finger-tight ring. These should seal by themselves in short order but if they haven't, add to a hot water canner and boil for 3-5 minutes.
Refrigerate any jars that don't seal.