added native code for buffer and event bus