Download the PHP package xcorp1986/zhttp without Composer

On this page you can find all versions of the php package xcorp1986/zhttp. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package zhttp

zhttp-用来做http web服务的异步非阻塞轻量级框架

开发交流群:384013097

新手入门项目,附有源码和线上实例(主要用于介绍)

https://github.com/keaixiaou/zhttptest/

最新框架依赖环境docker镜像已经发布,拉取方法(内置mongodb扩展、memcached扩展、swoole扩展1.9包括异步redis)

使用手册(待完善)

http://gitbook.jeekzx.com/

协议

MIT license

优势

1.框架基于swoole开发,并且一些IO操作底层已经封装为异步,性能极其强悍。
2.框架底层已经封装好异步,内置mysql、redis连接池,只需要在调用的时候在前面加yield,近乎同步的写法,却是异步的调用,并且无需关注底层实现,连接数超等问题,使用非常简单。

注意事项

1.框架最新加入协程+mysql连接池,非阻塞的mysql查询大大提高了框架应对请求的吞吐量
2.php版本需要7.0+
3.swoole版本1.8.*
4.如果用到异步redis,需要安装hiredis,安装教程:http://wiki.swoole.com/wiki/page/p-redis.html

安装依赖包

composer install
1.没有安装composer的先安装composer
2.不会composer或者不喜欢composer的可以直接去我另一个资源库下载框架依赖,地址:https://github.com/keaixiaou/zphp

运行zhttp

本框架只支持http模式:
运行:
cd 到根目录
php webroot/main.php start|stop|restart|reload|status
访问IP:PORT
建议:
    如果是静态文件如css、js、image,可以直接用nginx代理
    如果是动态请求,最好使用nginx做代理转发

服务监控图

服务监控

本机裸跑输出

ab测试(配置:MacBook Air 8G内存,双核,I5)

本机裸跑输出

本机裸跑输出

redis测试,2个work

redis测试


All versions of zhttp with dependencies

PHP Build Version
Package Version
Requires keaixiaou/zphp Version v2.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package xcorp1986/zhttp contains the following files

Loading the files please wait ....