Increase heat to medium-high. Add onion, celery and carrot to pot, and sauté 3 minutes, or until tender. Add sherry, scraping bottom to loosen any browned bits. Cook 2 minutes, or until sherry is nearly evaporated. Stir in lentils. Add stock, water, thyme and juniper berries, and bring to a boil. Reduce heat, cover, and simmer 1 hour, or until lentils are tender, stirring occasionally. Season to taste with salt and pepper.