Sentence:  He also met Count Rumford ( born Benjamin Thompson in Woburn, Mass . ) who was then <WSD>serving</WSD> the Elector of Bavaria , and the physicist Ritter ; these were Oersted 's main contacts in science . 
Meaning of the word marked with <WSD> tags:  devote (part of) one's life or efforts to, as of countries, institutions, or ideas