Lyra
Learn
AI Learning Platform
π Midnight
π Comfort
π₯ Ember
π Paper
β Contrast
Exams
Sign in to track progress
β Back to the lesson
Module 3 Β· Quiz
State, Caching, and Config
1. What is the best way to handle user sessions when adding a second server behind a load balancer?
Use in-memory session storage
Implement a distributed session store
Store sessions in local file storage
Minimize the use of sessions
2. What is a key downside of using IMemoryCache for caching frequently accessed reference data?
Low latency reads
Data is shared across servers
Requires serialization
Potential data inconsistency between servers
3. Which of the following is NOT a recommended practice for storing secrets in configuration?
User secrets for local development
Connection strings in appsettings.json
Azure Key Vault for production
Environment variables for deployment
4. Why is cache invalidation on write preferred over waiting for expiry in cache management?
It reduces network overhead
It ensures data consistency
It allows for instant cache hits
It minimizes memory consumption
Submit answers
Continue: The Slow Page Walkthrough β
Review this lesson
Retake quiz