IdleService tries to set a pref from a content process when running tests on B2G emulator

RESOLVED FIXED in 1.3 C1/1.4 S1(20dec)



4 years ago
4 years ago


(Reporter: reuben, Assigned: reuben)


(Blocks: 1 bug)

1.3 C1/1.4 S1(20dec)
Gonk (Firefox OS)
Dependency tree / graph

Firefox Tracking Flags

(Not tracked)


(Whiteboard: [systemsfe])


(1 attachment, 1 obsolete attachment)



4 years ago

FWIW, dom/permission/tests/test_idle.html runs earlier in the same chunk.
Blocks: 933355
I think this is the cause for the random orange on M4.
We should try to disable this test:
Flags: needinfo?(jgriffin)
Flags: needinfo?(ahalberstadt)
I've just disabled this on cedar.
I haven't seen this error since jgriffin disabled it. Was this debug only though? As I don't think it got disabled for opt yet.
Flags: needinfo?(ahalberstadt)
It looks like disabling that test did clear up M4, aside from the shutdown crash which bug 934009 addresses.
Flags: needinfo?(jgriffin)
Assignee: nobody → reuben.bmo
Whiteboard: [systemsfe]
Target Milestone: --- → 1.3 Sprint 6 - 12/6
I think this service, as it is, should only run in the master process. Child processes should simply forward their requests to the master.
At the very least, the daily stuff should just be disabled in child processes.

Comment 7

4 years ago
Created attachment 8346571 [details] [diff] [review]
Remote IdleService, disable idle-daily in content processes

Something like this?

Keeping track of an id->pointer map in parent and child is a PITA, does anyonek now if there's an easier way to do that? Is sending |static_cast<intptr_t>(ptr)| too hacky?
Attachment #8346571 - Flags: feedback?(roc)
Comment on attachment 8346571 [details] [diff] [review]
Remote IdleService, disable idle-daily in content processes

Review of attachment 8346571 [details] [diff] [review]:

This is good but I think we can simplify it a bit. Instead of allocating IDs in ContentChild and keeping an ID-to-observer map there, we can just have ContentChild::AddIdleObserver/RemoveIdleObserver cast the observer pointer to a uint64_t and forward directly to the parent. When notified by the parent, we just cast the uint64_t back to a pointer and notify on it. We have to trust the parent process anyway. ContentChild still needs to AddRef and Release the observer to maintain current lifetime semantics.
Attachment #8346571 - Flags: feedback?(roc) → feedback+

Comment 9

4 years ago
Created attachment 8347034 [details] [diff] [review]
Remote IdleService, disable idle-daily in content processes, v2

Nice, that makes things significantly simpler! I assumed sending pointers across processes would be frowned upon, but this makes a lot of sense :)
Attachment #8346571 - Attachment is obsolete: true
Attachment #8347034 - Flags: review?(roc)
Target Milestone: 1.3 Sprint 6 - 12/6 → 1.3 C1/1.4 S1(20dec)
Attachment #8347034 - Flags: review?(roc) → review+

Comment 10

4 years ago
Last Resolved: 4 years ago
Resolution: --- → FIXED
Depends on: 968558
You need to log in before you can comment on or make changes to this bug.