{"action":"closed","issue":{"url":"https://api.github.com/repos/webpack/webpack-dev-server/issues/161","labels_url":"https://api.github.com/repos/webpack/webpack-dev-server/issues/161/labels{/name}","comments_url":"https://api.github.com/repos/webpack/webpack-dev-server/issues/161/comments","events_url":"https://api.github.com/repos/webpack/webpack-dev-server/issues/161/events","html_url":"https://github.com/webpack/webpack-dev-server/issues/161","id":70523620,"number":161,"title":"Proxy is extermely slow","user":{"login":"grahamb","id":146111,"avatar_url":"https://avatars.githubusercontent.com/u/146111?v=3","gravatar_id":"","url":"https://api.github.com/users/grahamb","html_url":"https://github.com/grahamb","followers_url":"https://api.github.com/users/grahamb/followers","following_url":"https://api.github.com/users/grahamb/following{/other_user}","gists_url":"https://api.github.com/users/grahamb/gists{/gist_id}","starred_url":"https://api.github.com/users/grahamb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/grahamb/subscriptions","organizations_url":"https://api.github.com/users/grahamb/orgs","repos_url":"https://api.github.com/users/grahamb/repos","events_url":"https://api.github.com/users/grahamb/events{/privacy}","received_events_url":"https://api.github.com/users/grahamb/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-04-23T21:59:06Z","updated_at":"2015-04-23T23:43:51Z","closed_at":"2015-04-23T23:43:51Z","body":"I am using the `proxy` option to proxy API requests while using webpack-dev-server. The proxy is extremely slow, to the point where it's useless. I'm trying to test a type-ahead component, and proxying the API request is resulting in 5+ second response times.\r\n\r\nwebpack-dev-server: 1.8.2\r\nnode: 0.12.2\r\n\r\nRequest through proxy: 5.08 seconds\r\n![screen shot 2015-04-23 at 14 55 14](https://cloud.githubusercontent.com/assets/146111/7308379/c99218ca-e9c8-11e4-90a0-2e34d77b6ae0.png)\r\n\r\nRequest direct to API endpoint: 0.03 - 0.06 seconds\r\n![screen shot 2015-04-23 at 14 54 58](https://cloud.githubusercontent.com/assets/146111/7308388/d853dc68-e9c8-11e4-8164-e109d9348673.png)\r\n\r\nMy `webpack.config.js` is below:\r\n\r\n```javascript\r\nconst webpack = require('webpack');\r\nconst path = require('path');\r\nconst config = require('config');\r\nconst hostname = config.get('dev_server_hostname');\r\nconst port = config.get('dev_server_port');\r\n\r\nvar pragmas = new webpack.DefinePlugin({\r\n  __DEV__: 'true',\r\n  __CANVAS_API_TOKEN__: JSON.stringify(config.get('api_token'))\r\n});\r\n\r\nmodule.exports = {\r\n  devtool: 'eval',\r\n\r\n  entry: [\r\n    'webpack-dev-server/client?http://' + hostname + ':' + port,\r\n    'webpack/hot/only-dev-server',\r\n    './src/js/index.js',\r\n  ],\r\n\r\n  output: {\r\n    filename: 'canvas_spaces.js',\r\n    path: './dist',\r\n    publicPath: 'http://' + hostname + ':' + port + '/dist/'\r\n  },\r\n\r\n  module: {\r\n    loaders: [\r\n      {\r\n        test: /\\.js$/,\r\n        loaders: ['react-hot', 'babel-loader'],\r\n        include: path.join(__dirname, 'src')\r\n      },\r\n      {\r\n        test: /\\.scss$/,\r\n        loader: \"style!css!sass\"\r\n      }\r\n    ]\r\n  },\r\n\r\n  plugins: [\r\n    pragmas,\r\n    new webpack.HotModuleReplacementPlugin(),\r\n    new webpack.NoErrorsPlugin(),\r\n    new webpack.ProvidePlugin({\r\n      'es6-promise': 'es6-promise',\r\n      'fetch': 'imports?this=>global!exports?global.fetch!whatwg-fetch'\r\n    })\r\n  ],\r\n\r\n  resolve: {\r\n    extensions: ['', '.js', '.jsx'],\r\n    root: __dirname + '/src/js'\r\n  },\r\n\r\n  devServer: {\r\n    hot: true,\r\n    host: hostname,\r\n    port: port,\r\n    historyApiFallback: true,\r\n    proxy: {\r\n      '/api/v1/*': config.get('api_proxy'),\r\n      '/font/*': config.get('api_proxy'),\r\n    }\r\n  }\r\n}\r\n\r\n```"}}