metal solos eh...
When you listen to the music.. can't you tell that much of it is just spontaneous? Not so much as improvised, but there is no certain rule or range of notes or rhythms to metal solos.. that's what makes.. metal solos..
Sometimes, it doesn't fit, it doesn't sound right, if you grew up with it, you might not be able to experience this, but sometimes.. metal just doesn't make any musical sense (the more modern stuff) .. but that in itself is part of the "beauty" of it.
In the end, you just gotta go crazy and like thrasher! said much of it comes from just trying licks, improvising, and polishing them to the right tone.
There are few bands like.. Metallica (ahem.. mainstream metal) who writes their solos.. and you can tell right away that somebody wrote those lines.
Also.. techniques are needed.. such as.. fast alternate picking, tapping, double-tapping, sweep picking, bends, lots of times - crazy trem actions.. and attitude.. those metallists all have.
Man.. if SteveVai had that attitude.. he'd be the craziest metal guitarists.. but he's too much of an artist, all about character.. not that it's a bad thing