Place the ham bone in a large Dutch oven or stockpot. Add 6 cups of water and bring to a bare simmer over medium heat. Simmer for at least 1 hour, skimming off foam or impurities with a slotted spoon.
Add diced onion (if using), black pepper, and parsley flakes. Stir gently with a wooden spoon. Remove the ham bone and shred any remaining meat into bite-sized pieces. Return the shredded meat to the broth.
In a medium mixing bowl, combine the flour, cornmeal, and black pepper. In a small bowl, whisk the egg, melted butter, and 1 cup of ham broth until smooth. Gradually add the wet ingredients to the dry ingredients, stirring until a moist dough forms.
Using a tablespoon, scoop the dumpling batter and gently drop it into the simmering broth. Repeat until all the dough is used. Simmer for 10 minutes, allowing the dumplings to puff up.
Ladle the soup into bowls, garnish with optional green onions or a splash of lemon juice, and serve warm.