You can setup multiple troops to be trained depending on the size of your barracks. If your barracks is level 4 for example you can schedule 4 batches of troops to be trained. If your barracks is level 9 you can queue up 9 batches of troops to be trained. Similarly if you are building defenses on your walls you can schedule multiple batches of defenses to be built. The number of batches you can use on walls is based on the level of the walls.
I feel that it is best to queue up batches of troops in small quantities. That way you always have new troops becoming available. You might train 300 Archers or 100 ATs at a time. That way every hour you have new troops or new defenses available and you can schedule 4 or 8 or 12 or 24 hours worth of troops to be trained. This also gives you small boosts in Prestige as each new batch of 100 troops is completed. (Training smaller batches of troops no longer gives a prestige boost.)
One of the worst feelings in the world is when you queue up 10,000 troops to be trained and get attacked. You can’t use any of those troops and it takes hours to complete the building process. Another problem is when you have 10000 archers training and you discover you need to get maybe 10000 scouts instead. You either have to cancel the archers or wait until they finish training. It’s a lot easier to cancel 100 troops and possibly loose some resources than canceling 10,000.