Skip to content

Commit

Permalink
feat: 🎸Integrate Livepeer Subgraph (#251)
Browse files Browse the repository at this point in the history
* feat: 🎸 Integrate Livepeer Subgraph

Leverages The Graph to reduce the time-to-load of the transcoder view and add a “missed calls” column to the transcoder card.

Issues: #199, #192

* Update .env.development with REACT_APP_LIVEPEER_SUBGRAPH

* Prevent lerna from hoisting subgraph typescript dependencies

* Update graph-ts, graph-cli, and graph-node deps

* Refactor to support The Graph dependency updates

* Update graph-cli and graph-ts deps

* Update subgraph README

* Include more comments
  • Loading branch information
adamsoffer authored and Randy1Burrell committed Nov 16, 2018
1 parent 2dddf5c commit d7367ab
Show file tree
Hide file tree
Showing 100 changed files with 10,931 additions and 1,870 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ We happily await your pull requests and/or involvement in our [issues page](http
| [`@livepeer/explorer`](https://github.com/livepeer/livepeerjs/tree/master/packages/explorer) | A protocol explorer for the web. It allows users to see general information about the protocol and specific information about Eth addresses within the protocol. See it live at [explorer.livepeer.org](https://explorer.livepeer.org) |
| [`@livepeer/player`](https://github.com/livepeer/livepeerjs/tree/master/packages/player) | A video player for the web. Lets you see what's live streaming on the network. Our hosted media player runs off of this project. See it live at [media.livepeer.org](https://media.livepeer.org) |
| [`@livepeer/merkle-miner`](https://github.com/livepeer/livepeerjs/tree/master/packages/merkle-miner) | Helpers for mining a merkle proof and generating Livepeer Token |

| [`@livepeer/subgraph`](https://github.com/livepeer/livepeerjs/tree/master/packages/subgraph) | Subgraph manifest for The Graph |
## Resources

To get a full idea of what Livepeer is about, be sure to take a look at these other resources:
Expand Down
7 changes: 6 additions & 1 deletion docs/graphql-sdk/account.doc.html
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,11 @@ <h4 class="slds-text-title--caps slds-p-around--medium">Objects</h4>
Account
</a>
</li>
<li title="Block">
<a href="block.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
Block
</a>
</li>
<li title="Broadcaster">
<a href="broadcaster.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
Broadcaster
Expand Down Expand Up @@ -223,7 +228,7 @@ <h2 id="graphql-schema-definition" class="graphdoc-section__title slds-text-head
</a>
GraphQL Schema definition
</h2>
<code class="highlight"><ul class="code" style="padding-left:42px"><li><span class="keyword operator ts">type</span> <span class="identifier">Account</span> {</li><li></li><li><span class="tab"><span class="comment line"># The ETH address for an account</span></span></li><li><span class="tab"><span class="meta">id</span>: <a class="support type" href="string.doc.html">String</a>! </span></li><li></li><li><span class="tab"><span class="comment line"># The ETH balance for an account</span></span></li><li><span class="tab"><span class="meta">ethBalance</span>: <a class="support type" href="string.doc.html">String</a>! </span></li><li></li><li><span class="tab"><span class="comment line"># The Livepeer Token (LPTU) balance for an account</span></span></li><li><span class="tab"><span class="meta">tokenBalance</span>: <a class="support type" href="string.doc.html">String</a>! </span></li><li></li><li><span class="tab"><span class="comment line"># The broadcaster info for an account</span></span></li><li><span class="tab"><span class="meta">broadcaster</span>: <a class="support type" href="broadcaster.doc.html">Broadcaster</a>! </span></li><li></li><li><span class="tab"><span class="comment line"># The delegator info for an account</span></span></li><li><span class="tab"><span class="meta">delegator</span>: <a class="support type" href="delegator.doc.html">Delegator</a>! </span></li><li></li><li><span class="tab"><span class="comment line"># The transcoder info for an account</span></span></li><li><span class="tab"><span class="meta">transcoder</span>: <a class="support type" href="transcoder.doc.html">Transcoder</a>! </span></li><li>}</li></ul></code>
<code class="highlight"><ul class="code" style="padding-left:42px"><li><span class="keyword operator ts">type</span> <span class="identifier">Account</span> {</li><li></li><li><span class="tab"><span class="comment line"># The ETH address for an account</span></span></li><li><span class="tab"><span class="meta">id</span>: <a class="support type" href="string.doc.html">String</a>! </span></li><li></li><li><span class="tab"><span class="comment line"># The ENS name for an account</span></span></li><li><span class="tab"><span class="meta">ensName</span>: <a class="support type" href="string.doc.html">String</a>! </span></li><li></li><li><span class="tab"><span class="comment line"># The ETH balance for an account</span></span></li><li><span class="tab"><span class="meta">ethBalance</span>: <a class="support type" href="string.doc.html">String</a>! </span></li><li></li><li><span class="tab"><span class="comment line"># The Livepeer Token (LPTU) balance for an account</span></span></li><li><span class="tab"><span class="meta">tokenBalance</span>: <a class="support type" href="string.doc.html">String</a>! </span></li><li></li><li><span class="tab"><span class="comment line"># The broadcaster info for an account</span></span></li><li><span class="tab"><span class="meta">broadcaster</span>: <a class="support type" href="broadcaster.doc.html">Broadcaster</a>! </span></li><li></li><li><span class="tab"><span class="comment line"># The delegator info for an account</span></span></li><li><span class="tab"><span class="meta">delegator</span>: <a class="support type" href="delegator.doc.html">Delegator</a>! </span></li><li></li><li><span class="tab"><span class="comment line"># The transcoder info for an account</span></span></li><li><span class="tab"><span class="meta">transcoder</span>: <a class="support type" href="transcoder.doc.html">Transcoder</a>! </span></li><li>}</li></ul></code>
</div>
</section>
<section>
Expand Down
256 changes: 256 additions & 0 deletions docs/graphql-sdk/block.doc.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,256 @@
<!DOCTYPE html>
<html lang="en">

<head>
<meta charset="utf-8" />
<meta http-equiv="x-ua-compatible" content="ie=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
<link type="text/css" rel="stylesheet" href="./styles/graphdoc.css" />
<title>Block</title>
<link href="https://fonts.googleapis.com/css?family=Ubuntu+Mono:400,700" rel="stylesheet"><link type="text/css" rel="stylesheet" href="./assets/code.css" /><link type="text/css" rel="stylesheet" href="./assets/require-by.css" />
</head>
<body class="slds-scrollable--y">
<nav class="slds-grid slds-grid--vertical slds-col--rule-right">
<header class="slds-p-around--medium slds-col slds-shrik slds-grow-none">
<button class="slds-button slds-button--icon slds-float--right js-toggle-navigation less-than-medium">
<i class="material-icons">close</i>
</button>
<a href="https://livepeer.github.io/livepeerjs/" rel="nofollow" style="
padding: 29px;
box-sizing: border-box;
display: block;
"><img src="https://github.com/livepeer/livepeerjs/raw/master/livepeer_js.png" alt="LivepeerJS" style="max-width:100%;image-rendering: -webkit-optimize-contrast;"></a>
<div class="slds-p-top--small">
<input id="type-search" type="text" placeholder="Search a type" autofocus="" class="slds-input" />
</div>
</header>
<div id="navication-scroll" class="slds-scrollable--y slds-col slds-grow">
<div class="slds-grid slds-grid--vertical slds-navigation-list--vertical">
<h4 class="slds-text-title--caps slds-p-around--medium">Schema</h4>
<ul>
<li title="Query">
<a href="query.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
Query
</a>
</li>
<li title="Mutation">
<a href="mutation.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
Mutation
</a>
</li>
<li title="Subscription">
<a href="subscription.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
Subscription
</a>
</li>
</ul>
</div>
<div class="slds-grid slds-grid--vertical slds-navigation-list--vertical">
<h4 class="slds-text-title--caps slds-p-around--medium">Scalars</h4>
<ul>
<li title="Boolean">
<a href="boolean.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
Boolean
</a>
</li>
<li title="Int">
<a href="int.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
Int
</a>
</li>
<li title="JSON">
<a href="json.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
JSON
</a>
</li>
<li title="String">
<a href="string.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
String
</a>
</li>
</ul>
</div>
<div class="slds-grid slds-grid--vertical slds-navigation-list--vertical">
<h4 class="slds-text-title--caps slds-p-around--medium">Enums</h4>
<ul>
<li title="DelegatorStatus">
<a href="delegatorstatus.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
DelegatorStatus
</a>
</li>
<li title="TranscoderStatus">
<a href="transcoderstatus.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
TranscoderStatus
</a>
</li>
<li title="__DirectiveLocation">
<a href="directivelocation.spec.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
__DirectiveLocation
</a>
</li>
<li title="__TypeKind">
<a href="typekind.spec.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
__TypeKind
</a>
</li>
</ul>
</div>
<div class="slds-grid slds-grid--vertical slds-navigation-list--vertical">
<h4 class="slds-text-title--caps slds-p-around--medium">Objects</h4>
<ul>
<li title="Account">
<a href="account.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
Account
</a>
</li>
<li class="slds-is-active" title="Block">
<a href="block.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
Block
</a>
</li>
<li title="Broadcaster">
<a href="broadcaster.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
Broadcaster
</a>
</li>
<li title="Delegator">
<a href="delegator.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
Delegator
</a>
</li>
<li title="Job">
<a href="job.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
Job
</a>
</li>
<li title="JobProfile">
<a href="jobprofile.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
JobProfile
</a>
</li>
<li title="Protocol">
<a href="protocol.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
Protocol
</a>
</li>
<li title="Round">
<a href="round.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
Round
</a>
</li>
<li title="Transaction">
<a href="transaction.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
Transaction
</a>
</li>
<li title="Transcoder">
<a href="transcoder.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
Transcoder
</a>
</li>
<li title="__Directive">
<a href="directive.spec.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
__Directive
</a>
</li>
<li title="__EnumValue">
<a href="enumvalue.spec.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
__EnumValue
</a>
</li>
<li title="__Field">
<a href="field.spec.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
__Field
</a>
</li>
<li title="__InputValue">
<a href="inputvalue.spec.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
__InputValue
</a>
</li>
<li title="__Schema">
<a href="schema.spec.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
__Schema
</a>
</li>
<li title="__Type">
<a href="type.spec.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
__Type
</a>
</li>
</ul>
</div>
<div class="slds-grid slds-grid--vertical slds-navigation-list--vertical">
<h4 class="slds-text-title--caps slds-p-around--medium">Directives</h4>
<ul>
<li title="deprecated">
<a href="deprecated.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
deprecated
</a>
</li>
<li title="include">
<a href="include.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
include
</a>
</li>
<li title="skip">
<a href="skip.doc.html" class="slds-navigation-list--vertical__action slds-text-link--reset slds-truncate">
skip
</a>
</li>
</ul>
</div>
</div>
</nav>
<main><section class="title slds-theme--inverse">
<div class="container slds-grid">
<div>
<button class="slds-button js-toggle-navigation less-than-medium">
<i class="material-icons slds-button__icon slds-button__icon--left">menu</i>
<span class="slds-text-title--caps">Types<span>
</button>
</div>
</div>
</div>
<div class="container">
<p class="slds-text-title--caps slds-text-color--weak">OBJECT</p>
<h1 class="slds-text-heading--large">Block</h1>
<div class="slds-text-body--regular"><p>Info about an Ethereum block.</p>
</div>
</div>
</section>
<section>
<div class="container">
<h2 id="graphql-schema-definition" class="graphdoc-section__title slds-text-heading--medium slds-m-top--small">
<a href="#graphql-schema-definition">
<i class="material-icons">link</i>
</a>
GraphQL Schema definition
</h2>
<code class="highlight"><ul class="code" style="padding-left:28px"><li><span class="keyword operator ts">type</span> <span class="identifier">Block</span> {</li><li></li><li><span class="tab"><span class="comment line"># The block number</span></span></li><li><span class="tab"><span class="meta">id</span>: <a class="support type" href="string.doc.html">String</a>! </span></li><li>}</li></ul></code>
</div>
</section>
<section>
<div class="container">
<h2 id="require-by" class="graphdoc-section__title slds-text-heading--medium slds-m-top--small">
<a href="#require-by">
<i class="material-icons">link</i>
</a>
Require by
</h2>
<ul class="require-by"><li><a href="query.doc.html" title="Query - Contains all protocol data-fetching queries">Query<em>Contains all protocol data-fetching queries</em></a><li></ul>
</div>
</section>
<footer>
<div class="container slds-p-around--large">
<p class="slds-text-align--right slds-text-title--caps">
Generated with <a href="https://github.com/2fd/graphdoc#readme" target="_blank">graphdoc 2.4.0</a>
</p>
</div>
</footer>
</main>
<script src="./scripts/focus-active.js"></script>
<script src="./scripts/filter-types.js"></script>
<script src="./scripts/toggle-navigation.js"></script>
</body>
Loading

0 comments on commit d7367ab

Please sign in to comment.