Closed Bug 1156361 Opened 10 years ago Closed 9 years ago

Telemetry redesign: Consolidate date & string utility functions in TelemetryUtils.jsm

Categories

(Toolkit :: Telemetry, defect, P1)

defect
Points:
1

Tracking

()

RESOLVED FIXED
mozilla49
Tracking Status
firefox40 --- affected
firefox49 --- fixed

People

(Reporter: gfritzsche, Assigned: Dexter)

References

Details

(Whiteboard: [unifiedTelemetry] [measurement:client])

Attachments

(1 file)

Bug 1140037 started consolidating some things in TelemetryUtils.jsm.
Depends on: 1140037
Whiteboard: [b5] [unifiedTelemetry]
Whiteboard: [b5] [unifiedTelemetry] → [unifiedTelemetry]
Points: --- → 1
Priority: -- → P3
Whiteboard: [unifiedTelemetry] → [unifiedTelemetry] [measurement:client]
Priority: P3 → P1
Priority: P1 → P2
It looks like there's not much left to be done: - function toLocalTimeISOString(date): only used in TelemetrySession.jsm [1] - function getLocale(): can be removed, it's not used by TelemetrySession anymore [2] - function getMsSinceProcessStart(): used by TelemetrySession and potentially by TelemetryLog.jsm [3] - function tomorrow(date): can be removed from TelemetrySend, no longer used [4] - function limitStringToLength(aString, aMaxLength): used by TelemetryEnvironment [5] [1] - https://dxr.mozilla.org/mozilla-central/rev/6adc822f5e27a55551faeb6c47a9bd8b0859a23b/toolkit/components/telemetry/TelemetrySession.jsm#1014-1015 [2] - https://dxr.mozilla.org/mozilla-central/rev/6adc822f5e27a55551faeb6c47a9bd8b0859a23b/toolkit/components/telemetry/TelemetrySession.jsm#108 [3] - https://dxr.mozilla.org/mozilla-central/rev/6adc822f5e27a55551faeb6c47a9bd8b0859a23b/toolkit/components/telemetry/TelemetryLog.jsm#18 [4] - https://dxr.mozilla.org/mozilla-central/rev/6adc822f5e27a55551faeb6c47a9bd8b0859a23b/toolkit/components/telemetry/TelemetrySend.jsm#129 [5] - https://dxr.mozilla.org/mozilla-central/search?q=limitStringToLength&redirect=false&case=true
Assignee: nobody → alessio.placitelli
Priority: P2 → P1
Georg, what do you think about moving these to TelemetryUtils: - toLocalTimeISOString - getMsSinceProcessStart - limitStringToLength And removing the others? Anything else you can think of?
Flags: needinfo?(gfritzsche)
(In reply to Alessio Placitelli [:Dexter] from comment #3) > Georg, what do you think about moving these to TelemetryUtils: > > - toLocalTimeISOString > - getMsSinceProcessStart > - limitStringToLength > > And removing the others? Anything else you can think of? Definitely toLocalTimeISOString(), the other two are trivial local helpers so i'd only share them if we use them in multiple locations. There are no other i can think of right now without searching.
Flags: needinfo?(gfritzsche)
Attached patch bug1156361.patchSplinter Review
Attachment #8749704 - Flags: review?(gfritzsche)
Attachment #8749704 - Flags: review?(gfritzsche) → review+
Keywords: checkin-needed
Status: NEW → ASSIGNED
https://hg.mozilla.org/integration/fx-team/rev/64ad199ede21c4ab89e4b65b5b62351a3bbe5a45 Bug 1156361 - Telemetry redesign: Consolidate date & string utility functions in TelemetryUtils.jsm. r=gfritzsche
Keywords: checkin-needed
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla49
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: