A few years ago I remember I read a book series that I really liked.
The main character was the last of his race (I can’t remember what gender the main character was or the race but I thing it were elves).
There was a huge war between two countries.
The main character became a dragon rider, but the dragon he/she got didn't like her, at least at first.
There was some kind of super dark magic.