---
title: 架构说明
description: 文本抽取：知识库/02-商城交易私域场景/ECshopex开源资料/架构说明
updated: 2026-11-04
tags: [原始文档, 抽取, 知识库]
source: 知识库/02-商城交易私域场景/ECshopex开源资料/架构说明
source_type: txt
source_hash: 1a6550d7e4e9
extracted_at: 2026-11-04
quality: ok
---

---
source: 知识库/02-商城交易私域场景/ECshopex开源资料/架构说明.docx
type: docx
size_kb: 17
category: 02-商城交易私域场景
quality: ok
---

## 架构说明

### 软件架构

后端开发语言：PHP 7.2

后端技术框架：采用 Lumen 开源框架开发，引入dingo作为接口管理，采用更符合大型项目的 Doctrine ORM 替换系统自带 ORM

前端开发语言：HTML5/CSS3/ES6/小程序开发框架

前端开发框架：VueJS,Taro,Wepy

数据库：支持 MySQL等数据库

队列：支持 Redis/RabbitMQ/数据库 等方案，默认采用 Redis

缓存：支持 Redis/filesystem/memcached，默认采用 Redis

CDN/OSS：支持阿里云/七牛云

搜索：ES

日志搜集：ELK/Sentry

Software Architecture

Back-end Development Language: PHP 7.2

Back-end Framework: use Lumen Open Source Framework to develop, introduce dingo as interface management, and replace the System ORM by adopting Doctrine ORM, which is more conform in large-scale projects.

Front-end Development Language: HTML5/CSS3/ES6/Mini Program Framework

Front-end Framework: VueJS, Taro, Wepy

Database: Support MySQL databases

Queue: Support Redis/RabbitMQ/database and other schemes, Redis is used by default

Cache: Support Redis/filesystem/memcached, Redis is used by default

CDN/OSS: Support Alibaba Cloud/Qiniu Cloud

Search: ES

Log Collection: ELK/Sentry

### 数据处理能力

支持 MySQL 读写分离模式，支持阿里云PolarDB。

在 5 机集群下综合场景支持 2000 每秒并发，且根据实际业务需求扩容。

无优化情况下数据库4核8G配置，单独订单压测每秒27单，可根据实际业务调整web机、缓存、数据库配置来优化。

采用多级缓存机制，可以有效保证API响应时间在 2S 以内。

系统具备按照终端，店铺，门店等权限控制。

Data Processing Capability

Support MySQL read-write separation mode, support Alibaba Cloud PolarDB.

In a 5-machine cluster, a comprehensive scenario supports 2000 concurrency per second, and the capacity is expanded according to actual business requirements.

Without optimization, the database is configured with 4 cores and 8G, and individual orders are pressure tested at 27 orders per second, which can be optimized by adjusting the web machine, cache, and database configuration according to the actual business.

The use of a multi-level caching mechanism can effectively ensure that the API response time is within 2 seconds.

The system has authority control according to terminals, shops, stores, etc.

稳定性

系统支持集群模式部署，可按照 web/schedule/worker 等不同角色部署，可有效保证系统高可用

支持阿里云 K8S 部署，可以通过HPA实现 POD 自动扩容，可有效保证在突发流量下，系统的高可用

采用事件机制，可以异步处理耗时业务逻辑，保证实时业务稳定性

采用多级缓存机制，nginx+memcache/php+redis 方式。在redis数据库宕机时，可由 nginx 缓存来替代，保证系统高可用。

Stability

The system supports cluster mode deployment, which can be deployed according to different roles such as web/schedule/worker.

Supports Alibaba Cloud K8S deployment, and can realize automatic expansion of POD through HPA (horizontal pod autoscaling).

Using event mechanism, time-consuming business logic can be processed asynchronously to ensure real-time business stability.

Using a multi-level caching mechanism, nginx+memcache/php+redis mode. When the redis database is down, it can be replaced by nginx cache to ensure high system availability.

### 持续集成

系统采用 PHP 开发，支持二次开发

在 ONex中，除了授权部分，其他部分均为源代码

具备完善的开发环境（docker-compose）和测试环境构建脚本，可以快速搭建环境

采用基于 GitLab-CI/K8S/Helm/Helmfile 的持续集成方案

Continuous Integration

The system adopts PHP development and supports secondary development.

In ONex, except for the authorization part, the other parts are all source code.

With a complete development environment (docker-compose) and test environment build scripts, engineer can quickly build the environment.

Adopt a continuous integration solution based on GitLab-CI/K8S/Helm/Helmfile