With some periods of interruption, China dominated Vietnam for more than 10 centuries between 111 BC and 938 AD. This wikipedia article and its subsidiary links spoke of sinification and shifting of resources from the occupied population to the occupiers. Then, can there be a ethnic / genetic sense to claim that the people who ruled Vietnam between 938 AD to 1407 AD was ``Vietnamese''? That is, did an ethnic Vietnamese identity already exist start the domination in 111BC and did this identity persist in the liberation force against the Chinese in 938 AD and the group of people who ruled Vietnam until 1407 AD?
Clarification: when the "Americans" fought for the American Independence, they were "Americans" by their own declarations but they were mostly ethnic British. Of course, over time, the culture diverged, waves of immigration and interbreeding happened. But my understanding is that at the end of the 18th century, the liberation of the US was done by mostly a group of Brits against another of group of Brits. It was not, for example, mostly a collation of native Americans against the Brits.
So I'm trying to draw a similar distinction here: the people who fought off Chinese rule of Vietnam and went on to rule that latter country for the next few centuries: were they ethnic Chinese for the most part or they were mostly descendants of the original population at the start of the occupation in 111 BC or something in between?