Skip to content
Kailash edited this page Feb 14, 2022 · 1 revision

RavJS

Javascript client library to retrieve and calculate operations

Setup

Clone

git clone https://github.com/ravenprotocol/ravjs.git

Configure

  • In ravjs/raven.js file update the CID variable to a unique string before opening a new client.

    const cid = "<unique_client_id>"

  • Point RAVSOCK_SERVER_URL to ravsock. It can be your local ravsock running on your local device.

    const RAVSOCK_SERVER_URL = "localhost" // local ravsock server or const RAVSOCK_SERVER_URL = "<ravsock_server_url>" //remote ravsock server

Start

  • Open worker.html in a new browser tab to connect to ravsock

  • Once connected, click on Participate button. This triggers the execution of a local client benchmarking code and returns it's results to the server. The server utilizes this data for optimizing the scheduling algorithm.

The client will now dynamically receive groups of Ops from the server, compute them and return the results back to the server.

Clone this wiki locally