0
0
Supabasecloud~20 mins

Supabase architecture (Postgres, Auth, Storage, Realtime, Edge Functions) - Practice Problems & Coding Challenges

Choose your learning style9 modes available
Challenge - 5 Problems
🎖️
Supabase Architecture Master
Get all challenges correct to earn this badge!
Test your skills under time pressure!
🧠 Conceptual
intermediate
2:00remaining
Understanding Supabase Auth Behavior
Which of the following best describes how Supabase Auth manages user sessions after login?
ASupabase Auth stores the session token only in memory and loses it on page reload.
BSupabase Auth stores a session token in local storage and automatically refreshes it using a refresh token.
CSupabase Auth requires the user to manually re-login every 30 minutes to maintain session.
DSupabase Auth uses cookies that expire immediately after login, requiring constant re-authentication.
Attempts:
2 left
💡 Hint
Think about how persistent login works in web apps.
Architecture
intermediate
2:00remaining
Supabase Storage Usage Scenario
You want to store user-uploaded images in Supabase Storage. Which statement correctly describes how Supabase Storage integrates with other Supabase services?
ASupabase Storage requires manual configuration of access rules outside of Supabase Auth.
BSupabase Storage is a separate service and does not integrate with Supabase Auth for access control.
CSupabase Storage automatically replicates files into the Postgres database for backup.
DSupabase Storage uses Supabase Auth to control access to files, allowing only authenticated users to upload or download files.
Attempts:
2 left
💡 Hint
Consider how access control is unified in Supabase.
service_behavior
advanced
2:00remaining
Realtime Updates with Supabase Realtime
Given a Supabase Realtime subscription to a Postgres table, what happens when a new row is inserted into that table?
AThe client subscribed to the table immediately receives a realtime event with the new row data.
BSupabase Realtime only sends events for updates, not inserts.
CThe new row is only visible after a manual refresh of the client application.
DThe client must poll the database every few seconds to see new rows.
Attempts:
2 left
💡 Hint
Realtime means instant updates pushed to clients.
Configuration
advanced
2:00remaining
Edge Functions Deployment in Supabase
Which of the following is true about deploying Edge Functions in Supabase?
AEdge Functions are serverless functions deployed close to users for low latency and scale automatically.
BEdge Functions run on the client device and require manual scaling.
CEdge Functions must be deployed inside the Postgres database as stored procedures.
DEdge Functions only run during database migrations.
Attempts:
2 left
💡 Hint
Think about what 'edge' means in cloud computing.
security
expert
3:00remaining
Securing Supabase Postgres with Row Level Security (RLS)
You want to ensure users can only see their own data in a Supabase Postgres table. Which RLS policy correctly enforces this?
Supabase
CREATE POLICY "Users can view their own data" ON messages FOR SELECT USING (auth.uid() = user_id);
AThe policy allows users to select rows where the Postgres user ID matches the user_id column.
BThe policy allows all users to select all rows without restriction.
CThe policy allows users to select rows where the Supabase auth.uid() matches the user_id column.
DThe policy denies all SELECT operations on the messages table.
Attempts:
2 left
💡 Hint
auth.uid() returns the current logged-in user's ID.