{"action":"opened","issue":{"url":"https://api.github.com/repos/ivanceras/rustorm/issues/17","labels_url":"https://api.github.com/repos/ivanceras/rustorm/issues/17/labels{/name}","comments_url":"https://api.github.com/repos/ivanceras/rustorm/issues/17/comments","events_url":"https://api.github.com/repos/ivanceras/rustorm/issues/17/events","html_url":"https://github.com/ivanceras/rustorm/issues/17","id":119270783,"number":17,"title":"Platform should be Clonable","user":{"login":"JeanDenisVIDOT","id":5817251,"avatar_url":"https://avatars.githubusercontent.com/u/5817251?v=3","gravatar_id":"","url":"https://api.github.com/users/JeanDenisVIDOT","html_url":"https://github.com/JeanDenisVIDOT","followers_url":"https://api.github.com/users/JeanDenisVIDOT/followers","following_url":"https://api.github.com/users/JeanDenisVIDOT/following{/other_user}","gists_url":"https://api.github.com/users/JeanDenisVIDOT/gists{/gist_id}","starred_url":"https://api.github.com/users/JeanDenisVIDOT/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JeanDenisVIDOT/subscriptions","organizations_url":"https://api.github.com/users/JeanDenisVIDOT/orgs","repos_url":"https://api.github.com/users/JeanDenisVIDOT/repos","events_url":"https://api.github.com/users/JeanDenisVIDOT/events{/privacy}","received_events_url":"https://api.github.com/users/JeanDenisVIDOT/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-11-28T04:39:43Z","updated_at":"2015-11-28T04:39:43Z","closed_at":null,"body":"Hi, as i wrote in the title, Platform should be Clonable if we want to use it with threads like the following example:\r\n\r\n```\r\npub fn start(&self) -> bool {\r\n    let address = self.hostname.to_string() + \":\" + &self.port.to_string();\r\n    let listener = TcpListener::bind(&*address).unwrap();\r\n    let url = \"mysql://root:root@localhost/database\";\r\n    let pool = ManagedPool::init(&url, 1).unwrap();\r\n    let db = pool.connect().unwrap();\r\n\r\n    for stream in listener.incoming() {\r\n        match stream {\r\n            Ok(mut stream) => {\r\n                thread::spawn(move|| {\r\n                    handle_client(db, &mut stream);\r\n                });\r\n            },\r\n            Err(e) => {\r\n                println!(\"{}\", e);\r\n                return false;\r\n            }\r\n        }\r\n    }\r\n}\r\n```\r\nError:\r\n```\r\nerror: capture of moved value: `db` [E0382]\r\nhelp: perhaps you meant to use `clone()`?\r\n```\r\nI wanted to create a pull request but to do that, we have to do a pull request for r2d2 also (i guess)"}}