Embrace the Rust era and use Lotus to develop Rust Web painlessly

Embrace the era of Rust, use Lotus to develop Rust Web painlessly

Now, the Rust language is gaining popularity. Not only the Linux kernel, but Windows has also begun to use Rust development functions. It's time to start Rust. Based on my experience developing the Rust general-purpose code generator Lotus. No matter how familiar you are, the development speed of the Rust language is roughly half or one-third that of the Java language. slower than Java. Moreover, there are relatively few documents and examples for the Rust language. Therefore, there is still a threshold for new Rust language.

Do you want to develop Rust web applications painlessly and at a speed similar to java? Now, you can use the Rust general-purpose code generator lotus for this purpose. Lotus is a general-purpose code generator driven by SGS2 templates, and its usage method is similar to that of Java general-purpose code generator Guang and Go language general-purpose code generator Fairchild. Using it, you can rapidly develop Rust web applications with the speed and quality of a Java-like general-purpose code generator.

Rust general code generator lotus early adopter version 5, release the latest introduction video, build the code generator from the source code, and generate and run an example. See the video:

https://www.bilibili.com/video/BV1Cg4y1574C/

Lotus, the Rust general-purpose code generator, has announced early adopter version 5. This version is the first available version with complete functions, supports elastic automatic login module, supports the latest version of Axum 0.6.18, completely improves the database access layer, solves the problem of creating a new database link for each query, so that it can only query more than 10 times After more testing, this version supports MariaDB, MySQL and PostgreSQL databases. All non-Oracle examples attached are supported. This release is at a usable level of functionality and quality. Please deploy it under the webapps directory of Tomcat9. welcome.
This version is a full-featured, advanced version with detailed testing and bugfixes, and its elastic login module has been improved. Registered users automatically get the user role. The database access layer is an important improvement. From then on, the database data can be accessed unlimited times, so that the code generation can be used in practice. In addition, Axum has been improved to Axum 0.6.18 on the early adopter version 5, which is the latest version. Everyone is welcome to use it.

Code generator project address: https://gitee.com/jerryshensjf/Lotus

Download address of binary war package:  https://gitee.com/jerryshensjf/Lotus/attach_files

Rust Generic Code Generator: Lotus

introduce

Rust Generic Code Generator: Lotus

Software Architecture Description

The software is written in Java and deployed in the webapps directory of Tomcat 9. The current version is compiled with openjdk 17.

This software is rewritten from the general code generator of Go language: Fairchild.

The code generation is a rust 1.69 environment. Using Axum 0.6.18, tower web framework, tokio 1.0, sqlx 0.3.5 database access layer and MariaDB, MySQL 8, PostgreSQL database.

Rust general code generator lotus early adopter version 5. This version is the first available version with complete functions, supports automatic login module, supports the latest version of Axum 0.6.18, completely improves the database access layer, solves the problem of creating a new database link for each query, so that it can only query more than 10 times Major bug, after more testing, this version supports MariaDB, MySQL and PostgreSQL databases. All non-Oracle examples attached are supported. This release is at a usable level of functionality and quality. Please deploy it in the webapps directory of Tomcat9. welcome.

Early adopter version 4. Through programming and testing, the Vue frontend generated by lotus has finally been completely fixed. Now, the front end and back end can work smoothly without any hindrance. In addition to the functions of the elastic login module and the Oracle database, Lotus Early adopter version 4 has complete functions. Everyone can try it out.

Lotus early adopter version 3 upgrades Axum to 0.6.6, and eliminates 2/3 compilation warnings. Subsequent versions may downgrade Axum back to 0.4. Fans of Axum 0.6 please use this version. You can use the attached non-Oracle sample test system to get a working code generation.

This version supports Go language compatibility, that is, Go language general code generator Fairchild's templates directly generate Rust code generators. It also supports Java compatibility, that is, it supports the Java general code generator light, the Wings of Peace code generator, and the Excel template of the boundless code generator to directly generate Rust code generators.

Early adopter version 4 supports Excel and PDF data export. Standalone frontend for Vue, ElementUI. Supports MySQL, MariaDB and PostgreSQL databases. Support picture function. All non-Oracle examples attached are supported. Welcome to try it out.

Baidu topic

# Generic Code Generator #

Introduction video

For the introduction video of the early adopter version 5, please see:

https://www.bilibili.com/video/BV1Cg4y1574C/

Rust general code generator lotus early adopter version 4 released an introduction video, starting from the source code to build the Rust general code generator lotus. And generate the front and back end of a routine and demonstrate the operation. See the video:

https://www.bilibili.com/video/BV11N411c7H6/

Early adopter version 3

https://www.bilibili.com/video/BV1co4y1a7Ca/

Early adopter version 2

https://www.bilibili.com/video/BV1aj411N7YB/

Smoke Beta 4

https://www.bilibili.com/video/BV1jy4y1R79h/

Early adopter version five download

https://gitee.com/jerryshensjf/Lotus/attach_files

Project picture

Enter a picture description

Enter a picture description

software screenshot

Enter a picture description

Enter a picture description

code generator screenshot

single table operation

Enter a picture description

many to many

Enter a picture description

complex layout, tree table

Enter a picture description

graphic report

Enter a picture description

picture function

Enter a picture description

Excel data export

Enter a picture description

PDF data export

Enter a picture description

Vue independent front end, login interface

Enter a picture description

Vue independent front end, inner page

Enter a picture description

Reference routine

You can refer to the routine GirlOnlyTower, see:

https://gitee.com/jerryshensjf/GirlOnlyTower

Source Compilation User Guide

The general code generator already supports compiling the source code by itself, and I have uploaded the jar package of the front-end code generator that was missing. Support everyone to compile the source code by themselves.

Note that right now my development platform is openjdk 17 on Fedora 37. So it is best to use openjdk17 to compile the source code. The compiled war package runs on Apache Tomcat 9.0.

A user who already has jdk8 reports that the code generator war package downloaded by default does not work on his platform. Please report if you encounter similar issues. My email is: [email protected]

Attached openjdk 17 download address:

https://jdk.java.net/java-se-ri/17

Notes for source code readers

The source code of the first complete version of the boundless code generator, if you are interested, you can copy it:

https://gitee.com/jerryshensjf/InfinityGPGenerator_0_6_5

Related technical videos:

https://www.bilibili.com/video/BV1fX4y1u7Bn/

https://www.bilibili.com/video/BV1rv41187qY/

https://www.bilibili.com/video/BV1xv41187cA/

https://www.bilibili.com/video/BV1t64y1v7WA/

Guess you like

Origin www.oschina.net/news/241519