0
0
Firebasecloud~20 mins

Performance monitoring in Firebase - Practice Problems & Coding Challenges

Choose your learning style9 modes available
Challenge - 5 Problems
🎖️
Firebase Performance Pro
Get all challenges correct to earn this badge!
Test your skills under time pressure!
💻 Command Output
intermediate
2:00remaining
Firebase Performance Trace Start and Stop Output
What will be the output in the Firebase console after running this code snippet to start and stop a custom performance trace?
Firebase
const trace = performance.trace('custom_trace');
trace.start();
// some operations
trace.stop();
ANo trace appears because start() and stop() methods are asynchronous and need await.
BAn error is thrown because 'performance.trace' is not a valid method.
CThe trace appears but with zero duration because stop() was called immediately after start().
DA new custom trace named 'custom_trace' appears in the Firebase Performance dashboard with duration matching the operation time.
Attempts:
2 left
💡 Hint
Remember that Firebase Performance traces record duration between start and stop calls.
🧠 Conceptual
intermediate
1:30remaining
Understanding Firebase Performance Monitoring Data Collection
Which statement correctly describes how Firebase Performance Monitoring collects data from your app?
AIt only collects data when the app is running in debug mode.
BIt requires manual instrumentation for all traces and network requests to appear in the dashboard.
CIt automatically collects traces and network requests without any code changes after SDK initialization.
DIt collects data only if the user explicitly grants permission each time the app starts.
Attempts:
2 left
💡 Hint
Think about what Firebase SDK does after you add it to your app.
Troubleshoot
advanced
2:00remaining
Diagnosing Missing Firebase Performance Data
You notice no performance traces appear in the Firebase console after deploying your app with the Performance Monitoring SDK. What is the most likely cause?
AThe app is running on a device with network connectivity disabled, preventing data upload.
BThe Firebase project is missing the Performance Monitoring API key.
CThe SDK requires manual calls to upload data which were not added.
DPerformance Monitoring only works on Android devices, not iOS.
Attempts:
2 left
💡 Hint
Consider what conditions are needed for data to appear in the console.
🔀 Workflow
advanced
2:30remaining
Configuring Custom Attributes in Firebase Performance Traces
Which sequence correctly describes how to add a custom attribute to a Firebase Performance trace in your app code?
A1,2,3,4
B1,3,2,4
C3,1,2,4
D2,1,3,4
Attempts:
2 left
💡 Hint
Attributes must be set after creating the trace but before stopping it.
Best Practice
expert
3:00remaining
Optimizing Firebase Performance Monitoring for Production
Which practice is best to minimize performance monitoring overhead in a production Firebase app?
AUse the default SDK settings without any configuration changes.
BDisable automatic network request collection and manually instrument only critical requests.
CDisable all custom traces to reduce SDK initialization time.
DEnable verbose logging in production to capture detailed performance data.
Attempts:
2 left
💡 Hint
Think about balancing data collection detail with app performance.