Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rest Server: Enjoying the Rust Language #21

Open
axyiee opened this issue Mar 28, 2022 · 0 comments
Open

Rest Server: Enjoying the Rust Language #21

axyiee opened this issue Mar 28, 2022 · 0 comments
Assignees
Labels
🤷 good first issue Good for newcomers 🏷️ in progress Issue or pull request that is already being worked on ❗ priority: high 😴 rest Issue or pull request related to the REST modules

Comments

@axyiee
Copy link
Member

axyiee commented Mar 28, 2022

Rest Server: Enjoying the Rust Language

Table of contents:

  1. 📰 Summary
  2. 🤔 Motivations and the proposed solution
  3. ⚠️ Limitations
  4. 🤷 Final considerations

Summary

We should move our rest server from Kotlin to Rust.

Motivations and the proposed solution

Rust is a richer language in ecosystem, performance, features and community. It is a really fun language to code in. Since we need to spend less time searching why simple things don't work or aren't documented (Ktor 👀), we can just use the nifty libraries for Rust in which will provide us a decent performance, clean code and consistent code style. I'm currently planning to use the following stack (RARSTCHL) for the rest server development:

  • actix-web would be the main technology used for our backend services
  • rbatis would be used for database connections in our rest server
  • serde for (de)serializing json
  • tokio for asynchronous code handling
  • chrono for date and time support
  • lapin for rabbitmq messaging support
  • redis-rs for redis caching support
  • jwt for json web token support

Limitations

The only limitation that comes to my mind is that we need to create an entity data class in Kotlin with the same contents as Rust for the rest web client, this means that we would have duplicated code.

Final considerations

Suggestions are appreciated for new sections in this issue, or if you have a better idea about how to structure or improve our rest server, feel free to comment down below. Thank you for the attention.

@axyiee axyiee added 🤷 good first issue Good for newcomers 😴 rest Issue or pull request related to the REST modules ❗ priority: high labels Mar 28, 2022
@axyiee axyiee added the 🏷️ in progress Issue or pull request that is already being worked on label Apr 19, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🤷 good first issue Good for newcomers 🏷️ in progress Issue or pull request that is already being worked on ❗ priority: high 😴 rest Issue or pull request related to the REST modules
Projects
None yet
Development

No branches or pull requests

2 participants