דף זה מספק עצות לפתרון בעיות לתחילת העבודה עם ניטור ביצועים או שימוש בתכונות וכלים של ניטור ביצועים.
בדיקה ראשונה לפתרון בעיות
שתי הבדיקות הבאות הן שיטות עבודה מומלצות כלליות המומלצות לכל אחד לפני המשך פתרון בעיות.
1. בדוק הודעות יומן עבור אירועי ביצועים
בדוק את הודעות היומן שלך כדי לוודא ש-SDK ניטור הביצועים לוכד אירועי ביצועים.
פתח את כלי המפתחים של הדפדפן שלך (לדוגמה, כרטיסיית רשת עבור Chrome Dev Tools או ב- Network Monitor for Firefox ).
רענן את אפליקציית האינטרנט שלך בדפדפן.
בדוק את הודעות היומן שלך עבור הודעות שגיאה.
לאחר מספר שניות, חפש קריאת רשת אל
firebaselogging.googleapis.com
בכלי המפתחים של הדפדפן שלך. הנוכחות של אותה שיחת רשת מראה שהדפדפן שולח נתוני ביצועים ל-Firebase.
אם האפליקציה שלך לא רושמת אירועי ביצועים, עיין בטיפים לפתרון בעיות .
2. בדוק את לוח המחוונים של מצב Firebase
בדוק את לוח המחוונים של מצב Firebase למקרה שיש הפסקה ידועה עבור Firebase או עבור ניטור ביצועים.
תחילת העבודה עם ניטור ביצועים
אם אתה מתחיל עם ניטור ביצועים ( iOS+ | Android | אינטרנט ), הטיפים הבאים לפתרון בעיות יכולים לעזור בבעיות הכוללות Firebase זיהוי SDK או הצגת נתוני הביצועים הראשונים שלך במסוף Firebase.
Firebase יכול לזהות אם הוספת בהצלחה את ה-SDK לניטור ביצועים לאפליקציה שלך כאשר הוא מקבל מידע על אירועים (כמו אינטראקציות באפליקציה) מהאפליקציה שלך. בדרך כלל תוך 10 דקות מהפעלת האפליקציה שלך, לוח המחוונים הביצועים של מסוף Firebase מציג הודעת "SDK מזוהה". לאחר מכן, תוך 30 דקות, לוח המחוונים מציג את הנתונים המעובדים הראשוניים.
אם עברו יותר מ-10 דקות מאז שהוספת את הגרסה העדכנית ביותר של SDK לאפליקציה שלך, ועדיין אינך רואה שום שינוי, בדוק את הודעות היומן שלך כדי לוודא שניטור ביצועים רושם אירועים. נסה את שלבי פתרון הבעיות המתאימים כמתואר להלן כדי לפתור הודעת זיהוי SDK מושהית.
אם אתה עדיין מתפתח באופן מקומי, נסה ליצור אירועים נוספים לאיסוף נתונים:
הצג והצג את אפליקציית האינטרנט שלך בסביבה מקומית.
צור אירועים על ידי טעינת דפי משנה עבור האתר שלך, אינטראקציה עם האפליקציה שלך ו/או הפעלת בקשות רשת. הקפד להשאיר את לשונית הדפדפן פתוחה לפחות 10 שניות לאחר טעינת הדף.
ודא שאובייקט התצורה של Firebase נוסף כהלכה לאפליקציה שלך ושלא שינית את האובייקט. באופן ספציפי, בדוק את הדברים הבאים:
- מזהה Firebase Web App (
appId
) באובייקט התצורה מתאים לאפליקציה שלך. מצא את מזהה האפליקציה שלך ב-Firebase בכרטיס האפליקציות שלך הפרויקט שלך.
אם נראה שמשהו לא בסדר עם אובייקט התצורה באפליקציה שלך, נסה את הפעולות הבאות:
מחק את אובייקט התצורה שיש לך כרגע באפליקציה שלך.
בצע את ההוראות הבאות כדי להשיג אובייקט תצורה חדש ולהוסיף אותו לאפליקציית האינטרנט שלך.
- מזהה Firebase Web App (
אם ה-SDK רושם אירועים ונראה שהכל מוגדר כהלכה, אבל אתה עדיין לא רואה את הודעת זיהוי ה-SDK או נתונים מעובדים (לאחר שעתיים), פנה לתמיכה של Firebase .
ודא ש-SDK ניטור הביצועים מאוחל כהלכה באפליקציה שלך.
ודא ש-SDK ניטור הביצועים אינו מושבת באמצעות הדגל הבא:
-
performance.instrumentationEnabled
-
ודא שאחסון המטמון של הדפדפן שלך מושבת , אחרת ייתכן שהדפדפן לא יקלוט הגדרות מכשור חדשות.
סגור ולאחר מכן פתח מחדש את כרטיסיית דף האינטרנט. בדוק שוב אם יש רישום.
אם זה עתה הוספת את ה-SDK לניטור ביצועים לאפליקציה שלך, ייתכן שיהיה עליך להפעיל מחדש את האפליקציה במלואה כדי שה-SDK יתחיל לעבוד.
אם אינך מוצא שום דבר מושבת באפליקציה שלך, פנה לתמיכה של Firebase .
ניטור ביצועים מעבד נתוני אירועי ביצועים לפני הצגתם בלוח המחוונים של ביצועים .
אם חלפו יותר מ-24 שעות מאז הופעת הודעת "SDK זוהה" ועדיין אינך רואה נתונים, בדוק את לוח המחוונים של Firebase Status למקרה שיש הפסקה ידועה. אם אין הפסקה, פנה לתמיכה של Firebase .
פתרון תקלות כללי
אם הוספת בהצלחה את ה-SDK ואתה משתמש בניטור ביצועים באפליקציה שלך, הטיפים הבאים לפתרון בעיות יכולים לעזור בבעיות כלליות הכוללות תכונות וכלים של ניטור ביצועים.
אם אינך רואה הודעות יומן עבור אירועי ביצועים , נסה את שלבי פתרון הבעיות הבאים:
ודא ש-SDK ניטור הביצועים מאוחל כהלכה באפליקציה שלך.
ודא ש-SDK ניטור הביצועים אינו מושבת באמצעות הדגל הבא:
-
performance.instrumentationEnabled
-
ודא שאחסון המטמון של הדפדפן שלך מושבת , אחרת ייתכן שהדפדפן לא יקלוט הגדרות מכשור חדשות.
סגור ולאחר מכן פתח מחדש את כרטיסיית דף האינטרנט. בדוק שוב אם יש רישום.
אם זה עתה הוספת את ה-SDK לניטור ביצועים לאפליקציה שלך, ייתכן שיהיה עליך להפעיל מחדש את האפליקציה במלואה כדי שה-SDK יתחיל לעבוד.
אם אינך מוצא שום דבר מושבת באפליקציה שלך, פנה לתמיכה של Firebase .
אם אינך רואה נתונים עבור מדד השהיית הקלט הראשון , נסה את שלבי פתרון הבעיות הבאים:
שים לב שניטור ביצועים מתעד רק את מדד עיכוב הקלט הראשון כאשר משתמש לוחץ על דף האינטרנט ב-5 השניות הראשונות לאחר טעינת הדף.
ודא שהגדרת את האפליקציה שלך למדידת מדד זה. מדד השהיית הקלט הראשון דורש הגדרה ידנית . באופן ספציפי, עליך להוסיף את ספריית polyfill עבור מדד זה. להוראות התקנה, עיין בתיעוד של הספרייה.
שים לב שהוספת ספריית polyfill זו אינה נדרשת לניטור ביצועים כדי לדווח על מדדי אפליקציות אינטרנט אחרים.
האם אתה רואה נתוני ביצועים עבור עקבות שנאספו אוטומטית אך לא עבור עקבות קוד מותאם אישית ? נסה את השלבים הבאים לפתרון בעיות:
בדוק את ההגדרה של עקבות קוד מותאם אישית באמצעות ה- Trace API , במיוחד את הדברים הבאים:
- שמות עבור עקבות קוד מותאם אישית ומדדים מותאמים אישית חייבים לעמוד בדרישות הבאות: ללא רווח לבן מוביל או נגרר, ללא תו תחתון מוביל (
_
), והאורך המרבי הוא 32 תווים. - יש להתחיל ולהפסיק את כל העקבות. כל מעקב שלא הופעל, לא הופסק או הופסק לפני שהתחיל לא יירשם.
שים לב שאם אתה משתמש בשיטת
record()
אין צורך להפעיל או להפסיק את המעקב במפורש.- שמות עבור עקבות קוד מותאם אישית ומדדים מותאמים אישית חייבים לעמוד בדרישות הבאות: ללא רווח לבן מוביל או נגרר, ללא תו תחתון מוביל (
ודא שאיסוף נתוני ניטור ביצועים אינו מושבת באמצעות הדגל הבא:
performance.dataCollectionEnabled
דגל זה שולט באיסוף הנתונים עבור מעקבי קוד מותאם אישית בלבד (לא כל הנתונים).
בדוק את הודעות היומן שלך כדי לוודא שניטור ביצועים רושם מעקבי קוד מותאם אישית צפויים.
אם ניטור הביצועים רושם אירועים, אך לא מוצגים נתונים לאחר 24 שעות, פנה לתמיכה של Firebase .
אם חסרים לך נתוני בקשת רשת, שים לב לדברים הבאים:
ניטור ביצועים אוסף באופן אוטומטי מדדים עבור בקשות רשת המדווחות על ידי ממשק ה-API של הדפדפן. דוחות אלה אינם כוללים בקשות רשת שנכשלו.
בהתאם להתנהגות הקוד שלך וספריות הרשת המשמשות את הקוד שלך, ניטור ביצועים עשוי לדווח רק על בקשות רשת שהושלמו. המשמעות היא שחיבורי HTTP/S שנותרו פתוחים עשויים שלא להיות מדווחים.
למידע נוסף על האופן שבו ניטור ביצועים צובר נתוני בקשות רשת תחת דפוסי כתובות אתרים.
אתה יכול גם לנסות דפוסי כתובת אתר מותאמים אישית !
שאלות נפוצות
החלפנו את הבעיות המובילות בהתראות אחרונות כהמשך להצגת ההתראות האחרונה שלנו, אשר מודיעות לך באופן אוטומטי כאשר חציית הספים שהגדרת. הבעיות הוצאו משימוש ומוחלפות בהתראות.
בורר האפליקציות בחלק העליון של כרטיס הביצועים מסנן את ערכי ההתראות תחת התראות אחרונות . רק שלוש ההתראות העדכניות ביותר עבור האפליקציה/ות שנבחרו מוצגות.
למידע נוסף על התראות, ראה הגדרת התראות לבעיות ביצועים .
ניטור ביצועים תומך בהתראות עבור מדדים החורגים מסף מוגדר. כדי למנוע בלבול עם הספים הניתנים להגדרה עבור מדדי ביצועים, הסרנו את היכולת להגדיר ספים לבעיות .
החלפנו את דפי הפרטים והמדדים בממשק משתמש מרכזי (UI) שעוצב מחדש לאחרונה כדי לשפר את אופן פתרון הבעיות. ממשק משתמש חדש זה לפתרון בעיות מציע את אותה פונקציונליות ליבה שהציעו פרטים ומדדים. למידע נוסף על פתרון בעיות, ראה הצגת נתונים נוספים עבור מעקב ספציפי .
ניטור ביצועים אוסף נתוני ביצועים ממכשירי המשתמש של האפליקציה שלך. אם לאפליקציה שלך יש משתמשים רבים או אם האפליקציה מייצרת כמות גדולה של פעילות ביצועים, ניטור ביצועים עשוי להגביל את איסוף הנתונים לקבוצת משנה של מכשירים כדי להפחית את מספר האירועים המעובדים. המגבלות הללו גבוהות מספיק כך שגם עם פחות אירועים, ערכי המדדים עדיין מייצגים את חוויית האפליקציה של המשתמש שלך.
כדי לנהל את נפח הנתונים שאנו אוספים, ניטור ביצועים משתמש באפשרויות הדגימה הבאות:
הגבלת קצב במכשיר : כדי למנוע ממכשיר לשלוח פרצי עקבות פתאומיים, אנו מגבילים את מספר מעקבי הקוד ובקשת הרשת הנשלחים ממכשיר ל-300 אירועים כל 10 דקות. גישה זו מגנה על המכשיר מפני מכשור לולאה שיכול לשלוח כמויות גדולות של נתוני ביצועים, והיא מונעת ממכשיר בודד להטות את מדידות הביצועים.
דגימה דינמית : ניטור ביצועים אוסף כ-100 מיליון אירועים עבור מעקבי קוד ו-100 מיליון עבור מעקבי בקשות רשת לכל אפליקציה בכל משתמשי האפליקציה. קצב דגימה דינמי מובא במכשירים (באמצעות Firebase Remote Config) כדי לקבוע אם מכשיר אקראי צריך ללכוד ולשלוח עקבות. מכשיר שלא נבחר לדגימה אינו שולח אירועים. קצב הדגימה הדינמי הוא ספציפי לאפליקציה ומתכוונן כדי להבטיח שהנפח הכולל של הנתונים שנאספים יישאר מתחת לגבול.
הפעלות משתמש שולחות נתונים נוספים ומפורטים מהמכשיר של משתמש, הדורשות משאבים נוספים כדי ללכוד ולשלוח את הנתונים. כדי למזער את ההשפעה של הפעלות משתמש, ניטור ביצועים עשוי גם להגביל את מספר ההפעלות.
הגבלת קצב בצד השרת : כדי להבטיח שהאפליקציות לא יחרגו ממגבלת הדגימה, ניטור ביצועים עשוי להשתמש בדגימה בצד השרת כדי להפיל כמה אירועים שהתקבלו ממכשירים. למרות שסוג זה של הגבלה אינו משנה את האפקטיביות של המדדים שלנו, היא עלולה לגרום לשינויים קלים בדפוס, כולל הדברים הבאים:
- מספר העקבות יכול להיות שונה ממספר הפעמים שקטע קוד הופעל.
- לעקבות המקושרות באופן הדוק בקוד, ייתכן שלכל אחת יש מספר שונה של דוגמאות.
החלפנו את הכרטיסייה 'בעיות' בהקדמה של התראות, שמודיעה לך אוטומטית כאשר חריגה מהסף שהגדרת. אינך צריך עוד לבדוק ידנית את מסוף Firebase כדי לקבוע את הסטטוס של סף. למידע על התראות, ראה הגדרת התראות לבעיות ביצועים .
עיצבנו מחדש את קטע ניטור הביצועים של מסוף Firebase כך שהכרטיסייה לוח המחוונים תציג את מדדי המפתח שלך ואת כל העקבות שלך בחלל אחד. כחלק מהעיצוב המחודש, הסרנו את הדפים במכשיר והרשת .
בטבלת העקבות בתחתית הכרטיסייה לוח המחוונים יש את כל אותו מידע שהציגו הכרטיסיות במכשיר ורשת , אך עם כמה תכונות נוספות, כולל היכולת למיין את העקבות שלך לפי אחוז השינוי עבור מדד מסוים. כדי להציג את כל המדדים והנתונים עבור מעקב ספציפי, לחץ על שם המעקב בטבלת העקבות.
הצג את העקבות שלך בכרטיסיות המשנה הבאות של טבלת העקבות:
- מעקבי בקשות רשת (הן מהקופסה והן מותאמת אישית) - כרטיסיית המשנה של בקשות רשת
- עקבות קוד מותאם אישית - כרטיסיית המשנה של מעקבים מותאמים אישית
- התחלת אפליקציה, אפליקציה בחזית, עקבות אפליקציה ברקע - כרטיסיית המשנה של מעקבים מותאמים אישית
- עקבות עיבוד מסך — כרטיסיית משנה של עיבוד מסך
- עקבות טעינת עמוד — כרטיסיית המשנה של טעינת עמוד
לפרטים על טבלת העקבות וצפייה במדדים ובנתונים, בקר בדף הסקירה הכללית של המסוף ( iOS+ | Android | אינטרנט ).
מסגרות עיבוד איטי ומסגרות קפואות מחושבות עם קצב רענון משוער של 60 הרץ. אם קצב הרענון של המכשיר נמוך מ-60 הרץ, לכל פריים יהיה זמן רינדור איטי יותר מכיוון שפחות פריימים מעובדים בשנייה. זמני רינדור איטיים יותר עלולים לגרום לדיווח על יותר פריימים איטיים או קפואים מכיוון שיותר פריימים יעובדו לאט יותר או יקפאו. עם זאת, אם קצב רענון המכשיר גבוה מ-60 הרץ, לכל פריים יהיה זמן רינדור מהיר יותר. זה יכול לגרום לדיווח על פחות פריימים איטיים או קפואים. זוהי מגבלה נוכחית ב-SDK לניטור ביצועים.
If Performance Monitoring is the only Firebase product in your app, you can use the standalone Performance Monitoring SDK (and the recommended header script below) if you're interested in:
- using a namespaced library
- reducing your SDK package size
- delaying initialization of the SDK until after your page loads
To include the standalone Performance Monitoring SDK in your app and delay its initialization to after your page loads:
- Add the following script to the header of your index file.
- Make sure to add your app's Firebase project configuration object .
(function(sa,fbc){function load(f,c){var a=document.createElement('script'); a.async=1;a.src=f;var s=document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(a,s);}load(sa); window.addEventListener('load',function(){firebase.initializeApp(fbc).performance()}); })(performance_standalone, firebaseConfig);
where,
- performance_standalone is
'https://www.gstatic.com/firebasejs/9.19.0/firebase-performance-standalone.js'
- firebaseConfig is your app's Firebase config object
The above script asynchronously loads the standalone SDK then initializes Firebase after the window's onload
event fires. This tactic reduces the impact that the SDK could have on page load metrics since the browser has already reported its loading metrics when you initialize the SDK.
Near real-time data processing and display
Firebase Performance Monitoring processes collected performance data as it comes in, which results in near real-time data display in the Firebase console. Processed data displays in the console within a few minutes of its collection, hence the term "near real-time".
To take advantage of near real-time data processing, make sure your app uses a real-time compatible SDK version .
To take advantage of near real-time data processing, you only need to make sure that your app uses a Performance Monitoring SDK version that's compatible with real-time data processing.
These are the real-time compatible SDK versions:
- iOS — v7.3.0 or later
- tvOS — v8.9.0 or later
- Android — v19.0.10 or later (or Firebase Android BoM v26.1.0 or later)
- Web — v7.14.0 or later
Note that we always recommend using the latest version of SDK, but any version listed above will enable Performance Monitoring to process your data in near real time.
These are the SDK versions compatible with real-time data processing:
- iOS — v7.3.0 or later
- tvOS — v8.9.0 or later
- Android — v19.0.10 or later (or Firebase Android BoM v26.1.0 or later)
- Web — v7.14.0 or later
Note that we always recommend using the latest version of SDK, but any version listed above will enable Performance Monitoring to process your data in near real time.
If your app doesn't use a real-time compatible SDK version, you will still see all your app's performance data in the Firebase console. However, the display of performance data will be delayed by roughly 36 hours from the time of its collection.
Yes! Regardless of which SDK version an app instance uses, you'll see performance data from all your users.
However, if you're looking at recent data (less than roughly 36 hours old), then the displayed data is from users of app instances using a real-time compatible SDK version. The non-recent data, though, includes performance data from all versions of your app.
Contacting Firebase Support
If you reach out to Firebase Support , always include your Firebase App ID. Find your Firebase App ID in the Your apps card of your Project settings .
,This page provides troubleshooting tips for getting started with Performance Monitoring or using Performance Monitoring features and tooling.
First checks for troubleshooting
The following two checks are general best practices recommended for anyone before further troubleshooting.
1. Check log messages for performance events
Check your log messages to be sure that the Performance Monitoring SDK is capturing performance events.
Open your browser's developer tools (for example, Network tab for Chrome Dev Tools or in the Network Monitor for Firefox ).
Refresh your web app in the browser.
Check your log messages for any error messages.
After a few seconds, look for a network call to
firebaselogging.googleapis.com
in your browser's developer tools. The presence of that network call shows that the browser is sending performance data to Firebase.
If your app isn't logging performance events, review the troubleshooting tips .
2. Check the Firebase Status Dashboard
Check the Firebase Status Dashboard in case there is a known outage for Firebase or for Performance Monitoring.
Getting started with Performance Monitoring
If you're getting started with Performance Monitoring ( iOS+ | Android | Web ), the following troubleshooting tips can help with issues that involve Firebase detecting the SDK or displaying your first performance data in the Firebase console.
Firebase can detect if you've successfully added the Performance Monitoring SDK to your app when it receives event information (like app interactions) from your app. Usually within 10 minutes of starting your app, the Performance dashboard of the Firebase console displays an "SDK detected" message. Then, within 30 minutes, the dashboard displays the initial processed data.
If it's been more than 10 minutes since you added the latest version of SDK to your app, and you're still not seeing any change, check your log messages to make sure that Performance Monitoring is logging events. Try the appropriate troubleshooting steps as described below to troubleshoot a delayed SDK detection message.
If you're still developing locally, try generating more events for data collection:
Serve and view your web app in a local environment.
Generate events by loading subpages for your site, interacting with your app, and/or triggering network requests. Make sure to keep the browser tab open for at least 10 seconds after the page loads.
Make sure that your Firebase configuration object is correctly added to your app and that you haven't modified the object. Specifically, check the following:
- The Firebase Web App ID (
appId
) in the config object is correct for your app. Find your Firebase App ID in the Your apps card of your Project settings .
If anything seems wrong with the config object in your app, try the following:
Delete the config object that you currently have in your app.
Follow these instructions to obtain a new config object and add it to your web app.
- The Firebase Web App ID (
If the SDK is logging events and everything seems to be set up correctly, but you're still not seeing the SDK detection message or processed data (after 2 hours), contact Firebase Support .
Make sure that the Performance Monitoring SDK is correctly initialized in your app.
Make sure that the Performance Monitoring SDK is not disabled through the following flag:
-
performance.instrumentationEnabled
-
Make sure that your browser caching is disabled, otherwise the browser might not pick up any new instrumentation settings.
Close, then reopen the webpage tab. Check for logging again.
If you just added the Performance Monitoring SDK in your app, you might need to fully restart your app for the SDK to start working.
If you can't find anything that's disabled in your app, contact Firebase Support .
Performance Monitoring processes performance event data before displaying it in the Performance dashboard .
If it's been more than 24 hours since the "SDK detected" message appeared , and you're still not seeing data, then check the Firebase Status Dashboard in case there is a known outage. If there is no outage, contact Firebase Support .
General troubleshooting
If you've successfully added the SDK and are using Performance Monitoring in your app, the following troubleshooting tips can help with general issues that involve Performance Monitoring features and tooling.
If you're not seeing log messages for performance events , try the following troubleshooting steps:
Make sure that the Performance Monitoring SDK is correctly initialized in your app.
Make sure that the Performance Monitoring SDK is not disabled through the following flag:
-
performance.instrumentationEnabled
-
Make sure that your browser caching is disabled, otherwise the browser might not pick up any new instrumentation settings.
Close, then reopen the webpage tab. Check for logging again.
If you just added the Performance Monitoring SDK in your app, you might need to fully restart your app for the SDK to start working.
If you can't find anything that's disabled in your app, contact Firebase Support .
If you're not seeing data for the first input delay metric , try the following troubleshooting steps:
Be aware that Performance Monitoring only records the first input delay metric when a user clicks on the web page within the first 5 seconds after page load.
Make sure that you've set up your app to measure this metric. The first input delay metric requires manual setup . Specifically, you need to add the polyfill library for this metric. For installation instructions, refer to the library's documentation .
Note that adding this polyfill library is not required for Performance Monitoring to report other web app metrics.
Are you seeing performance data for automatically collected traces but not for custom code traces ? Try the following troubleshooting steps:
Check the setup of custom code traces instrumented via the Trace API , especially the following:
- Names for custom code traces and custom metrics must meet the following requirements: no leading or trailing whitespace, no leading underscore (
_
) character, and max length is 32 characters. - All traces must be started and stopped. Any trace that is not started, not stopped, or stopped before started will not be logged.
Note that if you're using the
record()
method, then you don't need to explicitly start or stop your trace.- Names for custom code traces and custom metrics must meet the following requirements: no leading or trailing whitespace, no leading underscore (
Make sure that Performance Monitoring data collection is not disabled through the following flag:
performance.dataCollectionEnabled
This flag controls the collection of data for custom code traces only (not all data).
Check your log messages to make sure that Performance Monitoring is logging expected custom code traces.
If Performance Monitoring is logging events, but no data displays after 24 hours, contact Firebase Support .
If you're missing network request data, be aware of the following:
Performance Monitoring automatically collects metrics for network requests reported by the browser API. These reports do not include failed network requests.
Depending on the behavior of your code and networking libraries used by your code, Performance Monitoring might only report on network requests that are completed. This means that HTTP/S connections that are left open might not be reported.
Learn more about how Performance Monitoring aggregates network request data under URL patterns.
You can also try out custom URL patterns !
FAQ
We replaced Top Issues with Recent Alerts as a follow-up to our recent introduction of alerts, which automatically notify you when the thresholds you set are crossed. Issues are now deprecated and replaced by alerts.
The apps selector at the top of the Performance card filters the alert entries under Recent Alerts . Only the three most recent alerts for the app(s) selected are displayed.
To learn more about alerts, see Set up alerts for performance issues .
Performance Monitoring supports alerts for metrics that exceed defined thresholds. To avoid confusion with these configurable thresholds for performance metrics, we removed the ability to configure thresholds for issues .
We replaced the Details and Metrics pages with a newly redesigned, centralized user interface (UI) to improve how you troubleshoot issues. This new troubleshooting UI offers the same core functionality that Details and Metrics offered. To learn more about troubleshooting, see View more data for a specific trace .
Performance Monitoring collects performance data from your app's user devices. If your application has many users or if the app generates a large amount of performance activity, Performance Monitoring might limit data collection to a subset of devices to reduce the number of processed events. These limits are high enough so that, even with fewer events, the metric values are still representative of your user's app experience.
To manage the volume of data that we collect, Performance Monitoring uses the following sampling options:
On-device rate limiting : To prevent a device from sending sudden bursts of traces, we limit the number of code and network request traces sent from a device to 300 events every 10 mins. This approach protects the device from looped instrumentations that can send large amounts of performance data, and it prevents a single device from skewing the performance measurements.
Dynamic sampling : Performance Monitoring collects approximately 100M events for code traces and 100M for network request traces per app across all app users. A dynamic sampling rate is fetched on devices (using Firebase Remote Config) to determine whether a random device should capture and send traces. A device that is not selected for sampling does not send any events. The dynamic sampling rate is app-specific and adjusts to ensure that the overall volume of collected data remains below the limit.
User sessions send additional, detailed data from a user's device, requiring more resources to capture and send the data. To minimize the impact of user sessions, Performance Monitoring might also restrict the number of sessions.
Server-side rate limiting : To ensure that apps don't exceed the sampling limit, Performance Monitoring might use server-side sampling to drop some events received from devices. Although this type of limiting doesn't change the effectiveness of our metrics, it may cause minor pattern shifts, including the following:
- The number of traces can differ from the number of times that a piece of code was executed.
- Traces that are closely coupled in code may each have a different number of samples.
We replaced the Issues tab with the introduction of Alerts, which automatically notifies you when the thresholds you set are exceeded. You no longer need to manually check the Firebase console to determine the status of a threshold. To learn about Alerts, see Set up alerts for performance issues .
We've redesigned the Performance Monitoring section of the Firebase console so that the Dashboard tab displays your key metrics and all your traces in one space. As part of the redesign, we removed the On device and Network pages.
The traces table at the bottom of the Dashboard tab has all the same information that the On device and Network tabs displayed, but with some added features, including the ability to sort your traces by the percentage change for a specific metric. To view all the metrics and data for a specific trace, click the trace name in the traces table.
View your traces in the following subtabs of the traces table:
- Network request traces (both out-of-the-box and custom) — Network requests subtab
- Custom code traces — Custom traces subtab
- App start, app-in-foreground, app-in-background traces — Custom traces subtab
- Screen rendering traces — Screen rendering subtab
- Page load traces — Page load subtab
For details about the traces table and viewing metrics and data, visit the console overview page ( iOS+ | Android | Web ).
Slow rendering frames and frozen frames are calculated with an assumed device refresh rate of 60Hz. If a device refresh rate is lower than 60Hz, each frame will have a slower rendering time because fewer frames are rendered per second. Slower rendering times can cause more slow or frozen frames to be reported because more frames will be rendered slower or will freeze. However, if a device refresh rate is higher than 60Hz, each frame will have a faster rendering time. This can cause fewer slow or frozen frames to be reported. This is a current limitation in the Performance Monitoring SDK.
If Performance Monitoring is the only Firebase product in your app, you can use the standalone Performance Monitoring SDK (and the recommended header script below) if you're interested in:
- using a namespaced library
- reducing your SDK package size
- delaying initialization of the SDK until after your page loads
To include the standalone Performance Monitoring SDK in your app and delay its initialization to after your page loads:
- Add the following script to the header of your index file.
- Make sure to add your app's Firebase project configuration object .
(function(sa,fbc){function load(f,c){var a=document.createElement('script'); a.async=1;a.src=f;var s=document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(a,s);}load(sa); window.addEventListener('load',function(){firebase.initializeApp(fbc).performance()}); })(performance_standalone, firebaseConfig);
where,
- performance_standalone is
'https://www.gstatic.com/firebasejs/9.19.0/firebase-performance-standalone.js'
- firebaseConfig is your app's Firebase config object
The above script asynchronously loads the standalone SDK then initializes Firebase after the window's onload
event fires. This tactic reduces the impact that the SDK could have on page load metrics since the browser has already reported its loading metrics when you initialize the SDK.
Near real-time data processing and display
Firebase Performance Monitoring processes collected performance data as it comes in, which results in near real-time data display in the Firebase console. Processed data displays in the console within a few minutes of its collection, hence the term "near real-time".
To take advantage of near real-time data processing, make sure your app uses a real-time compatible SDK version .
To take advantage of near real-time data processing, you only need to make sure that your app uses a Performance Monitoring SDK version that's compatible with real-time data processing.
These are the real-time compatible SDK versions:
- iOS — v7.3.0 or later
- tvOS — v8.9.0 or later
- Android — v19.0.10 or later (or Firebase Android BoM v26.1.0 or later)
- Web — v7.14.0 or later
Note that we always recommend using the latest version of SDK, but any version listed above will enable Performance Monitoring to process your data in near real time.
These are the SDK versions compatible with real-time data processing:
- iOS — v7.3.0 or later
- tvOS — v8.9.0 or later
- Android — v19.0.10 or later (or Firebase Android BoM v26.1.0 or later)
- Web — v7.14.0 or later
Note that we always recommend using the latest version of SDK, but any version listed above will enable Performance Monitoring to process your data in near real time.
If your app doesn't use a real-time compatible SDK version, you will still see all your app's performance data in the Firebase console. However, the display of performance data will be delayed by roughly 36 hours from the time of its collection.
Yes! Regardless of which SDK version an app instance uses, you'll see performance data from all your users.
However, if you're looking at recent data (less than roughly 36 hours old), then the displayed data is from users of app instances using a real-time compatible SDK version. The non-recent data, though, includes performance data from all versions of your app.
Contacting Firebase Support
If you reach out to Firebase Support , always include your Firebase App ID. Find your Firebase App ID in the Your apps card of your Project settings .