Pretty well every time I've heard it sung or seen it in print or record there's the suggestion that it dates back to the Peasants' Revolt in the Fourteenth Century. But I've never seen any indication of whether there's any basis for this, and where the suggestion first emerged.