Preheat the oven to 190°C/375°F/gas mark 5. Butter a 20cm springform cake tin and line the base with baking parchment.
Beat the butter and the 125g of caster sugar until pale and fluffy. Add the eggs a little at a time, beating well after each addition. If the mixture starts to curdle, add one tablespoon of the flour. Put the lemon thyme leaves in a mortar with the lemon zest and pound together to release the fragrance. Add to the batter and briefly mix.
Fold in the rest of the flour, the almonds and the baking powder, using a large metal spoon. Scrape into the tin. Toss the gooseberries with the remaining five tablespoons of caster sugar and spread over the top. Bake for 30 minutes. The cake is ready when a skewer inserted into the centre comes out clean.
To make the syrup, quickly heat the granulated sugar, lemon juice and lemon thyme leaves in a saucepan, stirring to help the sugar dissolve. Pierce the cake all over with a skewer while it is still warm and slowly pour the syrup into it. Leave to cool a little, then carefully remove from the tin and put on a serving plate.
Meanwhile, make the poached gooseberries. Heat 175ml of water, the granulated sugar and lemon thyme together in a saucepan, stirring until the sugar has dissolved. Add the gooseberries and cook over a medium heat for four minutes, or until the fruit is soft but not collapsing (most of the berries should still hold their shape). Leave to cool.
Any thyme flowers you have will look lovely on top of the cake. You can leave it as it is, or dust lightly with icing sugar just before serving, with sweetened crème fraîche or whipped cream and the poached gooseberries on the side.