{"action":"created","issue":{"url":"https://api.github.com/repos/cnpm/cnpmjs.org/issues/909","repository_url":"https://api.github.com/repos/cnpm/cnpmjs.org","labels_url":"https://api.github.com/repos/cnpm/cnpmjs.org/issues/909/labels{/name}","comments_url":"https://api.github.com/repos/cnpm/cnpmjs.org/issues/909/comments","events_url":"https://api.github.com/repos/cnpm/cnpmjs.org/issues/909/events","html_url":"https://github.com/cnpm/cnpmjs.org/issues/909","id":153069221,"number":909,"title":"Request timeouts almost every day","user":{"login":"glen-84","id":261509,"avatar_url":"https://avatars.githubusercontent.com/u/261509?v=3","gravatar_id":"","url":"https://api.github.com/users/glen-84","html_url":"https://github.com/glen-84","followers_url":"https://api.github.com/users/glen-84/followers","following_url":"https://api.github.com/users/glen-84/following{/other_user}","gists_url":"https://api.github.com/users/glen-84/gists{/gist_id}","starred_url":"https://api.github.com/users/glen-84/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/glen-84/subscriptions","organizations_url":"https://api.github.com/users/glen-84/orgs","repos_url":"https://api.github.com/users/glen-84/repos","events_url":"https://api.github.com/users/glen-84/events{/privacy}","received_events_url":"https://api.github.com/users/glen-84/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2016-05-04T17:22:53Z","updated_at":"2016-05-05T10:55:24Z","closed_at":null,"body":"Almost every day we get the following:\r\n\r\n```\r\nSync packages from official registry failed.\r\nStart sync time is Mon May 02 2016 10:06:38 GMT+0000 (UTC).\r\nError message is ResponseTimeoutError: Request timeout for 300000ms, GET https://registry.npm.taobao.org/-/short 200 (connected: true, keepalive socket: false, agent status: {\"createSocketCount\":4,\"closeSocketCount\":4,\"errorSocketCount\":0,\"timeoutSocketCount\":0,\"requestCount\":3,\"freeSockets\":{},\"sockets\":{},\"requests\":{}})\r\nheaders: {\"date\":\"Mon, 02 May 2016 10:02:06 GMT\",\"content-type\":\"application/json; charset=utf-8\",\"content-length\":\"4711183\",\"connection\":\"keep-alive\",\"etag\":\"\\\"47e30f-sAIl+yDS3z2Vzu6oJL0izQ\\\"\",\"x-readtime\":\"2992\"} (sync package error)\r\nResponseTimeoutError: Request timeout for 300000ms, GET https://registry.npm.taobao.org/-/short 200 (connected: true, keepalive socket: false, agent status: {\"createSocketCount\":4,\"closeSocketCount\":4,\"errorSocketCount\":0,\"timeoutSocketCount\":0,\"requestCount\":3,\"freeSockets\":{},\"sockets\":{},\"requests\":{}})\r\nheaders: {\"date\":\"Mon, 02 May 2016 10:02:06 GMT\",\"content-type\":\"application/json; charset=utf-8\",\"content-length\":\"4711183\",\"connection\":\"keep-alive\",\"etag\":\"\\\"47e30f-sAIl+yDS3z2Vzu6oJL0izQ\\\"\",\"x-readtime\":\"2992\"} (sync package error)\r\nat Timeout._onTimeout (/con/home/cnpm/node_modules/urllib/lib/urllib.js:647:13)\r\nat tryOnTimeout (timers.js:224:11)\r\nat Timer.listOnTimeout (timers.js:198:5).\r\n```\r\n\r\nToday we got:\r\n\r\n```\r\nSync packages from official registry failed.\r\nStart sync time is Wed May 04 2016 10:05:26 GMT+0000 (UTC).\r\nError message is JSONResponseFormatError: Unexpected end of input (data json format: \"[\\\"0\\\",\\\"0.0\\\",\\\"0.workspace\\\",\\\"00\\\",\\\"001\\\",\\\"001_skt\\\",\\\"001_test\\\",\\\"003\\\",\\\"007\\\",\\\"008-somepackage\\\",\\\"009\\\",\\\"00k-node\\\",\\\"01\\\",\\\"01-simple\\\",\\\"0126af95c0e2d9b0a7c78738c4c00a860b04acc8\\\",\\\"03\\\",\\\"04uppercase\\\",\\\"06_byvoidmodule\\\",\\\"06_cli_applications_using_nodejs\\\",\\\"0815\\\",\\\"09aac0b7d986b720253a65a47d1fd3d9\\\",\\\"0card-images-helper\\\",\\\"0flux\\\",\\\"0latency\\\",\\\"0model\\\",\\\"0s\\\",\\\"0x\\\",\\\"0x21\\\",\\\"0x23\\\",\\\"0xff\\\",\\\"1\\\",\\\"1-1-help-desk-system\\\",\\\"1-click-bom\\\",\\\"1-liners\\\",\\\"1-wire-js\\\",\\\"1.0.1\\\",\\\"1.0.2\\\",\\\"10\\\",\\\"100\\\",\\\"100-prisoners\\\",\\\"101\\\",\\\"101-es6\\\",\\\"101-tomekwi\\\",\\\"10119-dep\\\",\\\"101\" ...skip... \"k\\\",\\\"azuma-test-githook\\\",\\\"azumio\\\",\\\"azuqua\\\",\\\"azura\\\",\\\"azure\\\",\\\"azure-ad-jwt\\\",\\\"azure-ad-jwt-cache\\\",\\\"azure-ad-jwt-mod\\\",\\\"azure-angular-providers\\\",\\\"azure-api\\\",\\\"azure-arm-apiapp\\\",\\\"azure-arm-authorization\\\",\\\"azure-arm-batch\\\",\\\"azure-arm-cdn\\\",\\\"azure-arm-commerce\\\",\\\"azure-arm-compute\\\",\\\"azure-arm-datalake-analytics\\\",\\\"azure-arm-datalake-store\\\",\\\"azure-arm-dns\\\",\\\"azure-arm-hdinsight\\\",\\\"azure-arm-hdinsight-jobs\\\",\\\"azure-arm-insights\\\",\\\"azure-arm-intune\\\",\\\"azure-arm-keyvault\\\",\\\"azure-arm-network\\\",\\\"azure-arm-rediscache\\\",\\\"azure-arm-res\"), GET https://registry.npm.taobao.org/-/short 200 (connected: true, keepalive socket: false, agent status: {\"createSocketCount\":6,\"closeSocketCount\":6,\"errorSocketCount\":0,\"timeoutSocketCount\":0,\"requestCount\":5,\"freeSockets\":{},\"sockets\":{},\"requests\":{}})\r\nheaders: {\"date\":\"Wed, 04 May 2016 10:02:07 GMT\",\"content-type\":\"application/json; charset=utf-8\",\"content-length\":\"4727619\",\"connection\":\"keep-alive\",\"etag\":\"\\\"482343-iBRdOfOAKh31CUDt8vPatg\\\"\",\"x-readtime\":\"2597\"} (sync package error)\r\nJSONResponseFormatError: Unexpected end of input (data json format: \"[\\\"0\\\",\\\"0.0\\\",\\\"0.workspace\\\",\\\"00\\\",\\\"001\\\",\\\"001_skt\\\",\\\"001_test\\\",\\\"003\\\",\\\"007\\\",\\\"008-somepackage\\\",\\\"009\\\",\\\"00k-node\\\",\\\"01\\\",\\\"01-simple\\\",\\\"0126af95c0e2d9b0a7c78738c4c00a860b04acc8\\\",\\\"03\\\",\\\"04uppercase\\\",\\\"06_byvoidmodule\\\",\\\"06_cli_applications_using_nodejs\\\",\\\"0815\\\",\\\"09aac0b7d986b720253a65a47d1fd3d9\\\",\\\"0card-images-helper\\\",\\\"0flux\\\",\\\"0latency\\\",\\\"0model\\\",\\\"0s\\\",\\\"0x\\\",\\\"0x21\\\",\\\"0x23\\\",\\\"0xff\\\",\\\"1\\\",\\\"1-1-help-desk-system\\\",\\\"1-click-bom\\\",\\\"1-liners\\\",\\\"1-wire-js\\\",\\\"1.0.1\\\",\\\"1.0.2\\\",\\\"10\\\",\\\"100\\\",\\\"100-prisoners\\\",\\\"101\\\",\\\"101-es6\\\",\\\"101-tomekwi\\\",\\\"10119-dep\\\",\\\"101\" ...skip... \"k\\\",\\\"azuma-test-githook\\\",\\\"azumio\\\",\\\"azuqua\\\",\\\"azura\\\",\\\"azure\\\",\\\"azure-ad-jwt\\\",\\\"azure-ad-jwt-cache\\\",\\\"azure-ad-jwt-mod\\\",\\\"azure-angular-providers\\\",\\\"azure-api\\\",\\\"azure-arm-apiapp\\\",\\\"azure-arm-authorization\\\",\\\"azure-arm-batch\\\",\\\"azure-arm-cdn\\\",\\\"azure-arm-commerce\\\",\\\"azure-arm-compute\\\",\\\"azure-arm-datalake-analytics\\\",\\\"azure-arm-datalake-store\\\",\\\"azure-arm-dns\\\",\\\"azure-arm-hdinsight\\\",\\\"azure-arm-hdinsight-jobs\\\",\\\"azure-arm-insights\\\",\\\"azure-arm-intune\\\",\\\"azure-arm-keyvault\\\",\\\"azure-arm-network\\\",\\\"azure-arm-rediscache\\\",\\\"azure-arm-res\"), GET https://registry.npm.taobao.org/-/short 200 (connected: true, keepalive socket: false, agent status: {\"createSocketCount\":6,\"closeSocketCount\":6,\"errorSocketCount\":0,\"timeoutSocketCount\":0,\"requestCount\":5,\"freeSockets\":{},\"sockets\":{},\"requests\":{}})\r\nheaders: {\"date\":\"Wed, 04 May 2016 10:02:07 GMT\",\"content-type\":\"application/json; charset=utf-8\",\"content-length\":\"4727619\",\"connection\":\"keep-alive\",\"etag\":\"\\\"482343-iBRdOfOAKh31CUDt8vPatg\\\"\",\"x-readtime\":\"2597\"} (sync package error)\r\nat Object.parse (native)\r\nat parseJSON (/con/home/cnpm/node_modules/urllib/lib/urllib.js:733:24)\r\nat /con/home/cnpm/node_modules/urllib/lib/urllib.js:606:23\r\nat decodeContent (/con/home/cnpm/node_modules/urllib/lib/urllib.js:471:14)\r\nat IncomingMessage. (/con/home/cnpm/node_modules/urllib/lib/urllib.js:587:7)\r\nat emitNone (events.js:85:20)\r\nat IncomingMessage.emit (events.js:179:7)\r\nat endReadableNT (_stream_readable.js:913:12)\r\nat _combinedTickCallback (internal/process/next_tick.js:74:11)\r\nat process._tickCallback (internal/process/next_tick.js:98:9).\r\n```\r\n\r\nIs there any way to improve the connection? Our server is in the US."},"comment":{"url":"https://api.github.com/repos/cnpm/cnpmjs.org/issues/comments/217124492","html_url":"https://github.com/cnpm/cnpmjs.org/issues/909#issuecomment-217124492","issue_url":"https://api.github.com/repos/cnpm/cnpmjs.org/issues/909","id":217124492,"user":{"login":"drsect0r","id":9106228,"avatar_url":"https://avatars.githubusercontent.com/u/9106228?v=3","gravatar_id":"","url":"https://api.github.com/users/drsect0r","html_url":"https://github.com/drsect0r","followers_url":"https://api.github.com/users/drsect0r/followers","following_url":"https://api.github.com/users/drsect0r/following{/other_user}","gists_url":"https://api.github.com/users/drsect0r/gists{/gist_id}","starred_url":"https://api.github.com/users/drsect0r/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/drsect0r/subscriptions","organizations_url":"https://api.github.com/users/drsect0r/orgs","repos_url":"https://api.github.com/users/drsect0r/repos","events_url":"https://api.github.com/users/drsect0r/events{/privacy}","received_events_url":"https://api.github.com/users/drsect0r/received_events","type":"User","site_admin":false},"created_at":"2016-05-05T10:55:24Z","updated_at":"2016-05-05T10:55:24Z","body":"@dead-horse Is there maybe some load balancing doing some magic? I did a traceroute from Europe (Malta) and the traffic seems to be routed to/trough Singapore.\r\n\r\n```\r\nmtr --report-wide registry.cnpmjs.org\r\n                                                     Loss%   Snt   Last   Avg  Best  Wrst StDev\r\n...\r\n  6.|-- ae-0-11.bar1.Milan1.Level3.net                0.0%    10   38.8  37.8  35.3  42.6   2.5\r\n  7.|-- 4.68.71.58   \r\n  8.|-- if-ae-1-2.tcore1.FR0-Frankfurt.as6453.net     0.0%    10  288.0 290.6 287.4 293.2   1.8\r\n  9.|-- if-ae-4-2.tcore2.FNM-Frankfurt.as6453.net     0.0%    10  302.3 304.5 301.3 313.6   3.7\r\n 10.|-- if-ae-9-2.tcore1.PVU-Paris.as6453.net         0.0%    10  293.8 293.3 291.3 296.0   1.7\r\n 11.|-- if-ae-2-2.tcore1.PYE-Paris.as6453.net         0.0%    10  299.6 300.0 297.8 303.5   1.8\r\n 12.|-- if-ae-8-1600.tcore1.WYN-Marseille.as6453.net  0.0%    10  297.4 294.4 292.5 297.8   1.8\r\n 13.|-- if-ae-9-6.tcore1.MLV-Mumbai.as6453.net        0.0%    10  288.2 286.9 281.9 292.7   3.8\r\n 14.|-- if-ae-2-2.tcore2.MLV-Mumbai.as6453.net        0.0%    10  291.1 289.2 287.8 291.1   0.9\r\n 15.|-- if-ae-16-2.tcore1.SVW-Singapore.as6453.net    0.0%    10  298.3 295.6 293.4 298.3   1.7\r\n 16.|-- 180.87.12.50                                  0.0%    10  303.0 304.1 302.8 306.2   0.9\r\n 17.|-- 116.251.66.25                                 0.0%    10  296.1 297.1 294.4 301.7   2.3\r\n 18.|-- ???                                          100.0    10    0.0   0.0   0.0   0.0   0.0\r\n 19.|-- 47.88.189.193                                 0.0%    10  291.6 293.8 291.6 297.3   1.8\r\n\r\n```"}}