Giter Club home page Giter Club logo

strawframework's People

Contributors

iyane avatar zlizhe avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

strawframework's Issues

[Feature]Log 基础设施

添加一个日志基类

  • 在任何位置使用 日志类 写入日志信息, 需要自动添加当前环境 (REQUEST参数, CONTROLLER, ACTION, 或当前请求/来源方法, 请求时间, 大小, HTTP_METHOD)
    Log 基类创建于 /Strawframework/Base/Log.php
  • 允许配置日志写入方式 (文本, 邮件, 数据库 Mongodb / ES)
  • 允许配置默认的日志写入方式 (如默认文本)
  • 允许手动指定日志写入方式 (在配置了默认日志写入方式后可以更换其他方式写入)

可选

  • 延迟写入日志 (收集到一定量或时间到后批量写入)

[Feature]Cache 子类 Redis

  • 创建 Cache 子类 Redis,
    使用 Redis 作为缓存介质,完成 Cache 接口方法
implements /Strawframework/Protocol/Cache

Cache 子类创建于 /Strawframework/Cache/

Cache基类中没有的方法, 需要 Redis 实现

  • Redis Pub/Sub
  • Redis 队列

[Feature]Model 子类 Mysql

  • 创建 Model 子类 Mysql
implements /Strawframework/Protocol/Db

通过 Model 基类调用 Mysql 方法, 子类创建于 /Strawframework/Db/Mysql.php

[Feature]Cache 基类变更

  • 变更原 Cache 基类与接口
    位置 /Strawframework/Base/Cache.php ,需要让 Cache 基类兼容多种 Cache 方法 (File, Redis)等,添加 Cache 接口于 /Strawframework/Protocol/Cache.php,添加 Cache 连接,写入,查询等所需方法
    • 以 File, Redis 为目标设计 Cache 接口与 Cache 基类
    • 兼容其他 Cache 方法
  • 通过静态方法在任意位置调用 Cache 基类以完成 Cache 接口方法
  • 允许配置多个 Cache 方法, 类型可以重复 (如添加2个不同服务器的 Redis)
    • 允许配置默认的 Cache 方法, 如 Redis,配置后默认使用调用该方法
    • 允许手动指定 Cache 方式 (在配置了默认 Cache 方式后可以更换其他 Cache),如配置了 默认 Cache 方法为 Redis, 依然可以通过指定 File 来使用 File缓存/读取
    • 允许配置默认的缓存时间
    • 允许手动指定缓存时间
    • 允许删除缓存/清空缓存/重新生成缓存
  • 接口中与基类需要预留一个可以直接操作子类的方法(即通过黑名单方式禁止一些危险操作,其他未定义的操作依然可以通过此预留方法进行操作)

[Feature]Cache 子类 File

  • 创建 Cache 子类 File,
    使用 php 文件作为缓存介质,完成 Cache 接口方法
implements /Strawframework/Protocol/Cache.php

Cache 子类创建于 /Strawframework/Cache/

  • 缓存框架内部复杂操作 (生成表缓存等)

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.