1. If using dried beans, soak them overnight or do a quick soak (boil for 2 minutes, then remove them from the heat and let soak for 1 hour).
2. In a medium saucepan over moderate heat, cover the presoaked beans with 2 inches of water and cook until tender, about 30 minutes. Add 1¼ cup water, bring to a boil, then add the barley. Lower the heat and simmer for 45 minutes. Set aside.
(If using canned beans, wait to add them to the soup until step 4.)
3. In a large saucepan over moderate heat, warm the olive oil. Add the onion, carrots and celery, and sauté, stirring occasionally, until translucent, about 5 minutes. Add the zucchini and green beans and sauté until beginning to soften, about 3 minutes. Add the potato and sauté, stirring occasionally, for 3 minutes.
4. Add 6 cups of water and the tomato sauce, raise the heat, and bring the soup to a boil. Lower the heat and simmer for 20 minutes. Add the beans and barley and continue to simmer for 5 more minutes. Season with salt, and purée with an immersion blender, if desired.