The word "Vlach" is etymologically derived from the ethnonym of a Celtic tribe, adopted into Proto-Germanic *Walhaz which meant "stranger", from *Wolka- (Caesar's Latin: Volcae, Strabo and Ptolemy's Greek: Ouolkai).  Via Latin, in Gothic, as *walhs, the ethnonym took on the meaning "foreigner" or "Romance-speaker", and was adopted into Greek Vlahi (Blakhoi), Slavic Vlah, Hungarian olah and olasz, etc. The root word was notably adopted in Germanic for Wales and Walloon (German: Welsch), and in Poland Wlochy became an exonym for Italians. Via both Germanic and Latin, the term started to signify "stranger, foreigner" also in the Balkans, where it in its early form was used for Romance-speakers, but the term eventually took on the meaning of "shepherd, nomad". The Romance-speaking communities themselves however used the endonym (they called themselves) "Romans". During the early history of the Ottoman Empire in the Balkans, there was a social class of Vlachs in Serbia and Macedonia, made up of Christians who served as auxiliary forces and had the same rights as Muslims. In Croatia, the term became derogatory, and Vlasi was used for the ethnic Serb community.  Romanian scholars have suggested that the term Vlach appeared for the first time in the Eastern Roman Empire and was subsequently spread to the Germanic- and then Slavic-speaking worlds through the Norsemen (possibly by Varangians), who were in trade and military contact with Byzantium during the early Middle Ages (see also Blakumen).  The term "Vlach" is used in scholarship for the Romance-speaking communities in the Balkans, especially those in Greece, Albania and Macedonia.

Answer this question "Was it considered derogative?" by extracting the answer from the text above.
In Croatia, the term became derogatory, and Vlasi was used for the ethnic Serb community.