GithubHelp home page GithubHelp logo

skill's Introduction

依赖库:

go get -u gopkg.in/ini.v1

go get -u github.com/kataras/iris

go get -u github.com/jinzhu/gorm 

go get -u github.com/unknwon/com

go get -u github.com/streadway/amqp

服务端优化思路

image-20200512092901398

分布式验证

Wrk 压测工具安装

  • 安装

    • 在 centos 7 上执行 git clone https://github.com/wg/wrk

    • 进入 wrk 目录: cd wrk

    • 执行安装命令 : make

    • 使用介绍

      Usage: wrk <options> <url>                            
        Options:                                            
          -c, --connections <N>  Connections to keep open   
          -d, --duration    <T>  Duration of test           
          -t, --threads     <N>  Number of threads to use   
                                                            
          -s, --script      <S>  Load Lua script file       
          -H, --header      <H>  Add header to request      
              --latency          Print latency statistics   
              --timeout     <T>  Socket/request timeout     
          -v, --version          Print version details      
                                                            
        Numeric arguments may include a SI unit (1k, 1M, 1G)
        Time arguments may include a time unit (2s, 2m, 2h)
        
      -------
      使用方法: wrk <选项> <被测HTTP服务的URL>                            
        Options:                                            
          -c, --connections <N>  跟服务器建立并保持的TCP连接数量  
          -d, --duration    <T>  压测时间           
          -t, --threads     <N>  使用多少个线程进行压测   
                                                            
          -s, --script      <S>  指定Lua脚本路径       
          -H, --header      <H>  为每一个HTTP请求添加HTTP头      
              --latency          在压测结束后,打印延迟统计信息   
              --timeout     <T>  超时时间     
          -v, --version          打印正在使用的wrk的详细版本信息
                                                            
        <N>代表数字参数,支持国际单位 (1k, 1M, 1G)
        <T>代表时间参数,支持时间单位 (2s, 2m, 2h)
      
      

      image-20200519110239657

  • 只支持 UNIX 系统

  • 能用少量的线程测大量的链接

  • htop 监控工具

    htop使用详解

    yum instll -y htop
    使用: htop

    image-20200515160315108

skill's People

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.