{"action":"created","issue":{"url":"https://api.github.com/repos/felixge/node-mysql/issues/987","labels_url":"https://api.github.com/repos/felixge/node-mysql/issues/987/labels{/name}","comments_url":"https://api.github.com/repos/felixge/node-mysql/issues/987/comments","events_url":"https://api.github.com/repos/felixge/node-mysql/issues/987/events","html_url":"https://github.com/felixge/node-mysql/issues/987","id":56927892,"number":987,"title":"script trying to insert 12 million registers one by one","user":{"login":"Muriloo","id":5303413,"avatar_url":"https://avatars.githubusercontent.com/u/5303413?v=3","gravatar_id":"","url":"https://api.github.com/users/Muriloo","html_url":"https://github.com/Muriloo","followers_url":"https://api.github.com/users/Muriloo/followers","following_url":"https://api.github.com/users/Muriloo/following{/other_user}","gists_url":"https://api.github.com/users/Muriloo/gists{/gist_id}","starred_url":"https://api.github.com/users/Muriloo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Muriloo/subscriptions","organizations_url":"https://api.github.com/users/Muriloo/orgs","repos_url":"https://api.github.com/users/Muriloo/repos","events_url":"https://api.github.com/users/Muriloo/events{/privacy}","received_events_url":"https://api.github.com/users/Muriloo/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/felixge/node-mysql/labels/question","name":"question","color":"d4c5f9"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":6,"created_at":"2015-02-07T22:01:52Z","updated_at":"2015-03-09T03:32:42Z","closed_at":"2015-03-09T03:32:42Z","body":"Hi,\r\n\r\nMy team wrote an script that will make 12 million requests to server, which would take 2 or 3 days to process (taking into account only the request time) and for each request we need to loop over the answers inserting several rows for each request.\r\n\r\nWe're currently using a pool with 15 connections, but when we get around the request of number 1 million we've core dump of the server (probably due to using more memory than available). We'll try to use V8 monitors to find where is the issue, but I'd like to understand a bit better how would the nodejs event loop handle all those requests, and also how the connection pool handle it.\r\n\r\nI'd appreciate if you could give me an insight about it, suggest some other method to safely store the records, or recommend some material to read.\r\n\r\nThank you for your time, and I'm sorry for any wrong thing I might have said."},"comment":{"url":"https://api.github.com/repos/felixge/node-mysql/issues/comments/77795523","html_url":"https://github.com/felixge/node-mysql/issues/987#issuecomment-77795523","issue_url":"https://api.github.com/repos/felixge/node-mysql/issues/987","id":77795523,"user":{"login":"dougwilson","id":67512,"avatar_url":"https://avatars.githubusercontent.com/u/67512?v=3","gravatar_id":"","url":"https://api.github.com/users/dougwilson","html_url":"https://github.com/dougwilson","followers_url":"https://api.github.com/users/dougwilson/followers","following_url":"https://api.github.com/users/dougwilson/following{/other_user}","gists_url":"https://api.github.com/users/dougwilson/gists{/gist_id}","starred_url":"https://api.github.com/users/dougwilson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dougwilson/subscriptions","organizations_url":"https://api.github.com/users/dougwilson/orgs","repos_url":"https://api.github.com/users/dougwilson/repos","events_url":"https://api.github.com/users/dougwilson/events{/privacy}","received_events_url":"https://api.github.com/users/dougwilson/received_events","type":"User","site_admin":false},"created_at":"2015-03-09T03:32:42Z","updated_at":"2015-03-09T03:32:42Z","body":"Hi @Muriloo I'm going to close this issue since the last activity was a while ago, but please feel free to post comments on here or even open new issues if needed :)"}}