Giter Club home page Giter Club logo

spinx's Introduction

spinx

A golang fastcgi proxy client.

quick start

go get github.com/lwl1989/spinx
cd $gopath/src/github.com/lwl1989/spinx
go build
./spinx

Please input your config path(default /usr/etc/spinx/server.json):

change log

2018-5-14

1. add handler coroutine
2. add logger(handler.SetLogger(log))

config.json demo

{
    "server": {
        "port": "8081",
        "log": "/tmp/spinx.log",
        "keep_alive_timeout": 3,
        "gzip_level": 1,
        "cache": {
            "len": 10240,
            "expire": "24h"
        }
    },

    "vhosts": [
        {
            "name": "www.test.com wwww.aaa.com",
            "port": "18000",
            "proxy":"127.0.0.1:9000",
            "documentRoot": "/www/web/wordpress",
            "tryFiles": "/index.php?$uri",
            "index":  "index.php index.html"
        },
        {
            "name": "www.phpmyadmin.com",
            "port": "18000",
            "proxy":"127.0.0.1:9000",
            "documentRoot": "/www/web/phpmyadmin",
            "tryFiles": "/index.php?$uri"

        }
    ]
}

The next Step

  1. ssl support
  2. channel add
  3. keepalive support

ab test

new version test(wordpress):

Server Software:        spinx
Server Hostname:        www.test.com
Server Port:            18000

Document Path:          /
Document Length:        53302 bytes

Concurrency Level:      100
Time taken for tests:   20.158 seconds
Complete requests:      1000
Failed requests:        0
Total transferred:      53507000 bytes
HTML transferred:       53302000 bytes
Requests per second:    49.61 [#/sec] (mean)
Time per request:       2015.799 [ms] (mean)
Time per request:       20.158 [ms] (mean, across all concurrent requests)
Transfer rate:          2592.17 [Kbytes/sec] received
==========================================================
Server Software:        nginx/1.13.9
Server Hostname:        www.test.com
Server Port:            18000

Document Path:          /
Document Length:        53302 bytes

Concurrency Level:      100
Time taken for tests:   20.277 seconds
Complete requests:      1000
Failed requests:        0
Total transferred:      53548000 bytes
HTML transferred:       53302000 bytes
Requests per second:    49.32 [#/sec] (mean)
Time per request:       2027.685 [ms] (mean)
Time per request:       20.277 [ms] (mean, across all concurrent requests)
Transfer rate:          2578.95 [Kbytes/sec] received
=============================================================
Performance has caught up with nginx.

contact

qq 285753421

email [email protected]

wechat contact me with wechat

spinx's People

Contributors

lwl1989 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.