One of the problems that sometimes happens in books and stories that are heavy on allegory is that the writer forgets that not all the characters should feel the same way about the issue.
For example one of the few episodes of law and order I have seen was a very thinly veiled anti-gun message. The things was that every character felt the same way about the message, that guns were bad (for anyone who was not law enforcement obviously) to carry.
Even if most of them feel that way, having everyone have exactly the same views on a contentious issue just does not make sense. Even if they feel in general the same maybe one thinks that pistols are okay, but nothing larger. Maybe another thinks that anyone who goes through a long training process and has no criminal history is okay. You could even have two people agree on the end result but disagree on why.
It can come off as trying to pass off an opinion as a universal fact. Done well an allegory convinces people by letting them see a new point of view or by the use of reason.
Allegories don’t work just by having all the main characters say they feel the same way about an issue.