Re: Written in the UK and finally in the dustbin of history.
It's older than that. The, AFAIK, first mention of data retention were a series of propositions in Sweden in the late 90's, when the Swedish Police argued that ISP's should be forced to retain all traffic indefinitely, so the police could go on fishing expeditions in the data. The original bugbear the police wanted to slay were people who slandered celebrities on-line, a big problem in those days (according to the tabloids). Sweden, however, instead outlawed the mentioning of any person's name on the internet without that person's written consent (yes, really). The police didn't give up, and subsequent iterations of the proposition motivated the dire need for police to be able to search everyone's internet activities with, in order, piracy, pedophilia and hate speech.
The proposition started getting traction after 9/11, with terrorism as the new bugbear, and got bumped from being a national concern to the EU level after the Madrid bombing.
The rest is history (and really, really, bad legislation).