Samsung / Castanets

Edge distributed web engine. Part of web engine processes are offloaded to a powerful devices and only graphical results are processed in local devices. This way, we overcome both CPU limitations and memory limitations of the low-end local devices
BSD 3-Clause "New" or "Revised" License
45 stars 43 forks source link

Use SharedMemory for Data Pipe without data transfer #170

Open is46-kim opened 4 years ago

is46-kim commented 4 years ago

Goal : Load resources directly on renderer side device without network transfer.

Network service sends Mojo DataPipe to transfer the loaded resources to renderer. The DataPipe has a ring buffer consist of shared memory. The DataPipe is delivered by URLLoaderClient::OnStartLoadingResponseBody(mojo::ScopedDataPipeConsumerHandle body) mojo interface.

For browser side navigation scenario, Although the Renderer and Utility have Unix domain socket connections on the same device by (#112), the shared memory handle of DataPipe can not be passed from Utility to Renderer because the Message Pipe of |URLLoaderClient| mojo interface created by Browser and connected on TCP socket channel.

The Shared Memory Handle of DataPipe should be shared between utility and renderer on the same device even through bypassing TCP socket.

is46-kim commented 4 years ago

[WIP] Use SharedMemory named GUID for Renderer Side Resource Load.

Loads resources properly in Renderer with WIP patch.

is46-kim commented 4 years ago

I requested PR https://github.com/Samsung/Castanets/pull/179 This patch sends NamedSharedMemory to share DataPipeConsumerHandle for URLLoaderClient mojo interface connected with TCP.