sorrycc / roadhog

🐷 Cli tool for creating react apps, configurable version of create-react-app.
2.72k stars 342 forks source link

加入websocket代理后crash #876

Open yoyo837 opened 5 years ago

yoyo837 commented 5 years ago

Environment(required) | 环境(必填)

  // 注释掉ws代理就没事
  proxy: {
    '/websocket/socketServer.do': {
      target: 'http://localhost:8080/',
      changeOrigin: true,
      ws: true,
    },
    '/v3': {
      target: 'http://localhost:8080/',
      changeOrigin: true,
    },
  },

What do you expected?(预期的正常效果)

正常代理websocket

What happen?(发生了何种非正常现象)

dev server crash

Error: read ECONNRESET at TCP.onStreamRead (internal/stream_base_commons.js:111:27)

Re-producible online demo (可复现的在线demo)