What is the maximum amount of diamonds in one vein?
Solution 1:
Diamond ore appears in veins of 3-8. As said by the Minecraft wiki and also by personal experience.
Diamond ore only appears at Y level 16 and below, and can be found in veins of 3–8.
Source: Minecraft Wiki
Solution 2:
Due to how Minecraft vein generation works, it is possible to find veins with up to 10 diamonds even though the max vein size is 8.