I personally think the book is an exploration of what a militaristic society would look like if faced by a external threat, and that it should be taken at face value, but there are plenty of critics who have read more books than I have with much less favourable interpretations.
tl;dr - Heinlein ain’t that smart