Closed Bug 794948 Opened 12 years ago Closed 11 years ago

Port Telemetry writes to OS.File

Categories

(Toolkit :: Telemetry, enhancement)

enhancement
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 839794

People

(Reporter: Yoric, Assigned: Yoric)

References

Details

      No description provided.
Currently, Telemetry writes are fully on-main-thread synchronous. The rationale is that we want them to block shutdown until the write is complete.

Putting the writes off the main thread should be easy. Not 100% sure this will still block shutdown, though.
Unfortunately, the current tests for Telemetry are all xpcshell-based. As xpcshell does not have workers, it does not support OS.File, so I will need to port the tests to mochitest-something.
(In reply to David Rajchenbach Teller [:Yoric] from comment #2)
> Unfortunately, the current tests for Telemetry are all xpcshell-based. As
> xpcshell does not have workers, it does not support OS.File, so I will need
> to port the tests to mochitest-something.

Oh, ugh.  Can we figure out something better here?  The xpcshell tests are so much more convenient to run than the mochitest ones.
(In reply to Nathan Froyd (:froydnj) from comment #3)
> (In reply to David Rajchenbach Teller [:Yoric] from comment #2)
> > Unfortunately, the current tests for Telemetry are all xpcshell-based. As
> > xpcshell does not have workers, it does not support OS.File, so I will need
> > to port the tests to mochitest-something.
> 
> Oh, ugh.  Can we figure out something better here?  The xpcshell tests are
> so much more convenient to run than the mochitest ones.

I second adding workers to xpcshell over moving tests to mochitests
(In reply to Taras Glek (:taras) from comment #4)
> > Oh, ugh.  Can we figure out something better here?  The xpcshell tests are
> > so much more convenient to run than the mochitest ones.
> 
> I second adding workers to xpcshell over moving tests to mochitests

From my conversations with the js team, that sounds rather unlikely.

Unrelated update: OS.File (and more generally workers) ceases functioning after event "web-workers-shutdown". Consequently, anything beyond that point cannot be written to dish using OS.File
(In reply to David Rajchenbach Teller [:Yoric] from comment #5)
> (In reply to Taras Glek (:taras) from comment #4)
> > > Oh, ugh.  Can we figure out something better here?  The xpcshell tests are
> > > so much more convenient to run than the mochitest ones.
> > 
> > I second adding workers to xpcshell over moving tests to mochitests
> 
> From my conversations with the js team, that sounds rather unlikely.
> 
> Unrelated update: OS.File (and more generally workers) ceases functioning
> after event "web-workers-shutdown". Consequently, anything beyond that point
> cannot be written to dish using OS.File

Seems straight-forward to me. Either finish all of the io by then or have the backend switch to doing io on main thread once that condition is hit, effectively making async calls sync.
This might be a little more complicated, as I believe we can have some IO sent to the worker before web-workers-shutdown, and lost because of web-workers-shutdown.

I will work on this once I have finally outsmarted the blocker bug.
Ah, right.
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.