[FR] Support sending Firebase Performance traces to multiple destinations (e.g. log, Firebase, Hotdog, Sentry, etc.)
Nobody has claimed this yet.
Assessment
- Difficulty
- 5/5
- Estimated time
- Over a week
- Newbie friendliness
- 30/100
- Issue type
- Feature
- Clarity
- Mostly clear
- Activity status
- Stale
- Domain
- mobile-dev, observability-sre
Research direction
The issue mentions the Now in Android performance tracking utilities but names no files or tests. Start by locating those utilities and reviewing how Firebase Performance traces are currently reported; done means a clearly configurable design can forward traces to multiple destinations, with coverage for the supported reporting behavior.
Written by the indexing model from the issue text.
Description
Is there an existing issue for this?
- I have searched the existing issues
Describe the problem
Description
It would be extremely helpful if the Now in Android sample app (and its performance tracking utilities) could support sending performance trace data not only to Firebase Performance Monitoring but also to other destinations such as:
- Logcat (for quick local debugging)
- Firebase Performance Dashboard (default destination)
- Hotdog
- Sentry
- (Any other custom tools)
Motivation
Developers often need performance data in multiple contexts simultaneously. For instance:
- Logcat: Useful for immediate debugging during development, CI builds, or local testing.
- Firebase: Great for aggregate analytics and real user monitoring.
- Hotdog / Sentry / etc.: Useful for centralized error/performance dashboards, custom dashboards, or alternative monitoring solutions.
Serving multiple destinations would make debugging and monitoring smoother and more flexible.
Proposed approach
- Create an abstraction layer over performance trace reporting, e.g., a
PerformanceReporterinterface. - Implement multiple reporters (e.g.,
LogcatReporter,FirebaseReporter,HotdogReporter,SentryReporter). - Make these reporters configurable (via dependency injection or a simple registry), so users can opt in to any combination they need.
Example usage
val performanceReporters = listOf(LogcatReporter(), FirebaseReporter(), SentryReporter())
PerformanceReporting.initialize(performanceReporters)
trace("user_login") {
// Business logic here
}
### Describe the solution
interface PerformanceReporter {
fun onTraceStart(name: String)
fun onTraceEnd(name: String, durationMs: Long)
}
Each destination will implement this interface, for example:
kotlin
Copy code
class FirebaseReporter : PerformanceReporter { /* ... */ }
class LogcatReporter : PerformanceReporter { /* ... */ }
class SentryReporter : PerformanceReporter { /* ... */ }
class HotdogReporter : PerformanceReporter { /* ... */ }
2. Create a CompositePerformanceReporter
This class will manage a list of reporters and forward trace events to all of them:
kotlin
Copy code
class CompositePerformanceReporter(
private val reporters: List<PerformanceReporter>
) : PerformanceReporter {
override fun onTraceStart(name: String) {
reporters.forEach { it.onTraceStart(name) }
}
override fun onTraceEnd(name: String, durationMs: Long) {
reporters.forEach { it.onTraceEnd(name, durationMs) }
}
}
### Additional context
_No response_
### Code of Conduct
- [x] I agree to follow this project's Code of Conduct
- Dominant language
- Kotlin
- Stars
- 22.1k
- Forks
- 4.7k
- PR merge metrics
- No merged PRs in 30d
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from android/nowinandroid
-
[Bug]: Search empty-state copy reads "explorer" instead of "explore"Possibly taken @Amir-yazdanmanesh claimed this 168 days ago. Openbug
Difficulty 1/5 Under an hour Newbie friendliness 84/100
android/nowinandroid#2127 ·
-
[Documentation]: Grammar error in SyncInitializer commentPossibly taken @sahilpatel2521 claimed this 185 days ago. Opendocumentation
Difficulty 1/5 Under an hour Newbie friendliness 92/100
android/nowinandroid#2121 ·
-
[FR]: Move TopicScreen user-facing strings to resourcesPossibly taken @ois0886 claimed this 189 days ago. Open
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
android/nowinandroid#2115 ·
-
[Bug]: Interests top-level nav label sources string from feature/search instead of feature/interestsPossibly taken @Noahs212 claimed this 193 days ago. Open
Difficulty 1/5 Under an hour Newbie friendliness 90/100
android/nowinandroid#2112 ·
-
[FR]: Add network connectivity check before launching Chrome Custom TabPossibly taken A pull request linked to this issue is open or already merged. Openenhancement
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
android/nowinandroid#2110 ·
All issues in android/nowinandroid
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
bug needs-triage
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
emm3000/myGame#2175 · 1 comment ·
Maintainers usually reply within 1 day
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
MetrolistGroup/Metrolist#5426 · 1 comment · 1 reaction ·
Maintainers usually reply within 1 day
-
🐛 Type:Bug 📥 State:Awaiting Assignment 🚨 Priority: P0 - Critical
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
backend
Difficulty 2/5 1-3 hours Newbie friendliness 64/100
digitalfabrik/entitlementcard#3330 ·
Maintainers usually reply within 2 days