There is every reason to believe that Epicurus and his friends complied with their military service.
Yes, as we know Herodotus wrote a book (Περὶ Ἐπικούρου ἐφηβείας), Hicks translates this tile On the Training of Epicurus as a Cadet. The new Oxford edition translates it very literally On Epicurus' Ephebic Training, and explains simply "in ancient Athens, young men of citizen status were required to undergo military training."
But of course he did not go as far as Plato, who "went on service three times, first to Tanagra, secondly to Corinth, and thirdly at Delium, where also he obtained the prize of valour." (DL 3.8)