2014년 6월 27일 금요일

What's Binder?

Everyone including app developers in Android world  may have heard about Binder, but I was wondering what exactly binder is and how that works. the following is what I've found so far.

Brief History of Binder?
Binder was originally made by George Hoffman as OpenBinder project for BeOS (I do not know why that lived for short time, will appreciate if anyone go find out and share some ideas/opinions)
Anyway OpenBinder project was carried out by Dinnie Hackborn after Be Inc. was acquired by Palm... and Dinnie moved to Google >>>> developed Binder in Android what we're using now.

Why use Binder? We can still use Inter Process Communication like sockets and pipes. Answer for this question would be performance. In Android all system functions are provided as server processes that means an optimized and fast communication method is required. Binder use a kernel memory, that's shared between all processes to minimize memory copy overhead, and provides Remote Procedure Call as well.

Benefits of adopting Binder mechanism seems very similar to those of Microkernel OS.
- It's easy to add a new service or remove an existing function
- It's not necessary to test the entire services, only limited components => easy to test
- Communication between processes is handled through Binder, so it guarantees transparency between components.


The following diagram depicts how Binder works in Android system, as previously mentioned two processes communicates through Binder





댓글 없음:

댓글 쓰기