Monday, 19 January 2015

What is Provider Life Cycle in Android ?

* Content Provider are another story.Clients, both internal and external, interact with a content provider synchronously.

* For external clients, content providers use a thread pool to satisfy this requirement.

* Like broadcast receivers, content providers do not have a particular life cycle.

* They get started when needed and stay around as long as the process stays around.

* Even though they are synchronous for external clients, they will run not on the main thread but on a thread pool of the process that they reside in, similar to a web client and a web server.

* The client  thread will wait until the call comes back.

* When there are on clients around, the process gets reclaimed as per the reclamation rules of a process, depending on what other components are defined and active in that process.

No comments:

Post a Comment