If someone were going to compose a piece of military music to especially rousing, what components would they be looking to emphasize? Like is there a certain key or time that military music is often played in that makes it especially rousing? What components of the brass section would the composer emphasize? I feel like the trombone and snare drums are instruments often emphasized; are there any others? Basically, are there any heuristics a composer might use if commissioned by some government to make young men willingly go into battle?
It sounds like you're specifically referring to marches written for military band.
The idiom was largely defined by John Philip Sousa, who wrote 136 marches and conducted the U.S. Marine Band for a number of years in the late 19th century.
Military marches are typically in 2/4 time and are driven by traditional marching snare drum beats. This is a big part of what makes them "rousing," as both characteristics encourage those who hear it to get on their feet and march. The tempo also usually matches this (q = 110-120). Marches are composed in all different keys (though some keys, like Eb, Bb, and F are more comfortable for inexperienced bands).
If you want to train your ear for this style of music, just head on over to YouTube and type in John Philip Sousa. You'll get dozens of recordings of many of his pieces sharing similar characteristics.
You mentioned the trombone section--Sousa typically uses them to lead the low brass/low reed sections in countermelodies or B strains. Brass writing is typically very "fanfarish," making use of ideas you would hear from a bugle call. (A natural horn's harmonic series.)
Ensemble writing rarely increases beyond three parts (melody, countermelody, bass). A military march is typically also composed in some sort of A-B-A form, starting in major, material like a trio or "dogfight" in the middle, and then back to the opening theme for a major ending.
The "dogfight" is a typically very exciting section. In "The Stars and Stripes Forever," it is in a minor key and led by the trombones. There are a few rhythmic patterns that are quite common in upbeat marches. If you want to become familiar with them, I would again encourage you to seek out and study some recordings of Sousa marches and/or find some detailed analyses written about them. "The Stars and Stripes Forever" is widely considered one of Sousa's best works, and would be well worth a listen or two.
U.S. Marine Band: The Stars and Stripes Forever
The characteristics of a Military march that are especially rousing are a strong bass line (Usually following an "octave hammering" style similar to ragtime) which drives the rhythm of the piece. The drum line supports the octave hammer and elaborates on the off-beat. i.e. the drum line will accent the first beat of the bar and play the more complex rhythms on the off beats (the upbeat of eighth notes and the second beat of the bar in 2/4.) This is to be viewed as a support of the octave hammer. The melody will be rather forceful- Motzart described it as "alla turca" literally meaning "With fire", and even Sousa required a quite forceful approach to the melody, though it backs off a bit in spots. Another thing we have that makes the march style distinct is the robust use of the brass section- think "big and bold". Big Band borrows this principle.