Download the PHP package cube-group/myaf-log without Composer

On this page you can find all versions of the php package cube-group/myaf-log. 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 myaf-log

LOG

Latest Stable Version Total Downloads License

namespace

1.业务日志

容器内日志路径:

宿主机内日志路径:

日志字段说明:

  • $time: 日期(例如: 2018-05-10 20:00)
  • $ip: 用户请求的ip地址
  • $level: 日志级别(INFO ERROR DEBUG WARN)
  • $ruid: 请求链唯一id(request unique id,例如: md5)
  • $domain: 域(例如: l.eoffcn.com)
  • $pid: 进程id或线程id或协程id
  • $route: web路由(例如: /user/login 或 user/login)
  • $uid: 用户类信息(例如: 相关用户id或用户名或手机号等)
  • $code: 业务错误码(例如: 0或10000等)
  • $msg: 业务错误信息(例如: ERR_USER_LOGIN)
  • $ext: 扩展字段

业务标准日志Demo:

业务标准日志打印级别:

  • DEBUG 用过调试,级别最低,可以随意的使用于任何觉得有利于在调试时更详细的了解系统运行状态的东东;
  • INFO 用于打印程序应该出现的正常状态信息, 便于追踪定位;
  • WARN 表明系统出现轻微的不合理但不影响运行和使用;
  • ERROR 表明出现了系统错误和异常,无法正常完成目标操作。
  • FATAL 相当严重,可以肯定这种错误已经无法修复,并且如果系统继续运行下去的话后果严重

日志工具包: SDK地址 https://github.com/cube-group/myaf-log

composer安装:

composer.json:

Log使用:

2.统计日志

容器内日志路径:

宿主机内日志路径:

日志字段说明:

  • $time: 日期(例如: 2018-05-10 20:00)
  • $app: 应用名称
  • $version: 应用版本号,如:0.1.2
  • $client: 终端代码 (0:backend, 1:pc,2:web,10:android,11:ios,20:微信公众号,21:微信服务号,22:微信小程序)
  • $os: 操作系统或设备(win-10.0.0、android-7.0.0、ios-11.0.3、mac-10.13.5、linux、darwin)
  • $ip: 用户ip(符合ip标准)
  • $uid: 用户类信息(例如: 相关用户id或用户名或手机号等)
  • $action: 行为类代码,如:user-login
  • $ext: 扩展字段(必须为query string格式,例如:a=1&b=2&...)

业务标准日志Demo:

日志工具包: SDK地址 https://github.com/cube-group/myaf-log

composer安装:

composer.json:

Log使用:


All versions of myaf-log with dependencies

PHP Build Version
Package Version
Requires php Version >=5.3
monolog/monolog Version 1.24.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 cube-group/myaf-log contains the following files

Loading the files please wait ....