Two Wii u's. Two Minecraft discs. Two tvs. same house
Solution 1:
Your sons must be friends with one another on their Wii U's through the Miiverse. According to this Reddit:
You have to add friends to play with them. You can add them in your friends list or through Miiverse!
You should be able to configure all of this on the Wii U itself, but if not, you can use the Miiverse link above.
Once they are friends with one another, they should be able to invite each other to one of their games and play together. From what I'm reading, they will need to be using an HD TV each, as well as supported Wii Controllers (Wii U gamepad, Wii U Pro controller, or Wii Classic controller).
According to this article the multiplayer is free (I wasn't sure since I don't have the console). As pointed out in comments, this is for all online multiplayer across all games on the Wii U.