enflow/component-laravel 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

enflow/component-laravel

Composer 安装命令:

composer require enflow/component-laravel

包简介

Laravel package for Enflow's clients

README 文档

README

The component-laravel package provides a sane-default configuration for Enflow based applications. The LaravelServiceProvider registers some classes, middleware, and enables Skyline cluster support.

Installation

You can install the package via composer:

composer require enflow/component-laravel

Configuration

This package registers automatically trough Laravel's autoloading.

Exception handling

To include this ExceptionHandler to enable prettier error handling, extend the \Enflow\Component\Laravel\AbstractExceptionHandler from app/Exceptions/Handler.php file like this:

<?php

namespace App\Exceptions;

use Enflow\Component\Laravel\AbstractExceptionHandler;

class Handler extends AbstractExceptionHandler
{
    protected $dontReport = [];

    protected $dontFlash = [
        'password',
        'password_confirmation',
    ];
}

Commands

db:sync

db:sync enabled you to mysqldump a production database to your local machine and import it automatically.

Performance

To improve import time of db:sync script (tested with a 2GB database) takes ~60 min, just to import.

  1. Ensure you are running MySQL 8.0 or higher on your Linux machine directly (legacy systems that connect from WSL to Windows based MySQL are much slower).
  2. Change configuration settings to improve buffer sizes to allow faster importing.

sudo nano /etc/mysql/mysql.conf.d/mysqld.cnf

Add the following after the [mysqld] block:

innodb_buffer_pool_size=4G
innodb_log_buffer_size=256M
innodb_log_file_size=1G
innodb_write_io_threads=16
innodb_flush_log_at_trx_commit=0
max_allowed_packet=1024M
read_buffer_size=2M

Restart MySQL to let these variables take effect: sudo service mysql restart

Ensure the variables are applied by checking it directly via mysql: SHOW VARIABLES LIKE "innodb_buffer_pool_size";

Contributing

Please see CONTRIBUTING for details.

Security

If you discover any security related issues, please email michel@enflow.nl instead of using the issue tracker.

Credits

About Enflow

Enflow is a digital creative agency based in Alphen aan den Rijn, Netherlands. We specialize in developing web applications, mobile applications and websites. You can find more info on our website.

enflow/component-laravel 适用场景与选型建议

enflow/component-laravel 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 47.79k 次下载、GitHub Stars 达 0, 在 PHP 生态内属于活跃度较高的组件。

我们在过去多个企业项目中使用过 enflow/component-laravel 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。

围绕 enflow/component-laravel 我们能提供哪些服务?
定制开发 / 二次开发

基于 enflow/component-laravel 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。

BUG 修复 & 性能优化

线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。

项目外包 & 长期维护

承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。

yvsm@zunyunkeji.com QQ:316430983 微信:yvsm316 西安尊云信息科技 · 专注 PHP / Go / 分布式系统研发

统计信息

  • 总下载量: 47.79k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 11
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 3
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 未知