Description
In this course, you will learn :
- How to create, test, and document the service in both pure and impure forms.
- Introduced to the distinctions between pure and impure implementation, their respective benefits and drawbacks.
- How pure implementation can be more robust in terms of performance, understandability, testability, and type safety.
- Using the functional programming paradigm, create, test, and document the back-end HTTP services.
- Discover the benefits and drawbacks of Pure and Impure functional programming techniques.
- You will have a solid understanding of functional programming in Scala.
Syllabus :
1. Impure Implementation
- Getting Started
- Models
- Setting Up the Database
- Slick Tables
- Functions for Data Access
- Akka-HTTP Routes
- Some More Routes
- Interact with the Service
2. Pure Implementation
- Getting Started
- Pure Configuration Handling
- Models
- Database
- Doobie
- Functions for Data Access
- Http4s Routes
- Streaming
- JSON Trouble
- Starting the Application
3. Testing Impure Services
- About Tests
- Generators
- Unit Tests
- Refactor the Code
- Setting Up Integration Tests
- Testing the Repository
- Testing the Routes: Setup
- Testing the Routes: Use Case - Loading
- Testing the Routes: Use Case - Saving
- Testing the Routes: Use Case - Updating
- Carrying Out Tests
4. Testing Pure Services
- Setting Up Unit Tests
- Unit Tests for Product Routes
- Integration Tests Setup
- Integration Tests
- Carrying Out Tests
5. Benchmarks
- Adding Benchmarks
6. Documentation
- Documenting Our API
- A Pure Implementation Using Tapir
- Product Routes - Load and Update Product
- Products Routes - Create and Load all Products
- Documentation via OpenAPI
- Refining the Generated Documentation