BackendStack21 / fast-gateway

Fast-gateway is an easy to use Node.js API gateway framework built to handle large scale API traffic with great performance and scalability. Written with JavaScript, it is a framework for the masses!
MIT License
311 stars 34 forks source link

3.97 RPS ? #31

Closed zuohuadong closed 4 years ago

zuohuadong commented 4 years ago

ab -c 20 -n 10000 http://127.0.0.1:8080/

const service = require('restana')()
service.get('/', (req, res) => res.send('Hello World!'))

service.start(3000)
const gateway = require('fast-gateway')
const server = gateway({
  routes: [{
    prefix: '/',
    target: 'http://127.0.0.1:3000'
  }]
})

server.start(8080)
jkyberneees commented 4 years ago

Hi @zuohuadong , I guess you are missing some details and explanations here. Can you please use https://github.com/giltene/wrk2 instead of ab, as the last does not support HTTP 1.1, neither high concurrency levels.

You can consider the following test scripts: https://github.com/jkyberneees/fast-gateway/tree/master/benchmark

Thanks.