Tutorials
Tutorials
Section titled βTutorialsβπ― Goal: Build real features while learning platform concepts through hands-on practice
This section contains step-by-step tutorials that guide you through building real features with the Banyan platform. Each tutorial builds working code and explains key concepts as you progress.
Learning Path by Experience Level
Section titled βLearning Path by Experience LevelβYour Tutorial Journeyββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
π’ BEGINNER (0-1 week experience) β±οΈ Total: 6 hoursββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ ββ Week 1: Core Patterns ββ ββ Todo Service (90min) β Basic CRUD operations ββ ββ User Management (2hrs) β Authentication patterns ββ ββ Blog Platform (3hrs) β Complete application ββ ββ β Commands, queries, and events ββ β Handler auto-discovery ββ β Basic testing patterns ββ β API Gateway integration ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β βΌπ‘ INTERMEDIATE (1-4 weeks experience) β±οΈ Total: 9 hoursββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ ββ Weeks 2-4: Advanced Patterns ββ ββ Event-Sourced Orders (4hrs) β Event sourcing deep dive ββ ββ Multi-Service Workflow (3hrs) β Service integration ββ ββ Real-Time Notifications (2hrs)β WebSocket subscriptions ββ ββ β Event store and aggregates ββ β Read model projections ββ β Service-to-service communication ββ β Two-layer authorization ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β βΌπ΄ ADVANCED (1+ months experience) β±οΈ Total: 14 hoursββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ ββ Month 2+: Enterprise Patterns ββ ββ Saga Orchestration (6hrs) β Distributed transactions ββ ββ Custom Read Models (4hrs) β Performance optimization ββ ββ Platform Extensions (4hrs) β Custom infrastructure ββ ββ β Saga pattern implementation ββ β Custom projections and indexes ββ β Performance tuning ββ β Platform extension points ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββQuick Tutorial Selector
Section titled βQuick Tutorial SelectorβI want to learnβ¦
Section titled βI want to learnβ¦βBasic CRUD operations β Todo Service (90 min, π’ Beginner)
- Create, read, update, delete operations
- Command and query handlers
- Basic validation
User authentication β User Management (2 hrs, π’ Beginner)
- User registration and login
- Password hashing
- JWT token generation
Complete application β Blog Platform (3 hrs, π’ Beginner)
- Posts, comments, and categories
- Multi-entity relationships
- Full CRUD workflows
Event sourcing β Event-Sourced Orders (4 hrs, π‘ Intermediate)
- Event store implementation
- Aggregate root pattern
- Event replay and projections
Service integration β Multi-Service Workflow (3 hrs, π‘ Intermediate)
- Service-to-service calls
- Generated service clients
- Error handling across services
Real-time features β Real-Time Notifications (2 hrs, π‘ Intermediate)
- WebSocket subscriptions
- Event broadcasting
- Real-time UI updates
Distributed transactions β Saga Orchestration (6 hrs, π΄ Advanced)
- Saga pattern implementation
- Compensation logic
- Long-running workflows
Performance optimization β Custom Read Models (4 hrs, π΄ Advanced)
- Custom projection strategies
- Database indexing
- Caching patterns
Platform customization β Platform Extensions (4 hrs, π΄ Advanced)
- Custom decorators
- Middleware integration
- Infrastructure extension points
Tutorial Catalog
Section titled βTutorial Catalogβπ’ Beginner Tutorials
Section titled βπ’ Beginner Tutorialsβ| Tutorial | Time | Focus | Prerequisites |
|---|---|---|---|
| Todo Service | 90 min | CRUD operations, basic handlers | Getting Started completed |
| User Management | 2 hrs | Authentication, password handling | Todo Service |
| Blog Platform | 3 hrs | Multi-entity app, relationships | User Management |
Total beginner path: 6 hours
π‘ Intermediate Tutorials
Section titled βπ‘ Intermediate Tutorialsβ| Tutorial | Time | Focus | Prerequisites |
|---|---|---|---|
| Event-Sourced Orders | 4 hrs | Event sourcing, aggregates | All beginner tutorials |
| Multi-Service Workflow | 3 hrs | Service integration | Event-Sourced Orders |
| Real-Time Notifications | 2 hrs | WebSocket, subscriptions | Multi-Service Workflow |
Total intermediate path: 9 hours
π΄ Advanced Tutorials
Section titled βπ΄ Advanced Tutorialsβ| Tutorial | Time | Focus | Prerequisites |
|---|---|---|---|
| Saga Orchestration | 6 hrs | Distributed transactions | All intermediate tutorials |
| Custom Read Models | 4 hrs | Performance, projections | Saga Orchestration |
| Platform Extensions | 4 hrs | Custom infrastructure | Custom Read Models |
Total advanced path: 14 hours
How to Use These Tutorials
Section titled βHow to Use These Tutorialsβ1. Choose Your Starting Point
Section titled β1. Choose Your Starting PointβNever used Banyan? β Start with π’ Beginner tutorials
Completed Getting Started? β Try Todo Service first
Understand CQRS basics? β Jump to π‘ Intermediate tutorials
Production experience? β Explore π΄ Advanced tutorials
2. Follow Best Practices
Section titled β2. Follow Best Practicesβπ‘ Best Practice: Type code yourself instead of copying/pasting for better retention
Recommended approach:
- Read the entire tutorial introduction first
- Follow steps in order without skipping
- Test after each major section
- Complete the checkpoint exercises
- Review the βWhat You Builtβ summary
3. Learn Actively
Section titled β3. Learn Activelyβ- Experiment: Try variations to see what happens
- Break things: Understanding errors deepens learning
- Complete exercises: Practice reinforces concepts
- Check solutions: Compare your work with provided examples
4. Track Your Progress
Section titled β4. Track Your ProgressβBeginner milestones:
- β Create command handlers
- β Create query handlers
- β Handle domain events
- β Test via message bus
Intermediate milestones:
- β Implement event sourcing
- β Build read model projections
- β Integrate multiple services
- β Add authorization policies
Advanced milestones:
- β Orchestrate sagas
- β Optimize read performance
- β Extend platform capabilities
- β Handle production scenarios
Tutorial Format
Section titled βTutorial FormatβEvery tutorial follows the same structure for consistency:
1. Introduction ββ What you'll build ββ What you'll learn ββ Time estimate
2. Prerequisites ββ Required knowledge ββ Required tutorials ββ Required setup
3. Learning Objectives ββ Skills you'll gain ββ Concepts you'll understand
4. Step-by-Step Instructions ββ Numbered steps ββ Code examples ββ Explanations ββ Checkpoints
5. What You Built ββ Summary of accomplishments ββ Diagram of architecture
6. Exercises ββ Practice challenges ββ Extension ideas
7. Next Steps ββ Related tutorials ββ Recommended readingGetting Help
Section titled βGetting HelpβIf you get stuck during a tutorial:
1. Check Checkpoints
Section titled β1. Check CheckpointsβEvery tutorial includes verification steps to ensure youβre on track. If a checkpoint fails, review the previous section.
2. Review Related Docs
Section titled β2. Review Related Docsβ- Concepts: Understand the βwhyβ β Concepts
- Guides: Quick how-to reference β Guides
- Reference: API specifications β Reference
3. Use Diagnostic Tools
Section titled β3. Use Diagnostic Toolsβ# View service logsdocker compose logs -f service-name
# Check distributed tracesopen http://localhost:16686
# Inspect message busopen http://localhost:156724. Visit Troubleshooting
Section titled β4. Visit Troubleshootingβ- By Symptom - βHandler not calledβ
- By Component - βMessage bus issuesβ
- Common Errors - Error codes
5. Study Working Examples
Section titled β5. Study Working ExamplesβEvery tutorial concept has a complete working example β Examples
Recommended Learning Paths
Section titled βRecommended Learning PathsβFor Backend Developers
Section titled βFor Backend DevelopersβTime: 10 hours over 2 weeks
Week 1: Foundationsββ Todo Service (90min)ββ User Management (2hrs)ββ Blog Platform (3hrs)
Week 2: Advanced Patternsββ Event-Sourced Orders (4hrs)ββ Multi-Service Workflow (3hrs)For Full-Stack Developers
Section titled βFor Full-Stack DevelopersβTime: 13 hours over 3 weeks
Week 1: Backend Basicsββ Todo Service (90min)ββ User Management (2hrs)ββ Blog Platform (3hrs)
Week 2: Real-Time Featuresββ Event-Sourced Orders (4hrs)ββ Real-Time Notifications (2hrs)
Week 3: Integrationββ Multi-Service Workflow (3hrs)For Platform Engineers
Section titled βFor Platform EngineersβTime: 20 hours over 4 weeks
Weeks 1-2: All Beginner + Intermediate (15hrs)
Weeks 3-4: Advancedββ Saga Orchestration (6hrs)ββ Custom Read Models (4hrs)ββ Platform Extensions (4hrs)Before You Start
Section titled βBefore You Startββ Prerequisites: Completed Getting Started (35 minutes)
π§ Setup: Platform running via
docker compose up
β±οΈ Time: Block uninterrupted time for each tutorial
π‘ Tip: Keep the Quick Reference open while coding
Ready to build? β Start with Todo Service (90 minutes, π’ Beginner)