The first reference to a 'Dutch wife' -- in anything but the literal sense -- appears to be a reference in a 1857 account of an Englishman's travels in Java1, in which the author discovers a hard, long bolster cushion in his bed. Upon asking on its use, he is told that it is a "Dutch wife", and is used to put your arms and legs over when you sleep, to reduce contact with the mattress and to increase air circulation -- a sleep aid to Europeans in insufferably hot climes. These were reported again in another travelogue of Singapore in 18832 using the same name, so it appears they were fairly widespread.
1. Harper's Magazine, Volume 15, June 1857
2. Sunny Lands and Seas, Hugh Wilkinson, 1883