UCToo is a general term for a set of best practices for cloud-native distributed SaaS application development.
overview
UCToo is a cloud-native distributed SaaS application development infrastructure. It meets the Level 5 standard of SaaS maturity model, implements SaaS unified application instance template development specifications, and adopts open-source, general-purpose, and vendor-neutral technology selection. Built-in many developer efficiency tools, it can quickly develop and operate SaaS applications, and is suitable as a starting project for SaaS platforms, industrial Internet and other products. Development results can be shared, interconnected, and commercially distributed in the UCToo Marketplace.
Key features:
The design goal of this project is to provide developers with the ability to generate the management background, API interface and default mobile application of the application module mainly by defining the data structure of the application module, so that the background developers and front-end developers who master the technology stack can use this project to quickly develop multi-terminal compatible digital systems and applications, and can carry out flexible secondary development.
Advanced technology, mainstream applications, open source and openness.
The module is detachable, and the system only retains the core functions, and the rest of the functions are realized by expanding the module.
It supports cloud-native application development, supports multi-merchant and multi-application management SaaS platform features, can be independently installed and deployed in most cloud platform environments, and supports cloud-native deployment.
Support WeChat Mini Program cloud development features.
Since the third-party platform development method is the basis for the dependence of WeChat transaction components and batch cloud development, it is recommended that the third-party platform method be used for the development of WeChat-related applications.
It realizes the modular development of applications on the third-party platform of WeChat, and various value-added applications can be installed and uninstalled independently, supporting the commercial distribution and deployment of modules.
It has integrated the WeChat third-party platform for batch cloud development, and supports decentralized deployment of merchant web management platform and applet application templates.
catchadmin can realize the rapid development of low-code on the merchant web management platform, and the UCToo low-code module can realize the rapid low-code development of mini programs and APP multi-terminal.
Product Architecture
The system integrates many excellent open source projects, adopts common technologies, and continuously integrates industry best practices on a weekly basis. The UCToo development team has expanded the functions related to WeChat app development, connecting all the interfaces of the WeChat Official Accounts Platform and the Open Platform, so that they can be used in any type of WeChat app project.
Third-party platform configuration information is stored in the WechatOpen table. The account information of the Official Account/Mini Program authorized to the third-party platform is stored in the wechatopen_applet table, the parameters of the WechatOpen table are used to initialize the easyWeChat SDK, and the parameters of the wechatopen_applet table are used as the account information of the third-party platform to realize the business on behalf of the Official Account/Mini Program.
– UCToo V2 adopts the catchadmin framework with front-end and back-end separation.
At the same time, combined with the characteristics of Tencent CloudBase’s cloud-native development platform,
It can realize the decentralized deployment of SaaS application instance templates.
This makes the project conform to the main features of a Level 5 SaaS product
controller
Use the Admin Admin – > System Administration – > code generation function to generate Admin Admin data tables, models, and resource controllers
API
uctoo-api-client
u
ctoo-api-client-php is a lightweight, semantic, IDE-friendly HTTP client that supports common HTTP requests, asynchronous requests, and concurrent requests.
When we want to develop a UCToo mall module minishop that integrates WeChat Mini Store, there is a function to synchronize WeChat Mini Store to get category details on the product category management function page, and we can use the following development specifications:
- From the front-end VUE project, initiate a request to the php background sync category interface of the minishop product.
In the PHP background synchronization category method, we do not initialize a WeChat SDK running locally to call the open interface of the transaction component of the standard version of WeChat Store in the traditional way, but initialize a uctoo-api-client-php client and forward the request to the microservice of WechatOpen product to get category details. The sample code is as follows:
/**
* Synchronize WeChat Mini Store category data to the local area
*/
public function sync(Request $request)
{
$result = null;$host = trim(Utils::config(‘wechatopen.host’));
$account = trim(Utils::config(‘wechatopen.account’));
$password = trim(Utils::config(‘wechatopen.password’));
$response = Http::withHost($host) // Specify the third-party platform
->withAccountAuth($account,$password) //Use server-side account authentication
->withVerify(false) // No SSL verification required
->product(‘/api/wechatopen’) // Required parameter if product is specified
->post(‘/product/category/get’, [‘appid’ => AdminApplet::adminApplet($request->user()->id)[‘appid’],’f_cat_id’=>0]); AppID managed by the current administrator
$res = $response->body();
return CatchResponse::success( $res,’sync success’);
}
Secondary developmentGeneral steps for secondary development with UCToo:
1. Create a database data structure based on your needs. The data structure must follow the data specifications agreed upon in the SaaS shared data model.
2. Through the background interface generation function of uctoo-api-server management background, the background CRUD function of the created data model can be generated with one click.
3. Generate APIs through the API management function of the uctoo-api-server management background. Configure API permissions for microapps managed by the platform.
4. Configure the interconnection API through the uctoo-api-client template to customize the application required for development.
5. Publish to the micro-application account managed by the platform through the application publishing function of the uctoo-api-server management background.
6. Through the application packaging function of uctoo-api-server management background, the developed application is packaged into a SaaS application instance template, which can be published to other micro-application accounts with the same functional requirements.Runtime environment dependencies
PHP >= 7.1.0
MySQL >= 5.5.0 (requires innodb support)
PDO PHP Extension
MBstring PHP Extension
CURL PHP Extension
ZIP Extension
ComposerManual
Please refer to the details for details
https://www.kancloud.cn/doc_uctoo/manual