Heat the oil in a stockpot over medium heat. Add the leeks, carrots and celery and sauté for 5 minutes. Add the garlic, salt, pepper, and sauté for another minute, then add the broth and tomatoes, raise the heat to medium high, and bring to a simmer. Add the potatoes and lower to heat to medium, keeping the broth at a simmer, and cook the potatoes until they start to soften, about 8 minutes.
Meanwhile, make the pesto if using. Place the basil, parsley, garlic, olive oil, lemon juice and salt in a food processor or blender. Puree until well blended. Add the Parmesan and pulse to combine.
Add the peas, asparagus, cabbage and thyme and simmer until the vegetables are crisp-tender, about 4 minutes. Taste and adjust seasoning.
Ladle into bowls and serve hot or warm, with a dollop of the pesto swirled in if desired.